While debugging, you can export property values to a properties file. This allows you to save multiple property values in a file for subsequent reference.
Exporting property values
Follow these steps to export property values to a specified file.
- From the debugger interface, click Export.
- Access the browser to locate the properties file or specifically enter its name, then click OK.
The property values are exported to the specified file. The property values are exported in the Json format and, by default, are saved to the service_properties.json file.
Format
In the properties file specified as a command argument, the property key and value used by the executed services can be defined in JSON, key=value, and key@FILE=file-path formats.
JSON format
{ "properties": [ { "keyName": "property-key", "displayName" : "property-display-name" "description" : "description-of-property" "type" : "property-type" "value": "property-value" }, { "keyName": "property-key", "displayName" : "property-display-name" "description" : "description-of-property" "type" : "property-type" "value": "property-value" }, ... ] }
Following are definition details for the JSON format:
- The displayName, description, and type fields are optional.
- When you specify the value field, set an empty value for the property value.
- The value for the password type property can be in plain text or encrypted. The "value" field of the password type property is not exported for security reasons. The defined value is imported as is, and the REST API determines whether it is in plain text or encrypted.
- In the definition file, define only properties for which you want to set values. The values of properties that are not defined in the imported file remain unchanged. When exporting step properties, the type field is only output for the service component.
key=value format:
To specify property values for a key=value properties file, use the following format:
property-key=property-value [line break]
Following are definition details of the key=value format:
- Specify a property name and a property value on each line.
- Lines starting with a hash mark (#) are handled as comment lines.
- Lines that do not contain an equal mark "=" are handled as comment lines.
- A line break needs to be added at the end of each property setting line.
- Do not add line breaks in the middle of the property name and property value lines.
- Characters are case-sensitive.
- Even when a "\" is contained in strings like service and plug-in resource files, you do not must type "\\".
- "\" is handled as a "\".
- The characters at the beginning of a line up to the first equal sign (=) are treated as a property name. Do not trim lines before and after the property setting line.
- The characters after the equal sign (=) after the property name, until the end of the line are treated as the property value. Do not trim lines before and after the property setting line.
- The end-of-line character at the end of the properties file (EOF) is optional.
- Empty lines (lines containing line breaks only) are ignored.
- Both CR+LF and LF can be used as line breaks.
- When using the property-key = [line break] format, set an empty value for the property value.
key@FILE=file-path format
In this format, the property key is stored in the properties file, and the property value is stored in the property value file and referenced separately. Note that this format can be used together with the key=value format in the properties file:
property-key@FILE=absolute-path-of-the-property-value-file or relative-path-from-the-property-file [line break]
The definitions in the key@FILE=file-path format are the same as the key=value format. The differences from the key=value format are as follows:
- The absolute path of the property value file or the relative path from the properties file must always be specified or an error occurs.
- If the specified file does not contain a property value, an error occurs.
- The property value file can contain end-of-line characters. However, if a property value file that contains an end-of-line character is specified for a property for which end-of-line characters must not be set, an error occurs.