The operation.json file defines the
operations that can be called when the virtual application is running.
Operations are grouped by role, and each operation is associated with
a Python script, which is provided by the plug-in. Users request the
operation on the Instance Console.
This request is forwarded by Cloud Pak System Software for Power®,
and any parameters are sent to the script on systems where the role
is running. You can modify the operation.json file
with the PDK JSON Editor.
Procedure
- If you already have the PDK JSON Editor open
for your plug-in project, click the Operation tab.
Otherwise,
- In the Project Explorer view,
expand the plug-in project node.
- Expand the plugin folder node.
- Expand the appmodel folder node.
- Double-click the operation.json file,
or right-click the file and select .
The
Overview tab, which shows the
structure and contents of the plug-in, is displayed. This tab has
four sections:
- Package
- Lists the parts, node parts, and roles in the plug-in. Click Add to
add a part, node part, or role to the plug-in.
- Metadata
- List the components, links, and policies in the plug-in. Click Add to
create a metadata element in metadata.json.
- Runtime
- Provides links to the metadata.json, operation.json,
and tweak.json files for the plug-in.
If an item is available for editing in Eclipse, you
can double-click to open it.
- Click the operation.json link on
the Overview tab, or click the Operation tab
to customize the operation.json file.
The
Operation tab
shows a list of the operations for the plug-in. The name of the operation
is the concatenation of the ID and role values that are associated
with the operation. Using this form-based interface, you can do the
following tasks:
Values that you specify are immediately validated, and
errors, such as missing required fields, duplicate IDs, are flagged,
with help tips, for correction.
In some cases you might prefer
to modify the configuration text directly, by clicking the operation.json tab
to present the configuration information in a formatted text editor.
Changes that are made in either the Operation user
interface or the source text editor are immediately reflected in both
views.