OpenTP1 Version 7 Programming Guide
Reception-dedicated application programs created in the system can be notified of OpenTP1 message logs. The application program, upon receiving a notification, can notify other vendors' network management system of the OpenTP1 status.
To enable message log notification, assign Y to the log_notify_out operand in the OpenTP1 log service definition.
Only application programs created for reception can receive message log notification. OpenTP1 UAPs (SUPs, SPPs, and MHPs) cannot receive a message log notification.
When receiving a notification, the application program uses OpenTP1 functions. When writing an application program, include the header file of the OpenTP1 log service and link the OpenTP1 library.
For an application program to receive a notification, the environment variable DCDIR that identifies the OpenTP1 home directory must be set. The value assigned to this environment variable must be the same as for the OpenTP1 that will send the message log notification.
If you need all message logs generated since OpenTP1 online operation started, the application program to receive notifications must be started before the OpenTP1.
The application program to receive notifications must declare the starting of reception using the function dc_log_notify_open(). It receives message logs using the function dc_log_notify_receive(). Only one message log can be received by one run of the function dc_log_notify_receive(). To receive multiple message logs, repeatedly invoke the function dc_log_notify_receive().
To terminate receiving message log notifications, invoke the function dc_log_notify_close(). Even after invoking the function dc_log_notify_close(), you can restart receiving message log notifications by invoking the function dc_log_notify_open().
Even after the OpenTP1 terminates, the notification reception application program continues to wait until the function dc_log_notify_close() is invoked. To notify a waiting application program of reception completion, send data from another application program using the function dc_log_notify_send(). The application program for reception completion notification cannot invoke the function dc_log_notify_open() before invoking the function dc_log_notify_send().
The figure below shows the reception of a message log notification.
Figure 2-55 Reception of message log notification
Notes on receiving message log notifications are given below.
All Rights Reserved. Copyright (C) 2006, 2010, Hitachi, Ltd.