2.2.5 Example of mapping parameter definition and flow of data
The process of defining mapping parameters links the input and output properties of a service to the input and output properties and variables of a plug-in. By defining mapping parameters, you can execute processing that uses a value specified at service execution as a value of the input property of a plug-in. You can also assign the output of a plug-in to an output property of a service template or a variable when the plug-in finishes processing.
The following describes an example of mapping parameter definitions, and explains what kind of data is exchanged between properties.
Conditions
The following describes an example of creating a service template that executes certain plug-ins and is defined as shown below.
-
The properties of the plug-ins are defined as follows:
Table 2‒4: Definition of plug-in A Property type
Property name
Input property
Capacity
Execution target server
Output property
Output result of plug-in
Table 2‒5: Definition of plug-in B Property type
Property name
Input property
Execution-target server
Storage folder path
-
The operator specifies the value of the Execution-target server and Storage folder path properties when he or she submits the service for execution.
-
The value of the Capacity property is fixed at 10 and does not need to be changed.
-
After the service has been executed, you can check the output result of plug-in A in the Task Details dialog box.
Definition
-
The service is defined as follows in the Edit Service Definition dialog box:
Table 2‒6: Definition in Edit Service Definition dialog box Property type
Property name
Input property
Server name
Storage folder path
Output property
Service execution results
-
Add plug-in A and plug-in B to the flow as steps. Then, define the steps as follows in the Edit Step dialog box:
Table 2‒7: Definition of step A Property name
Mapping parameter
Capacity
10
Execution-target server
Server name property key
Plug-in output results
Service execution results property key
Table 2‒8: Definition of step B Property name
Mapping parameter
Execution-target server
Server name property key
Storage folder path
Storage folder path property key
The properties defined in the Edit Service Definition dialog box are mapped to the execution-target server, plug-in output results, and storage folder path.
Flow of data
The following figure shows the flow of data between properties:
-
The value specified for the Server name parameter in the Submit Service dialog box is stored as the value of the Execution-target server parameter for plug-in A and plug-in B.
-
The value specified for the Storage folder path parameter in the Submit Service dialog box is stored as the value of the Storage folder path parameter for plug-in B.
-
The value of the Plug-in output results parameter of plug-in A appears for the Service execution result property in the Task Details dialog box.
-
The value of the Execution-target server parameter of plug-in A and plug-in B appears in the Server name field of the Task Details dialog box.
-
The value of the Storage folder path parameter of plug-in B appears for the Storage folder path property in the Task Details dialog box.