CICS as a service requester

For CICS to invoke an external service, an application program sends a request that is passed through a pipeline to a target service. The response from the service is returned to the application program through the same pipeline.

Figure 1 shows an example configuration of the architecture and resources that are required to process a request from a CICS application program for data from a service provider that is external to the CICS region, using a Java pipeline.

Figure 1. The architecture and resources for a service requester
The figure show a CICS application program in a CICS region initiating a request to a service provider that is external to the CICS region. The CICS region that the application program runs in also contains the PIPELINE, and WEBSERVICE resources; the pipeline and its handlers and a JVM server.
To process a request, CICS must perform the following operations:
  1. Build a request using data provided by the application program.

    When the CICS application program initiates a request to a service provider that is external to the CICS region, the requestor application calls the EXEC CICS INVOKE SERVICE command. The EXEC CICS INVOKE SERVICE command invokes the pipeline. The pipeline converts the application language structure into a language that the service provider can process, for example a SOAP message.

  2. Send the request to the service provider.

    CICS sends the request message to the remote service provider by using either HTTP or WebSphere MQ.

  3. Receive a response from the service provider.

    When the service provider response message is received, CICS passes the message back to the pipeline.

  4. Examine the response, and extract the contents that are relevant to the original application program.

    The pipeline converts the service provider response message into the application language structure, which is passed to the application program. Control is then returned to the application program.

Some of the processing within the pipeline can be performed using the zEnterprise® Application Assist Processor (zAAP) if the pipeline is configured appropriately. For more information, see Java-based SOAP pipelines.