You can edit, debug, and compile COBOL applications to JVM byte code (.class files) so that they can be run on a Java Virtual Machine. The following limitations and restrictions apply:
This can be done by specifying 'cobjrun -Xjit:optLevel=cold ProgramName' (or 'java -Xjit:optLevel=cold ProgramName') to launch the program. For more information, see the topic Selectively disabling the JIT in the Java SDK documentation available on IBM's Web site.
For example:
If a COBOLClass1.cbl is within a package com.microfocus.core then it should be in the Project/src/com/microfocus/core/COBOLClass1.cbl directory. In the case the com.microfocus.core package is mapped to com/microfocus/core directory.
To determine whether you are experiencing this issue, type the following at the command line to check the number of semaphores that start with the 0xa1 prefix:
"ipcs -s -r | grep 0xa1 | wc –l"
If this number is very high and keeps growing you need to follow the cleanup procedure described in the "IBM Developer Kit and Runtime Environment Diagnostics Guide", "Chapter 19. Attach API problem determination", ftp://public.dhe.ibm.com/software/dw/jdk/diagnosis/diag50.pdf
You can disable the Java™ Attach APIs to avoid the issue. Note, however, that when Attach API is disabled, it will not be possible for other Java application to attach to your application and features such as jtop, jstat, jconsole, JMX agents, JVMTI agents will cease to function.
The Attach API is enabled by default for Java 6 SR6 and later. To disable the feature you need to set the IBM JVM property com.ibm.tools.attach.enable to "no".
You can use this property with any Java trigger, or with IBM’s environment variable IBM_JAVA_OPTIONS which allows you to pass extra arguments to the JVM without changing any command lines.
You can set the variable as follows:
export IBM_JAVA_OPTIONS=-Dcom.ibm.tools.attach.enable=no
However, the application must not contain a using clause in at least one static method or in the class itself.
When all of these criteria are met, the Run as COBOL JVM Application option is available.