The <activationInterval> element contains elements that define when a rule is active and inactive.
A rule can be activated or deactivated at a discrete point in time or by a specific event.
If you specify that a rule is to be activated, or deactivated, at a discrete point in time and by a specific event, the rule is activated, or deactivated, by whichever occurs first, the point in time or the receipt of the event. However, in this case, the rule might be activated or deactivated by many events throughout its life cycle. For example, a rule might be activated by an event, deactivated, activated at a defined point in time, deactivated again, and activated by another event.
<activationInterval> has no attributes.
<activationInterval> contains the following elements.
The elements must be coded in the order that is shown. If an element is optional, it does not need to be coded, but all elements that are coded must follow the correct order.
Element | Required or optional? |
---|---|
<activationTime> | Optional. 0 or 1 occurrence is allowed. |
<activateOnEvent> | Optional. 0 or 1 occurrence is allowed. |
<deactivateOnEvent> | Optional. 0 or 1 occurrence is allowed. |
<activationByGroupingKey> | Optional. 0 or 1 occurrence is allowed. |
The <start> and <stop> elements that are contained within the <activationTime> element are a static method of activating and deactivating a rule. Through these elements, a rule is activated or deactivated at a discrete point in time. In contrast, the <activateOnEvent> and <deactivateOnEvent> elements are a dynamic method of activating and deactivating a rule. Through these elements, a rule is activated or deactivated if a certain event occurs. For example, a rule is activated by any event that meets the criteria that is defined for the <activateOnEvent> element, if the rule is not already active. A rule is deactivated by any event that meets the criteria that is defined for the <deactivateOnEvent> element, if the rule is not already inactive. Therefore, certain events can alter the static definition of when a rule is activated or deactivated.
If the <start> element is not coded at all, the default start time is the same as that defined by the <whenLoaded> element.
If the <stop> element is not coded at all, the default stop time is the same as that defined by the <never> element.
<activationTime> | <activateOnEvent> | <deactivateOnEvent> | Rule activity | |
---|---|---|---|---|
<start> | <stop> | |||
<whenLoaded> | <never> | Rule is active when it is loaded and remains active while the Active Correlation Technology engine is running. | ||
<whenLoaded> | <never> | Y | Rule is active when it is loaded. Event Y deactivates the rule. | |
<whenLoaded> | <never> | X | Y | Rule is active when it is loaded. Event Y deactivates the rule, and event X reactivates it. This deactivation and reactivation can occur multiple times. |
<whenLoaded> | <after> | Rule is active when it is loaded, and it is deactivated after a specified time interval. | ||
<whenLoaded> | <dateTime> | Rule is active when it is loaded, and it is deactivated at a specified date and time. | ||
<inactiveWhenLoaded> | <never> | X | Rule is inactive when it is loaded. Event X activates the rule, and the rule remains active while the Active Correlation Technology engine is running. | |
<inactiveWhenLoaded> | <never> | X | Y | Rule is inactive when it is loaded. Event X activates the rule, and event Y deactivates it. This activation and deactivation can occur multiple times. |
<dateTime> | <dateTime> | Rule is activated at a specified date and time and deactivated at a specified date and time. | ||
<dateTime> | <dateTime> | X | Y | Rule is activated at a specified date and time and deactivated at a specified date and time. Event X activates the rule, and event Y deactivates it. Event X and Y can activate and deactivate the rule multiple times. |
<dateTime> | <never> | Rule is activated at a specified date and time and remains active while the Active Correlation Technology engine is running. | ||
<dateTime> | <never> | Y | Rule is activated at a specified date and time. Event Y deactivates the rule. | |
<dateTime> | <never> | X | Y | Rule is activated at a specified date and time. Event Y deactivates the rule, and event X reactivates it. This deactivation and reactivation can occur multiple times. |
<dateTime> | <after> | Rule is activated at a specified date and time and deactivated after a specified time interval. | ||
<dateTime> | <after> | X | Y | Rule is activated at a specified date and time and deactivated after a specified time interval. Event X activates the rule, and event Y deactivates it. This activation and deactivation can occur multiple times. |