HCL Workload Automation, Version 9.4

Monitoring the HCL Workload Automation message queues

You can use event-driven workload automation (EDWA) to monitor the size of message queues and to start a predefined set of actions when one or more specific events take place. For more information about event-driven workload automation, refer to HCL Workload Automation: User's Guide and Reference.

You can monitor the following message queues:
  • appserverbox
  • mailbox
  • clbox
  • intercom
  • courier
  • monbox
  • moncmd
  • server
  • tomaster
  • pobox
  • planbox
The following .XML file contains the definition of a sample event rule to monitor the mailbox queue on the specified workstation and send an email when the filling percentage is greater than the specified value. If the condition described in the rule is already existing when you deploy the rule, the related event is not generated. This event rule calls the MailSender action provider to send an email to the receivers you specify. For more information about the MailSender action provider, refer to HCL Workload Automation: User's Guide and Reference:
<?xml version="1.0"?>
<eventRuleSet 	xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
		xmlns="http://www.ibm.com/xmlns/prod/tws/1.0/event-management/rules"
		xsi:schemaLocation="http://www.ibm.com/xmlns/prod/tws/1.0/event-management/rules 
			http://www.ibm.com/xmlns/prod/tws/1.0/event-management/rules/EventRules.xsd">
	<eventRule name="MONITORQUEUE" ruleType="filter" isDraft="no">
		<eventCondition name="twsMesQueEvt1" eventProvider="TWSApplicationMonitor" eventType="TWSMessageQueues">
			<scope>
				MAILBOX FILLED UP 80% ON FTA
			</scope>
			<filteringPredicate>
				<attributeFilter name="MailboxName" operator="eq">
					<value>mailbox_name</value>
				</attributeFilter>
				<attributeFilter name="FillingPercentage" operator="ge">
					<value>filling_percentage</value>
				</attributeFilter>
				<attributeFilter name="Workstation" operator="eq">
					<value>workstation_name</value>
				</attributeFilter>
				<attributeFilter name="SampleInterval" operator="eq">
					<value>sample_interval</value>
				</attributeFilter>
			</filteringPredicate>
		</eventCondition>
		<action actionProvider="MailSender" actionType="SendMail" responseType="onDetection">
			<scope>
				TWSUSER@TWS : THE MAILBOX ON workstation_name...
			</scope>
			<parameter name="To">
				<value>main_receiver_list</value>
			</parameter>
			<parameter name="Subject">
				<value>mail_subject</value>
			</parameter>
		</action>
	</eventRule>
</eventRuleSet>
where:
mailbox_name
Is the name of the mailbox to monitor.
filling_percentage
Is the filling percentage. Supported operators are as follows:
ge
causes the event generation when the mailbox filling percentage increases over the threshold value. The event is generated only the first time the specified mailbox filling percentage is reached. If you restart the SSM agent and the filling percentage is higher than the threshold value, the event is generated again. Table 1 provides an example in which the ge operator is set to 70%.
Table 1. Example for the ge operator
Mailbox name Filling percentage Action
Sample (0) >= 70% event not generated
Sample (0) < 70% event not generated
Sample (n-1) < 70% event not generated
Sample (n) >= 70% event generated
Sample (n+1) >= 70% event not generated
le
causes the event generation when the mailbox filling percentage decreases under the threshold value. The event is generated only the first time the specified mailbox filling percentage is reached. If you restart the SSM agent and the filling percentage is lower than the threshold value, the event is not generated until the filling percentage increases over the threshold value and then decreases under it again. Table 2 provides an example in which the le operator is set to 50%:
Table 2. Example for the le operator
Mailbox name Filling percentage Action
Sample (0) <= 50% event not generated
Sample (0) > 50% event not generated
Sample (n-1) > 50% event not generated
Sample (n) <= 50% event generated
Sample (n+1) <= 50% event not generated
workstation_name
Is the workstation on which the event is generated.
sample_interval
Is the interval, expressed in seconds, for monitoring the mailbox filling percentage.
main_receiver_list
Is the main receiver list.
mail_subject
Is the subject of the mail.