User Story Metadata Index
The User Story Metadata Index feature is used to track metadata components that have been added/committed the user stories. This index consists of records of the "User Story Metadata" object. Each of these records associate a metadata component with a user story.
The index is updated as long as the “Index Metadata” checkbox in the user story’s project has been checked. The Overlap Awareness feature will check whether the Metadata or Git Metadata added to the user stories have potential conflicts.
When a potential conflict is found with a metadata component, the Status of the conflicting User Story Metadata will be updated to "Potential Conflict". You will find the indexed metadata in the "User Story Metadata" related list in the user story layout.
As of Copado v8.5, you can click any user story metadata in the related list to see a list of user stories that share the same metadata component:
Since Copado V10: You can create a pull request between the feature branches of user stories with potential conflict in order to review if changes are mergeable or have conflicts. If there are conflicts, you can start a discussion with the developer/admin/business user that has ownership on the other user story to discuss and agree on how the conflict should be resolved.
The status of each user story metadata can be updated by clicking the dropdown icon in each record:
The status of all the user story metadata records can be updated at once by selecting a status from the "Mark All As" dropdown list:
The status picklist values are defined in the Status custom field of the User Story Metadata object and you can add custom values to it.
Metadata Index Update
As of Copado v8.5, the Metadata Index for each user story is updated automatically whenever a metadata component is added or committed in the user story.
You can schedule periodic updates of all your metadata index by scheduling an Apex class called “IndexMetadataJob”. To schedule it go to Setup > Develop > Apex Classes, and then press the button "Schedule Apex". Choose a name (e.g. Metadata Index), select the class "IndexMetadataJob" and set the period as needed. See screenshot below:
To execute the Index Metadata Job manually follow these steps:
- Open the Developer Console -> Debug -> Open Execute Anonymous Window
- Copy paste the following line of code:
- Id batchJobId = database.executebatch(new copado.IndexMetadataJob(), 50);
- The execution of the job usually takes between 1 to 5 minutes depending on the amount of user stories you have.
- After this time has passed, you can rerun the Report to update the values and within every User Story you will find the updated User Story Metadata related list.
- You can also track the execution of the job by going to Setup -> Monitor -> Jobs -> Apex Jobs
You can create a Report with the “User Story” and “User Story Metadata” objects. See image below for an example report showing in which user stories the same metadata components are being included:
You can add custom filters to the report and customize it as per your needs like, for example, excluding user stories with status “Completed”.