Generating consumer IDs for capability versions

You can simplify the creation of capability versions by generating a consumer ID value using the configurable modifier.

Procedure

To modify the WSRR profile to generate a consumer ID, complete the following steps:

  1. In Studio, create a new WSRR GEP V8.5 or SMP V8.5.5 project, or open an existing project.
  2. Create a configurable modifier file called generate_consumerID (found in Configuration Profile Files > Modifiers > Configurable Modifier).
  3. Add the following contents to the file:
    <action-configuration
      xmlns="http://www.ibm.com/xmlns/prod/serviceregistry/Actions" name="generate_consumerID"
      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      xsi:schemaLocation="http://www.ibm.com/xmlns/prod/serviceregistry/Actions ../schema/Actions.xsd">
      <!-- for a version -->
      <update-action run-on-import="false" target-query="//*[@bsrURI='${trigger.bsrURI}']">
    	<set-property name="gep63_consumerIdentifier" value="${random.uuid}"/>
      </update-action>
    </action-configuration>
  4. Save the file.
  5. Edit the triggers file in Configuration Profile Files > Modifiers > Configurable Modifier.
  6. At the bottom of the file, before the final </triggers> element, insert the following lines:
    <trigger wsrr-event="create">
    <mapping>
          <entity>
                   <any-of>
                   <model-type model-uri="http://www.ibm.com/xmlns/prod/serviceregistry/profile/v6r3/GovernanceEnablementModel#ServiceVersion"/>
                   <model-type model-uri="http://www.ibm.com/xmlns/prod/serviceregistry/profile/v6r3/GovernanceEnablementModel#ProcessVersion"/>
                   <model-type model-uri="http://www.ibm.com/xmlns/prod/serviceregistry/profile/v6r3/GovernanceEnablementModel#CapabilityVersion"/>
                   <model-type model-uri="http://www.ibm.com/xmlns/prod/serviceregistry/profile/v6r3/GovernanceEnablementModel#ApplicationVersion"/>
                   </any-of>
          </entity>
          <configuration name="generate_consumerID" />
        </mapping>
    </trigger>
  7. Save the file.
  8. Export the updated profile by completing one of the following actions:
    • Export the updated WSRR configuration profile to one of your defined WSRR Locations by right-clicking the WSRR location in the WSRR Locations window and selecting Export WSRR Configuration Profile.
    • Synchronize your changes with an existing WSRR configuration profile by right-clicking the project name and selecting Synchronize profile with WSRR.