DSM/SCM Event Management Programming Manual

SPI Programming Considerations for DSM/SCM
DSM/SCM Event Management Programming Manual529844-003
3-4
Creating and Loading a Standard Filter
where:
You can also write your own applications to start a consumer distributor, send a
filter, and retrieve events using Subsystem Programmatic Interface (SPI)
commands. For more information on event management and a list of all
parameters for the filter compiler and the EMSDIST program, see the EMS
Manual.
The filter specifications in Example 3-1 select DSM/SCM event messages based on
their activity ID and the DSM/SCM component that generated them.
$DPHI is the name of the distributor process.
[\system].$0 is the primary collector process.
[\system].$ZPHI is the alternate collector process.
filtrobj is the filter object file.
yyyy-mm-dd
hh:mm
specifies the date and time when the distributor starts examining
events.
evtsfile is a disk file that will contain the filtered events.
printing | P specifies the type of distributor to be started. In this case, it is
type P for a printing distributor.
Example 3-1. Filter Source Statements for DSM/SCM Events (page1of2)
==
== Filter file for the DSM/SCM subsystem
== The filter is set on the ACTIVITY ID and the range of ACTIVITY codes.
==
[#SET ZPHI^VAL^SSID [ZPHI^VAL^TANDEM].[ZPHI^SSN^DSMSCM].[ZPHI^VAL^VERSION] ]
FILTER filter^component^event ( SSID ( ZPHI^VAL^SSID, ZPHI^TKN^FLT^ACT^ID )
, SSID (ZPHI^ACT^VAL^SSID)
BEGIN
IF ZSPI^TKN^SSID = SSID (ZPHI^VAL^SSID) THEN
BEGIN
==
== If the CONFIGURATION BUILDER
==
IF ZPHI^TKN^FLT^CMPNT^CD = 2 THEN
BEGIN
IF ( ( ZPHI^TKN^ACTIVITY^CD = 10 )
AND ( ZPHI^TKN^ACTIVITY^ID = ZPHI^TKN^FLT^ACT^ID )) THEN PASS;
END;
==
== If the TARGET ACTIVATOR
==
IF ZPHI^TKN^FLT^CMPNT^CD = 3 THEN
BEGIN
IF (( ZPHI^TKN^ACTIVITY^CD = 20 OR
ZPHI^TKN^ACTIVITY^CD = 30 OR
ZPHI^TKN^ACTIVITY^CD = 40 OR
ZPHI^TKN^ACTIVITY^CD = 45 OR
ZPHI^TKN^ACTIVITY^CD = 90 OR
ZPHI^TKN^ACTIVITY^CD = 100 ) AND
( ZPHI^TKN^ACTIVITY^ID = ZPHI^TKN^FLT^ACT^ID ))THEN PASS;
END;
==