Previous Topic: Relationships with Applications in NATURAL DS Language

Next Topic: Implementation for the Stopping Method for Resources That Communicate by WTOR Messages

Implementation of the Definition for a Resource That Should Be Started Once Only

You can define a resource that satisfies the following requirements:

For example, you want to submit a set of jobs once and once only during the life of a system.

A typical implementation uses a activation process and a display process:

The activation process takes the following actions:

  1. Perform tasks.
  2. Execute the EVVARSET macro to set an EventView variable to ACTIVE.

The display process takes the following actions:

  1. Execute the EVVARGET macro to get the value of the EventView variable.
  2. Execute the COMPARE macro to test the value.

The startup sequence of the resource is as follows:

  1. The region starts up.
  2. The resource display process gets a null value from the EventView variable.
  3. The resource activation process is executed, setting the value of the variable to ACTIVE.
  4. In subsequent activations of the resource, the display process gets an ACTIVE value from the variable and the resource is not activated again.