Frequently asked questions
If you have a question, tag it with java
and cics
and our
experts will find you on Stack Overflow.
You can also start and join discussions in IBM Developer and IBM Z and LinuxONE Community (see Get involved).
Find questions about ...
Education and resources
- What samples are available for developing with JCICS or JCICSX?
-
Try Java in your environment summarizes all the samples that you can download. Try Java in our sandbox offers a tutorial that you can work through in an IBM-hosted CICS environment.
Packaging and deployment
- Can I use Cradle or Maven build systems to build Java applications?
-
Yes. See Managing Java dependencies using Maven or Gradle for information. The tutorial Extend an existing Java application’s build to produce a CICS bundle in IBM Developer walks you through it.
Programming
- How do I handle record-orientated EDCDIC data in my Java program?
-
Typically, you need to map the data fields from a record structure to specific Java data types. There are tools to help you to do this:
- IBM Record Generator for Java generates Java helper classes from structured data, such as COBOL copybooks. See IBM Record Generator for Java V3.0.0 or work through a tutorial in IBM Developer: Build Java records from COBOL with IBM Record Generator.
- Java data bindings in IBM Developer for z/OS take data structures from COBOL, PL/I, and C source code and generate Java classes with setter and getter methods for accessing the fields within the records. Try this with the tutorial in IBM Developer: Generate Java records from COBOL with IBM Developer J2C tools.
- Can I pass a CICS COMMAREA to and from a CICS Java program?
- A COMMAREA is nothing more than an area of storage that is owned by the calling program and is made available to the called program. CICS does not care about the format or layout of the COMMAREA; it is entirely up to the two programs that are involved but those two programs must have exactly the same definition of the COMMAREA format to enable correct intercommunication. For a Java application to communicate with an application written in another language, you use a byte array to represent the COMMAREA and to hold the data to be transferred. Tools that generate the Java classes, such as IBM Record Generator for Java, make it easier to construct the required byte array.
JVM runtime
- Should I use a Liberty JVM server or an OSGi JVM server to deploy my Java applications in CICS?
- Your choice depends on what type of application you are running. See Which JVM server to use in CICS: Liberty or OSGi? for considerations.
- How many JVM servers can I run in a single CICS region?
- There is no configuration limit to the number of JVM servers that a CICS region can support. However, the threads and the MVS storage that are used by a JVM do have limits. A CICS region can support only 2000 CICS-enabled Java threads and each JVM can use 256 of these threads. Also, although a JVM is a 64-bit process, each JVM requires some 31-bit and 24-bit storage. In practice, this often means that the number of JVM servers per CICS region is limited by the available unallocated 31-bit MVS storage. This storage, in turn, primarily depends on the size of the private area that is allocated to the CICS extended dynamic storage area (EDSA), as defined by the EDSALIM system initialization parameter.
- What tools can I use to monitor the health of my JVM server?
- In addition to the traditional CICS administration facilities such as CEMT, system programming interface (SPI), transaction monitoring, and statistics, there are interfaces and diagnostic logs that are unique to the CICS JVM environment, including JVM stdout and stderr destinations, JVM dumps, OSGi log file, and CICS JVM trace. The IBM Monitoring and Diagnostic Tools for Java - Health Center is a no-charge low-overhead diagnostic tool for monitoring an application that runs on an IBM JVM. Find out more about all these facilities in IBM Redbooks: IBM CICS and the JVM server: Developing and Deploying Java Applications.