How to collect all Snapshots(BaselineSets) linked with Baseline?
How to collect all Snapshots(BaselineSets) linked with Baseline?
I have a Stream and i have created Baseline for Component In ALM. I have created more than one Snapshot with the same reference of baseline(Baseline UUID).
In that case, how to collect all the BaselineSet which linked with Baseline(Baseline UUID)?
Note: Usually we can collect all the Baselines from BaselineSet. But this is like reverse case, from Baseline collecting all the linked BaselineSets(Snapshots). |
Accepted answer
The following API can be used to find all snapshots that contain a specific baseline:
IBaselineSetSearchCriteria.getContainsBaselinesOptional() (Note: You would first 'get' the list, then add the desired IBaselineHandle to that list)
Note: This API was added in RTC 6.0.2, so hopefully your RTC version is equal or greater to that version.
(The work item which added this feature is: Expand IBaselineSetSearchCriteria to allow searching for snapshots containing a baseline (376652))
Vijayanand Karunanithi selected this answer as the correct answer
Comments
Vijayanand Karunanithi
commented Jun 20 '18, 7:54 a.m.
I have tried that and it is not working for me.
David Lafreniere
commented Jun 20 '18, 11:07 a.m.
| edited Jun 20 '18, 11:10 a.m.
FORUM MODERATOR / JAZZ DEVELOPER
By setting the [optional] process area in the IBaselineSetSearchCriteria, it means you are only finding snapshots that are owned by a stream, where that stream is owned by that process area. This means the result will never return a snapshot that is owned by a repository workspace, or snapshots owned by a stream, which is owned by a different process area.
Can you try 'not' setting the process area in the IBaselineSetSearchCriteria and see if this fixes your issue?
I suppose the other question is: "Are you 100% sure there is even a snapshot that contains the baseline? There's no reason to assume a random baseline is contained in a snapshot in the repository".
|
Your answer
Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.