4.1

Table Of Contents
Run Workflows on Plug-In Objects in the Inventory
You can use the scripting objects that a plug-in adds to the Orchestrator JavaScript API to write workflows
and actions to interact with the plugged-in technology.
The solar system plug-in includes a package of workflows that you can use to perform operations on the objects
that the plug-in adds to the Orchestrator inventory.
Prerequisites
n
Install the solar system plug-in in the Orchestrator server.
n
Start the Orchestrator client.
Procedure
1 Click Workflows in the Orchestrator client.
2 Expand the Samples > SolarSystem nodes in the hierarchical list of workflows to see the list of workflows
that the solar system plug-in adds to the library.
3 Click the Add Planet workflow.
4 Click the Schema tab and click the scripted element in the schema.
5 Click the Scripting tab for the scripted element.
You see that Add Planet workflow calls the Star.addPlanet() method from the solar system application.
6 Click Inventory.
7 Expand the SolarSystem node in the hierarchical list of plug-ins and select the Helios star object.
You see objects that represent the planets of Earth's solar system. The planets are the instances of the
Planet object that the SolarSystemRepository class from the solar system application creates.
8 Expand a planet node to see its moons.
The vso.xml file defines the hierarchy of planets to stars and moons to planets by setting the
OrbitingPlanets and OrbitingMoons relations.
9 Click the sun, a planet, or a moon to display its properties on the right.
10 Right-click the sun, a planet, or a moon to and select Run workflow to run a workflow on that object.
You can select a workflow to run from a contextual list of workflows that take that type of object as an
input parameter.
You can run workflows on the solar system objects in the inventory. You can add a planet to the sun's orbit or
generate or wait for a solar flare. You can modify the circumference of planets or split or destroy them.
What to do next
Monitor events in the solar system application by setting a policy.
Monitor Plug-In Events by Using Policies
You can use policies to monitor events in a plugged-in technology and perform defined operations when the
events occur.
The solar system plug-in includes a policy that monitors a star object for solar flares. When flares occur, the
policy records the magnitude of the flares in the logs.
Prerequisites
n
Install the solar system plug-in in the Orchestrator server.
vCenter Orchestrator Developer's Guide
206 VMware, Inc.