4.1

Table Of Contents
n
Start the Orchestrator client.
Procedure
1 Click Policy Templates in the Orchestrator client.
2 Expand the Samples > SolarSystem nodes in the hierarchical list of policies.
3 Right-click the Star policy and select Apply Policy.
4 Add a policy description and select a Star object on which to apply the policy in the Apply Policy dialog
box and click Submit.
The Star policy opens in the Policies tab.
5 Click the Star policy and open the Scripting tab.
In the scripting tab you see that the policy is monitoring a threshold named Flare.
6 Right-click the Star policy and select Start policy.
7 Click the Inventory tab.
8 Right-click the Helios star and select Run workflow.
9 Run the Generate Flare Event workflow, setting the magnitude of the flare to 100.
The Generate Flare Event workflow includes a script that calls the
SolarSystemEventGenerator.generateFlareEvent() method. The gauge that the
SolarSystemEventGenerator class implements pushes an event object named Flare to the Orchestrator
policy engine.
10 Click the Policies tab.
11 Click the Star policy.
12 Click the Logs tab.
The policy has recorded the magnitude of the solar flare event in the logs.
The Star policy implements the solar system scripting API to monitor star objects for solar flare events and
records their magnitude. The policy keeps on running until you stop it. If you run the Generate Flare Event
again, the policy continues to record the magnitudes of the flares in the logs.
What to do next
Monitor events on objects in the plugged-in technology by running workflows.
Monitor Plug-In Events by Using Workflows
Workflows can include a Wait Event element that suspends the workflow and waits for an event to occur in a
plugged-in technology. Plug-ins can implement triggers and watchers to notify waiting workflows of the
events that occur.
The solar system example includes a workflow that implements a Wait Event element to wait for solar flares.
When a flare occurs, the waiting workflow resumes its run, records the magnitude of the flare in the logs, then
ends.
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.
Chapter 7 Developing Plug-Ins
VMware, Inc. 207