Define or update a collection in an application

  • Release version: Washingtondc
  • Updated February 1, 2024
  • 3 minutes to read
  • Define or update a collection while working in a changeset of a application.

    Before you begin

    Important:
    Starting with the Washington DC release, DevOps Config is being prepared for future deprecation. It will be hidden and no longer installed on new instances but will continue to be supported. For details, see the Deprecation Process [KB0867184] article in the Now Support Knowledge Base.

    Role required: cdm_editor or cdm_admin

    About this task

    Important:
    Save your changes whenever you are confident of the changes and before you leave the Config data tab.

    Procedure

    1. To add a collection to the application: While working in a changeset, select the more actions icon (More actions icon.) for the collection node and select Create collection.
    2. To edit individual data items, you can either work directly in the code or select the more actions icon (More actions icon.) for an item and select an action, as follows.
      SelectionAction
      Create collection Add an individual component to the collection.
      Create CDI

      Add an individual config data item (CDI) and value to the collection. See the instructions in the next step.

      The CDI can have an explicit value or it can be a variable, override, or overlay.
      • Variable: The value for this CDI will set the value for an identically-named CDI in an included component.
      • Override: The value for this CDI will override the value for an identically named CDI in an included component. You can also override inherited nodes and CDIs from the child collection. Overridden nodes and CDIs are labeled as Overridden Inherited.
      • Overlay: A CDI that does not appear in any included component.
      Inherit from collection Automatically inherit changes from another collection.

      When you select the check box and then specify a Collection, changes you make in the specified parent collection are reflected in all child collections.

      Select Remove inheritance to remove the existing hereditary relationship from a collection.

      Note:
      Inheritance is considered invalid when:
      • Circular, where the parent and child both inherit from each other.
      • There are more than the maximum number of collections in a chain. This number is 5 by default. Example: Collection1 is inherited by Collection2. Collection2 is inherited by Collection3. This chain of inheritance cannot continue to Collection6. You can change the valid chain length by editing the sn_cdm.max_inheritance_chain_length system property.
      Include in deployables

      Include the selected collection in specified deployables.

      In the Include in deployables dialog box, select the deployables that should include the collection and then select Include.

      Note:
      Only deployables that do not currently include the collection appear in the list.
      Rename Rename the selected collection.
      Delete Delete the selected collection.
      Details View the administrative information associated with the collection.
      View relationships View direct relationships with the node. Direct relationships are formed between nodes by inheritance or by being included.
    3. Add a CDI: Select the more actions icon (More actions icon.) for the item and select Create CDI.
      Table 1. Create CDI
      Name Unique and meaningful name for the CDI.
      Value Value that the CDI has in the current context or define a variable.
      • You can specify a direct key : value pair.
      • You can define a variable and specify its default value. Variable definitions have the following form:
        @@<variableName>@@: <value>
      • You can specify a value for a variable using the following form:
        "<variableName>": "<value>"
      • You can specify a contextual variable. These are variables defined out-of-the-box that use the context of the node to set the variable value. The variable uses the following form:
        "<variableName>": "(#<value>#)"
      • You can use recursive variables for a CDI value. Recursive variables use other variable values as parameters to set the CDI value. For example, each of these CDI values can resolve the same due to recursive variables:
        cdi1: @(favorite_food/@(person)@)@
        cdi2: @(favorite_food/@(john)@)@
        cdi3: waffles
      Encrypted

      Option to specify that the value of the CDI should be encrypted. This option appears only for users with the CDM Secrets [sn_cdm.cdm_secrets] role.

      After you create the CDI, the value appears in all views as *******. To view the value on any tab that displays the CDI, users with the CDM Secrets [sn_cdm.cdm_secrets] role can select the View encrypted data menu option.

    4. Optional: Add CDI settings that will override or overlay settings in collections.
      For more information, see Define or update a component.