To deal with incoming requests for a JVM, CICS takes the actions summarized
in
Figure 1:
Figure 1. Dealing with incoming
requests for JVMs
- When CICS receives a request for a JVM, and a JVM of the correct profile
and execution key is free, CICS assigns the JVM to the incoming request.
- If CICS receives a request for a JVM when either:
- there are no free JVMs
- there are free JVMs, but they are not of the correct profile and execution
key for the request
and CICS is able to create more JVMs (because the
MAXJVMTCBS limit has not been reached and MVS storage is not severely constrained),
then a TCB is allocated and a new JVM is created for the request.
- If CICS receives a request when there are free JVMs, but they are not
of the correct profile and execution key, and CICS is not able to create more JVMs (because the MAXJVMTCBS limit has been reached
or MVS storage is severely constrained), the selection mechanism is used.
The selection mechanism decides whether the request should wait for a suitable
JVM, or whether it should receive one of the free JVMs.
- If the request receives one of the free JVMs, there will be either a mismatch
or a steal, and the JVM and possibly the TCB will need to be re-initialized,
so the selection mechanism avoids this where it makes sense to do so. If the
selection mechanism does decide that the request should receive one of the
free JVMs, CICS checks whether the execution key specified by the request
matches the execution key of the JVM. If the execution key does not match,
the JVM and its TCB are destroyed and reinitialized (a steal). If the execution
key does match, and only the JVM profile is incorrect, the JVM is reinitialized
on the same TCB (a mismatch).
- If the selection mechanism decides that the request should wait rather
than receiving one of the free JVMs, the request is placed on the queue to
wait for a suitable JVM to become free.
- If CICS receives a request when there are no free JVMs, and CICS is not able to create more JVMs (because the MAXJVMTCBS limit has been
reached or MVS storage is severely constrained), the request is placed on
the queue to wait for a JVM to become free.