How can I add a baseline to a in-process delivery within a server operation participant
I am trying to provide support for our build process by adding a feature which allows RTC to automatically add a baseline to all components within a delivery. This will provide a reference for developers to choose which baseline they would like to build in the future. I would like to have it a baseline as this is viewable directly on a component and is selectable from the UI. I understand that functionality exists to automatically create a baseline POST-BUILD. However, not all code deliveries need to be built -- especially in a shared stream, multiple developer environment. Instead, what I would like is to not require a build to create the baseline yet have some way to designate one for the delivery. I have created a delivery operation participant server plugin for this purpose which I had hoped I could use to create the baseline on the server and add it to the delivery. However, due to the transactional nature of a delivery and the need to maintain referential integrity, I have not found a way to add a baseline to the current delivery. The code executes in an endless loop as it tries to figure out why various object timestamps within the transaction have changed. What I would like to see is an example of how this could be done.
Some things that have been attempted:
Some things that have been attempted:
-
Using com.ibm.team.scm.service.internal.SCMService, I have created changesets and baselines in various combinations on the delivery component. This method results in the aforementioned endless loop.
- Using com.ibm.team.scm.service.internal.utils.BaselineUtils, I have attempted to create a baseline within the currently running transaction. However the reference to the transaction, which is held by the current delta object for the delivery, is not accessible.