You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 9 Next »


Setting up event-action configurations

The live forecasting system can be scheduled to run workflows as a consequence of a log event generated by the system. This facility is used to enhance forecasting, or to export current forecast data on a new forecast becoming available.

This can only be done by suitably authorised users, and should follow a carefully defined scheduling plan. These users must have access to the admin interface tool (see Admin Interface manual).

A run that is to be enhanced must have already been submitted to the Master Controller and available in the Scheduled Forecasting Lists. The run is identified by its tag available in that list.

The actions that can be defined are;

  • Resuming a suspended task
  • Suspending a task
  • Changing of scheduling interval of a task (and resuming the task if required)
  • Submitting a single run of a task

For each an appropriate action configuration must be defined.

The procedure in defining an action config is.

  • Open the Admin interface.
  • Select the Workflow and FSS's item
  • Select Event and Action Configuration .
  • Select Upload New Action Configuration . This is an XML file that describes the action to be taken. It includes the tag that is defined in the Scheduled Forecast list. This must be identical (case sensitive) for a match to be made. Examples for the four types of actions are given below.
  • Submit the Action Config.
  • Select Event Action Mappings item
  • Select Create New Action Event Mapping
  • Enter the Event Code and select the Action Configuration Id for the configuration just created.
  • Select submit.

NOTE: when deleting action configurations, the Action Event Mapping must be deleted first due to relations in the database.

Example of Action Config to resume a suspended task

<?xml version="1.0" encoding="UTF-8"?>
<actionxml type="task">
	<enhance>
		<tag name="AIRE_FORECAST"/>
		<resume/>
	</enhance>
</actionxml>

Example of Action Config to suspend a task

<?xml version="1.0" encoding="UTF-8"?>
<actionxml type="task">
	<enhance>
		<tag name="AIRE_FORECAST"/>
		<suspend/>
	</enhance>
</actionxml>

Example of Action Config to enhance a task

<?xml version="1.0" encoding="UTF-8"?>
<actionxml type="task">
	<enhance>
		<tag name="EDEN_FORECAST"/>
		<repeatinterval interval="3600"/>
	</enhance>
</actionxml>

Example of Action Config to run one instance of a task

<?xml version="1.0" encoding="UTF-8"?>
<actionxml type="task">
	<oneoff>
		<cardinaltime interval="900" reference="2004-01-01T00:00:00.000+00:00"/>
		<tag name="EXPORT_CURRENT"/>
	</oneoff>
</actionxml>

Note: a one off task requires a cardinal time step and a reference time to establish a correct T0 for the run. The cardinal time step is important as it also controls how often the master controller will run an instance of the task if triggered by and event (it will only run once every cardinal timestep, even though there are multiple events in that period); it is recommended to set this to 1 second if the action should be executed for every event code (e.g. in the case of sending alert messages). This can be increased if is not desirable to executed several workflows in a short period (e.g. the case of creating web reports). It also needs the "template task" with the relevant tag scheduled (in suspended mode) as a singe/one-off task.

  • No labels