How to selectively deliver change-sets?
I have work that is complete in my current stream but I need to propagate my change-sets to a different (later) stream.
https://jazz.net/library/article/40
We created a repository workspace from 2015-03 release working stream and changed the flow target to 2015-07 release working stream, accepted all incoming changes and attempted to auto resolve all conflicts. We can't discard or suspend any of the other change sets in the component as it would create gaps, but also can't only deliver the change sets we're interested in because we get the following error:
Deliver Failed
Delivery for component 'Associates' failed as it would create conflicts in the stream. As
you do not have any incoming change sets for this component you should consider
delivering all of the outgoing changes.
OK
Is there some other method we can use to selectively deliver the change sets?
2 answers
- For every stream you want the change set to go to, create a repository workspace based on the current state.
- Search for the change set or select it on a work item
- Right click and Accept the change into the repository workspace - note that the change set should be completed
- Since the workspace is up to date with the stream there are no incoming changes and the like
-
Deliver to the stream
Problems that can occur are "Gaps" where the change set depends on other changes that are missing in the stream. RTC 5.x added more gap handling features.
Pasting a sample precondition to check change-sets BEFORE delivery:
public class TestPreconsition extends AbstractScmService implements IOperationAdvisor {
@Override
public void run(AdvisableOperation operation, IProcessConfigurationElement advisorConfiguration, IAdvisorInfoCollector collector, IProgressMonitor monitor) throws TeamRepositoryException {
Object operationData = operation.getOperationData();
DeliverOperationData data = (DeliverOperationData) operationData;
List<IChangeSetHandle> changeSetHandles = data.getChangeSetHandles();
//Here goes your custom actions on deliverable change-sets...
}
}
}