OSI/TS Management Programming Manual
Sample Programs
056786 Tandem Computers Incorporated C–15
Sample Event-
Message Filters
The Event Management Service (EMS) distributor collects event messages from the
subsystems running in your system or network, stores them in an event log, and
returns to your application only those that pass the filter you have installed. By using
filters, you can limit the event messages your application receives to those of interest.
Note If you do not install a filter, EMS returns all event messages it receives from subsystems running on your
local system. Since the total number of event messages can be very large, it is recommended that you
always install a filter if you are using EMS.
You can use any of the tokens in an event message to select the event messages to be
returned to an application. You can create filters that return only critical event
messages, all messages associated with a particular device, all messages with a certain
event number, and so forth.
The following two example filter source files illustrate typical filters you might want to
use to capture event messages related to OSI/TS. The source code file for these
examples are provided as part of the OSI/TS software. They reside (by default) in
$SYSTEM.ZOSITS.EXFLT1 and $SYSTEM.ZOSITS.EXFLT2.
Note To use these filters, you must change the system name to reflect your own environment.
Filter Example: All OSI-
Related Messages
The following filter selects all event messages reported by the OSI/TS, OSI/AS,
X25AM, and TLAM subsystems on the system \MYSYS. To compile this filter, you
must have OSI/AS and both X25AM and TLAM; otherwise, you must delete the
statements that pertain to the subsystems you are not using.
== File: EXFLT1
==
== This EMS filter selects all event messages
== originating from the OSI/TS, OSI/AS, X25AM, and TLAM
== subsystems on the system \MYSYS.
==
FILTER osi^layer^msgs;
BEGIN
--Initialize subsystem IDs
[#set zos4^val^ssid
[zspi^val^tandem].[zspi^ssn^zos4].[zos4^val^version] ]
[#set zosi^val^ssid
[zspi^val^tandem].[zspi^ssn^zosi].[zosi^val^version] ]
[#set zx25^val^ssid
[zspi^val^tandem].[zspi^ssn^zx25].[zx25^val^version] ]
[#set zlam^val^ssid
[zspi^val^tandem].[zspi^ssn^zlam].[zlam^val^version] ]
IF zems^tkn^system = [#SYSTEMNUMBER \MYSYS] AND
(zspi^tkn^ssid = ssid(zos4^val^ssid) OR
zspi^tkn^ssid = ssid(zx25^val^ssid) OR
zspi^tkn^ssid = ssid(zlam^val^ssid) OR
zspi^tkn^ssid = ssid(zosi^val^ssid)) THEN