DatasetMonitor events
Use this function to create event rules and trigger events
DatasetMonitor
events are: ReadCompleted
ModificationCompleted
Event type | Event trigger |
---|---|
A data set is closed after it was opened in read mode. | |
A data set is closed after it was opened in write mode. This event is sent also when you create an empty data set. |
attributeFilter name | Type | Required | Wilcard allowed | Length (min-max) | Default value | |
---|---|---|---|---|---|---|
FileName | string | ✓ | ✓ | 1 | 44 |
Note: For parameters with wildcard allowed, you can use the following wildcards:
- *
- To match any sequence of characters.
- ?
- To match any single character. For example, if you specify AB?, ABC is a match, AB or ABCD are not a match.
- %
- For compatibility with earlier versions, it is supported for the same function as ?.
The following list provides a detailed description of the parameters:
- FileName
- Specifies the data set name to be monitored for actions on special resources. For details about
how the Agent requests to change the resource availability, based on the specified
FileName
value.
Click here to see the Dynamic Workload Console fields for each event type.
Examples
The following examples show how to combine language elements and use wildcards:<?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/EventRules.xsd">
<eventRule name="FILE_MONITOR_FILE_CREATED" ruleType="filter" isDraft="no">
description>Event: File Created; Action: Send mail/description>
validity to="2012-04-22" />
<eventCondition name="fileCrtEvt1" eventProvider="FileMonitor" eventType="FileCreated">
<scope>/HOME/BOOK.TXT ON EDITOR_WRKSTN</scope>
<filteringPredicate>
<attributeFilter name="FileName" operator="eq">
<value>/home/book.txt</value>
</attributeFilter>
<attributeFilter name="SampleInterval" operator="eq">
<value>60</value>
</attributeFilter>
<attributeFilter name="Workstation" operator="eq">
<value>editor_wrkstn</value>
</attributeFilter>
<attributeFilter name="Hostname" operator="eq">
<value>ceditor</value>
</attributeFilter>
</filteringPredicate>
</eventCondition>
<action actionProvider="MailSender" actionType="SendMail" responseType="onDetection">
<description>Send an eMail</description>
<scope>SAUL.FELLOW@US.IBM.COM, ISAAC.LINGER@US.IBM.COM : THE EXPECTED FILE
HAS BEEN CREATED!</scope>
<parameter name="Cc">
<value>william.waulkner@us.ibm.com</value>
</parameter>
<parameter name="Bcc">
<value>ernest.demingway@us.ibm.com</value>
</parameter>
<parameter name="Body">
<value>The expected file was created!
The book is ready to be published.</value>
</parameter>
<parameter name="To">
<value>saul.fellow@us.ibm.com, isaac.linger@us.ibm.com</value>
</parameter>
<parameter name="Subject">
<value>The expected file was created!</value>
</parameter>
</action>
</eventRule>
</eventRuleSet>