TS/MP 2.5 Management Programming Manual

Event Management Programming for Pathway Subsystems
To process an event message, a management application must:
1. Start a copy of the EMS event distributor (EMSDIST).
2. Issue appropriate distributor programmatic commands, selecting the collector or log file from
which the events must be retrieved and specifying the filter to be used in selecting the events.
3. Issue a GETEVENT command to the EMS event distributor.
4. Use the EMSGET procedure to extract the event message from the response buffer and
individual tokens from the event message.
5. Perform the actions necessary to handle the event.
You can find general information about managing events as part of Distributed Systems Management
in the EMS Manual.
Event management information specific to the Pathway subsystem are.
Console Messages versus Event Messages
The PATHMON process generates error and status messages as console messages and event
messages. The event messages produce display-format messages when operated on by the EMSTEXT
procedure. Console messages and display-format messages are logically similar, but not identical
to each other.
NOTE: Message text can change from version to version. Your management application need
not depend upon the text generated by the EMSTEXT procedure.
Event messages have the same numbers corresponding to the console messages. For example,
status message 1005 (SHUTDOWN) has the same number as event message 1005
(ZPWY-EVT-PM-SHUTDOWN).
An event-message definition can be extended in any new version of TS/MP to include additional
tokens. Any token that is not identified as an unconditional token can be deleted from an
event-message definition.
Formatting Messages
In the interactive PATHCOM interface, the EVENTFORMAT attribute in the LOG1 and LOG2
commands specifies whether the PATHMON process format messages as text or as event messages.
Omitting EVENTFORMAT indicates that PATHMON process generate console messages; including
EVENTFORMAT indicates that PATHMON process generate event messages.
For example, these commands specify that all error, status, and warning messages are to be logged
to $0 as both event messages and console messages:
LOG1 $0, STATUS
LOG2 $0, STATUS, EVENTFORMAT
To control event-message generation through the Pathway subsystem Management Programming
interface, use the CONTROL PM command, assigning the value ZPWY-VAL-OFF or ZPWY-VAL-ON
to the ZEVENTFORMAT field in ZPWY-DDL-PAR-CONTROL-PM.
For the complete syntax of the PATHCOM LOG1 and LOG2 commands, see the TS/MP 2.5 System
Management Manual. For the complete syntax of the Pathway subsystem programmatic CONTROL
PM command, see “Pathway Subsystem Control Commands” (page 117).
When the PATHMON process is first started, an initial log file is opened for messages, as if you
had issued the PATHCOM command LOG1 file-name, STATUS. This initial file logs messages
until you specify a LOG1 command to indicate otherwise.
164 Event Management