Setting and viewing administrative metadata in Admin Center

You can use the Tags and Metadata dialog of the Explore tool to set and view administrative metadata for server, cluster, host, runtime, and application resources in a Liberty collective. Also, you can view administrative metadata for server, cluster, runtime, and application resources defined in an admin-metadata.xml file in the Explore tool. If a resource has administrative metadata defined in both the Tags and Metadata dialog and an admin-metadata.xml file, the Explore tool displays the resource metadata from both the dialog and the admin-metadata.xml file.

About this task

The following steps describe how to set or view resource metadata in the Explore tool:

The product stores changes that you save in the Tags and Metadata dialog directly to the collective repository, and not to an admin-metadata.xml file. Changes made to metadata settings in the admin-metadata.xml file are shown in the Tags and Metadata dialog and on the Explore tool resource page when the server to which the admin-metadata.xml file belongs is restarted. Metadata deleted using the Tags and Metadata dialog redisplays in the Explore tool after the server restarts if the deleted metadata is still defined in the admin-metadata.xml file.

Procedure

  • Set and view administrative metadata for server, cluster, host, runtime, and application resources in the Tags and Metadata dialog of the Explore tool.
    1. From the Toolbox, select Explore Explore icon.
    2. Select a resource for which to set administrative metadata.
      • For server metadata, select the Servers panel and then a server.
      • For cluster metadata, select the Clusters panel and then a cluster.
      • For host metadata, select the Hosts panel and then a host.
      • For runtime metadata, select the Servers panel, a server, and then Liberty Runtime or select the Hosts panel, a host, Runtimes and then a runtime instance.
      • For application metadata, view application details on a particular server. For example, if app1 is deployed to server1, view the app1 on server1 details to see the application metadata. If server1 is a member of a cluster, view the app1 on cluster cluster_name details.

        Each instance of app1 in members of the cluster inherits the app1 application metadata.

    3. Select Actions icon or Actions icon for a resource and then select Tags and Metadata.
    4. In the Tags and Metadata dialog, add metadata values to the Tags, Owner, Contacts or Notes fields and then select Save.
      Tags
      A tag is a word that you can use to search for resources. Specify no tags or as many tags as you want. Tags that contain uppercase characters convert to lowercase; thus, MyTag converts to mytag.
      Owner
      An owner is typically a person or entity responsible for the metadata. The owner can provide a key for the metadata. Specify no more than one owner.
      Contacts
      A contact is a person or entity who can provide information about the resource object. Specify zero or many contacts.
      Notes
      A note is arbitrary text. Specify no more than one note.
      Tags and Metadata dialog of the Explore tool

    The metadata is shown in details about the resource after you select the More link.

  • View administrative metadata for server, cluster, runtime and application resources defined in an admin-metadata.xml file.

    You can see administrative metadata that is set in an admin-metadata.xml file in a details or runtime view. Setting administrative metadata for Liberty resources describes how to enable an admin-metadata.xml file.

    For example, suppose a collective controller named controller1 has the following admin-metadata.xml file in its server configuration directory, $WLP_USER_DIR/servers/controller1:

    <admin-metadata>
        <server owner="John Doe">
            <tag>controller</tag>
            <tag>replica_controller</tag>
            <contact>Michal</contact>
            <contact>Felix</contact>
            <contact>Travis</contact>
            <contact>Philippa</contact>
            <contact>Amy</contact>
            <note>The first of three replica controllers. At least three replica controllers are needed for high availability.</note>
        </server>
    </admin-metadata> 

    The metadata is shown in details about the controller1 server after you expand the Tags and Metadata link:

    Explore tool server detail view showing administrative metadata in the controller1 admin-metadata.xml file

    Select the expanded Tags and Metadata link to hide the metadata.