Non-managed (client-managed) callout programming model
You can use the non-managed callout programming model to retrieve IMS application callout requests from any external Java™ applications that do not use a message-driven bean.
For any response data to a callout request, the Java application can send the response data either synchronously to the same IMS application in the same transaction or asynchronously in a different transaction.
For a synchronous callout request, unlike in the managed callout programming model where the callout protocol and response correlation are handled for you through the message-driven bean, you must handle the following issues in your Java application:
- Handle the callout protocol in your application to poll the hold queue for any callout messages.
- Ensure that the correlation token that is attached to the callout request is passed back with the response in order for the response to be correlated back to the initiating request.
Because you must handle the synchronous callout protocol and the correlation of response messages to the request, this programming model is also called client-managed callout programming model.
In general, the following tasks are required when you use the client-managed callout programming model:
- Your WebSphere® Application Server administrator must configure a shareable connection factory to be used by the Java application to retrieve the callout requests.
- Retrieve the callout messages from the IMS OTMA hold
queue (tpipe).
- For synchronous callout requests:
- You must correlate the response from the EJB application to the callout request. For more information, see Correlating the response from the Java application to the synchronous callout request
- Follow the steps described in Retrieving synchronous callout request messages from non-MDB applications
- For asynchronous callout requests, see Retrieving asynchronous callout request messages from non-MDB applications.
- For synchronous callout requests:
You can enable the send-only-with-acknowledgment protocol. Using this protocol, IMS TM Resource Adapter receives an acknowledgment from IMS when IMS receives a synchronous callout response message. In Version 13 and earlier, this acknowledgment is unavailable.
You can enable connection pooling for sychronous callout messages that are sent back to IMS. In Version 13 and earlier, the IMS TM Resource Adapter must create and then discard a new connection whenever a callout response is sent. By enabling connection pooling, you can avoid the overhead of opening and closing multiple connections.