![]() |
Copyright © TIBCO Software Inc. All Rights Reserved |
The following adapter agent methods use TIBCO Rendezvous. The header file relating to them is adapteragent.h and the link library relating to them is agent.lib for Microsoft Windows or libagent.so/libagent.sl for Unix.With regard to publication services, there are two methods for Asynchronous Rendezvous Adapter Agent, callPub() and callCArrayPub(). There are two methods for Synchronous Rendezvous Adapter Agent, callSyncPub() and callSyncCArrayPub().
• int callPub(char * serviceName, char * sendbuf, char * service, char * network, char * daemon, char * subject);This method is for publication services based on Asynchronous Rendezvous Adapter Agent. The user's Tuxedo service invokes the method to send the request which uses FML32/STRING buffers to TIBCO Rendezvous.char * serviceName— The name of the adapter service to be usedchar * sendbuf— The request buffer of type FML32/STRINGchar * service— The service parameter of the TIBCO Rendezvous transport which is used internallychar * network— The network parameter of the TIBCO Rendezvous transport which is used internallychar * daemon— The daemon parameter of the TIBCO Rendezvous transport which is used internallychar * subject— The message subject on which the message is to be sent from the Adapter Agent to the adapterThe method returns 1 on success, and 0 on failure. Error messages are written into the Tuxedo ULOG file.
• int callCArrayPub(char * serviceName, char * sendbuf, char * service, char * network, char * daemon, char * subject, long sendlen)This method is for publication services Asynchronous Rendezvous Adapter Agent. The user's Tuxedo service invokes the method to send the request which uses CArray buffers to TIBCO Rendezvous.char * serviceName— The name of the adapter service to be usedchar * sendbuf— The request buffer of type CArraychar * service— The service parameter of the TIBCO Rendezvous transport that is used internallychar * network— The network parameter of the TIBCO Rendezvous transport that is used internallychar * daemon— The daemon parameter of the TIBCO Rendezvous transport that is used internallychar * subject— The message subject on which the message is to be sentlong sendlen— The length of the CArray buffer to be sentThe method returns 1 on success, and 0 on failure. Error messages are written into the Tuxedo ULOG file.
• int callSyncPub(char * serviceName, char * sendbuf, char * service, char * network, char * daemon, char * subject, unsigned long agentTimeout);This method is for publication services based on Synchronous Rendezvous Adapter Agent. The user's Tuxedo service invokes the method to send the request which uses FML32/STRING buffers to TIBCO Rendezvous, and then the agent waits for the feedback from the adapter.char * serviceName— The name of the adapter service to be usedchar * sendbuf— The request buffer of type FML32/STRINGchar * service— The service parameter of the TIBCO Rendezvous transport which is used internallychar * network— The network parameter of the TIBCO Rendezvous transport which is used internallychar * daemon— The daemon parameter of the TIBCO Rendezvous transport which is used internallychar * subject— The message subject on which the message is to be sent from the agent to the adapterThe method returns 1 on success, and 0 on failure. Error messages are written into the Tuxedo ULOG file.
• int callSyncCArrayPub(char * serviceName, char * sendbuf, char * service, char * network, char * daemon, char * subject, long sendlen, unsigned long agentTimeout)This method is for publication services based on Synchronous Rendezvous Adapter Agent. The user's Tuxedo service invokes the method to send the request which uses CArray buffers to TIBCO Rendezvous, and then the agent waits for the feedback from the adapter.char * serviceName— The name of the adapter service to be usedchar * sendbuf— The request buffer of type CArraychar * service— The service parameter of the TIBCO Rendezvous transport that is used internallychar * network— The network parameter of the TIBCO Rendezvous transport that is used internallychar * daemon— The daemon parameter of the TIBCO Rendezvous transport that is used internallychar * subject— The message subject on which the message is to be sentlong sendlen— The length of the CArray buffer to be sentunsigned long agentTimeout — The timeout of the agent in seconds.The method returns 1 on success, and 0 on failure. Error messages are written into the Tuxedo ULOG file.When some abnormal situations occur, callPub or callCArrayPub will still return a success message, but callSyncPub or callSyncCArrayPub will report the errors by returning a failure message, which is received from the adapter. Those situations are as follows:
− The serviceName (the first parameter of each method) is different from the Name in the Configuration tab of Publication Service configured in TIBCO Designer.
− The subject (the six parameter of each method) is different from the Subject in the Configuration tab of PubAgentSubscriber (TuxedoAdapterConfiguration>Advanced>Sessions>DefaultRVSession>PubAgentSubscriber) configured in TIBCO Designer.
• int callClient (char * serviceName, char * sendbuf, unsigned long adapterTimeout, char * service, char * network, char * daemon, unsigned long agentTimeout, char * subject, void** replyBuf)This method is for Resquest-Response invocation services. The user's Tuxedo service invokes the method to send the request which uses FML32/STRING buffers to TIBCO Rendezvous.char * serviceName—The name of the adapter service to be usedchar * sendbuf—The request buffer of type FML32/STRINGunsigned long adapterTimeout— The timeout of the adapter in secondschar * service—The service parameter of the TIBCO Rendezvous transport that is used internallychar * network— The network parameter of the TIBCO Rendezvous transport that is used internallychar * daemon— The daemon parameter of the TIBCO Rendezvous transport that is used internallyunsigned long agentTimeout— The timeout of the agent in secondschar * subject— The message subject on which the message is to be sent from the Adapter Agent to the adaptervoid ** replyBuf— The address of the reply buffer of type FML32/STRING. The replyBuf must be allocated by tpalloc.The method returns 1 on success, and 0 on failure. Error messages are written into the Tuxedo ULOG file.
• int callCArrayClient(char * serviceName, char * sendbuf, unsigned long adapterTimeout, char * service, char * network, char * daemon, unsigned long agentTimeout, char* subject, void** replyBuf, long sendlen, unsigned int* rcvlen)This method is for Request-Response invocation services. The user's Tuxedo service invokes the method to send the request which uses CArray buffers to TIBCO Rendezvous.char * serviceName—The name of the adapter service to be usedchar * sendbuf—The request buffer of type CArrayunsigned long adapterTimeout— The timeout of the adapter in secondschar * service—The service parameter of the TIBCO Rendezvous transport that is used internallychar * network— The network parameter of the TIBCO Rendezvous transport that is used internallychar * daemon— The daemon parameter of the TIBCO Rendezvous transport that is used internallyunsigned long agentTimeout— The timeout of the agent in secondschar * subject— The message subject on which the message is to be sent from the Adapter Agent to the adaptervoid ** replyBuf— The address of the reply CArray buffer. The replyBuf must be allocated by tpalloclong sendlen—The length of the CArray buffer to be sentunsigned int* rcvlen—The address of a integer to return the length of replyBufThe method returns 1 if successful, and 0 if it failed. Error messages are written into the Tuxedo ULOG file.
![]() |
Copyright © TIBCO Software Inc. All Rights Reserved |