Procedure for Performing Operations That Do Not Update Source Traces
As a best practice, you should modify how you perform certain operations so that source traces are maintained as the operation is performed. This allows the user making the change to update the source traces to be consistent with the change.
As an alternative, you can check for and fix invalid source traces independent of the operation. However, in many cases, it is harder to determine the correct new source trace if you did not perform the operation that caused the change.
Update source traces at the time of the operation
Actions that do not automatically update traces should be restricted to select users who know the steps required to update source traces.
The general steps to follow are:
1. Record the traces to member revisions that will be affected by the operation.
2. Delete the traces to the affected member revisions.
3. Perform the operation.
4. Add the traces to the new member revisions where appropriate.
5. Verify the source traces for the affected items.
|
In many cases you can use scripts to record the current traces using the im viewissue, im issues and im viewsourcetraces CLI command output and then revise that information and use it to restore the correct traces using the im editissue CLI command.
|
Update source traces independent of the operation
Verify your source traces by running the check source traces command. This command identifies invalid traces and traces that are no longer to the current member revision. You can then correct the reported exceptions. It may be helpful to use a script to identify and update the source traces.
Verifying source traces
1. Determine the items that you want to verify source traces for.
|
Create a query using the hassourcelinks filter to find these items.
|
2. Run the im checksourcetraces CLI command for the required source link field(s) and item ID(s).
See the CLI man pages for details of this command.
3. Review the source traces and validation errors. The command reports the following:
◦ if the source trace configuration path is invalid (project configuration path has been changed)
◦ if the source trace is to a member that does not currently exist (has been dropped or renamed)
◦ if the source trace is to a member revision that is not the current member revision
4. Determine the corrective action. This often includes locating the current project configuration and member revision that the trace should be referring to.
5. Edit the item to drop invalid traces and add valid traces.