This tutorial describes how to use the J2C Java™ Bean
wizard to build a simple Web application that processes a CICS® transaction
with multiple possible outputs.
This tutorial
might require some optionally installable components. To ensure that you have
installed the appropriate optional components, see the System requirements
list.
This
tutorial will lead you through the detailed steps to generate a J2C application
that interfaces with a CICS transaction using an External Call Interface (ECI).
The service is built from a CICS COBOL function, getCustomerInfo, which accepts
a customer number. Depending on the customer's classification, preferred customer,
regular customer or bad customer, the program returns different output information
about the customer.

This tutorial is divided into several exercises
that must be completed in sequence for the tutorial to work properly. This
tutorial teaches you how to use the J2C Java bean wizard to connect to a CICS ECI server.
While completing the exercises, you will:
- Use the J2C Java bean wizard to create a J2C application that interfaces
with a CICS transaction
using an External Call Interface (ECI).
- Create a Java method, getCustomerInfo, which
accepts a customer number. Depending on the customer's classification, preferred
customer, regular customer or bad customer, the program returns different
output information about the customer.
- Create a Java class, TestECIMPO.java to test your application.
Time required
This tutorial should take approximately
30 minutes to finish. If you explore other concepts related to this tutorial,
it could take longer to complete.
Skill level
Experienced
Audience
This tutorial is intended for users who
are familiar with Enterprise Information systems (EIS) and CICS ECI in particular.
System requirements
To complete this tutorial,
you need to have the following tools and components installed:
- IBM® WebSphere® Application Server, version 6.1
- J2EE Connector (J2C) tools
- Connection to a CICS ECI server: In this tutorial, your application
interacts with a CICS program on a server. Specifically, you need to
set up a CICS transaction
gateway on a machine to access the server. You also need to perform some setup
work on the CICS server
machine, where you want the CICS to run. These steps are not covered.
- A copy of the COBOL file taderc25.cbl. You may locate this file
in your product installation directory: <installdir>\IBM\SDP70Shared\plugins\com.ibm.j2c.cheatsheet.content_7.0.0\Samples\CICS\taderc25.
If you wish to store it locally, you can copy the code from here: taderc25.cbl
- A clean workspace.
To use this tutorial, you must have an application
server installed and configured. To verify that a server runtime environment
is available, click , expand Server, and then click Installed
Runtimes. You can use this pane to add, remove, or edit installed
server runtime definitions. You can also download and install support for
a new server.
Prerequisites
In order to complete this tutorial
end to end, you should be familiar with:
- J2EE and Java programming
- COBOL programming language
- CICS ECI
server technology