APD customization example: Update the Classification Script

After you customize the version file, you must update the classification script.

Procedure

  1. Navigate to Discovery Definition > CI Classification > Application and open the Application Classification record for your application.
  2. In the On classification script field, configure the classifier to return the data from the environment and version files.

Example

This example uses the following script:

var appdata = ciData.getData();
appdata.<asset_tag> = versionResult.config.version.custom.<asset_tag>;
appdata.<comments> = envResult.config.environment.custom.<comments>;

This script uses the appdata parameter to identify the field tags in each file. The remainder of the statement shows the position in each XML file in which the data appears.