
VTCPD Application Programming
P0602483 Ver: 03.41 Page 89
Host Responses From Any Connection
The host response normally arrives through the connection the application used to
send the request. VTCPD can also be configured to route host responses from any
connection (vtcpd -md) (see Message Routing on page 53.)
If VTCPD is configured to route host responses from any connection, internal
message processing is delayed slightly.
Asynchronous Replies and Reply Notification
Normally, if the host message is not available when an application executes a
Resource block to receive a message, the application pauses (blocks). However,
VTCPD can be configured for asynchronous data delivery (vtcpd -m a) (see
Asynchronous Replies and Reply Notification on page 89.)
If VTCPD is configured for asynchronous data delivery and the application has not
already executed the Resource block to receive the message, VTCPD sends the
message to the application as condition data associated with unexdata. The
application can retrieve the data from the System.ConditionData data card.
VTCPD can also be configured to notify the application when the host sends a
message (vtcpd -m n). When the host message arrives, VTCPD notifies the
application by generating unexdata. In this configuration, when the application
receives unexdata it should execute a Resource block to receive the message.
Retrieving Unidentified Host Data
Normally, if the host data contains a message ID that VTCPD cannot associate with a
phone line, VTCPD discards the message. However, VTCPD can be configured to
route all unidentified host data to a particular phone line that is running an
administrative application (vtcpd -a#) (see Unidentified Host Data on page 62.)
In this configuration, VTCPD sends the unidentified messages to the administrative
line as condition data associated with unexdata. The application can retrieve the
data from the System.ConditionData data card.
There are several important considerations for an administrative application designed
to retrieve unidentified host messages:
• VTCPD sends these message asynchronously. To avoid possible race conditions,
the administrative application should not execute any blocks that pause the
execution of the application.
• In most circumstances, the administrative application should not restart. If the
application restarts, it can lose messages that arrive during the transition period.
However, to properly reconnect to VMST, the application must restart if it
receives linkdown.
The following demonstrates the implementation of an administrative application:
Kommentare zu diesen Handbüchern