Upcoming Apama 10.11 release information – Java® 11

What is changing?

Existing 10.x versions of Apama come with a Java® 8 JDK, but the upcoming October 2021 release of Apama 10.11 will come with a Java 11 JDK. This means all Java code executed by correlator and IAF processes will be executed with Java 11.

Some of the most notable changes in the new Java version are:

  • Removal of some APIs including JAXB (see JEP 320)
  • The default garbage collector has changed from Parallel GC to G1GC

Some key points about G1GC from Oracle® are as follows:

  • The Garbage-First (G1) garbage collector is targeted for multiprocessor machines with a large amount of memory.
  • G1 may exhibit higher overhead than other collectors, affecting throughput due to its concurrent nature.
  • G1 can reclaim some completely empty, large areas of the old generation during any collection. This could avoid many otherwise unnecessary garbage collections, freeing a significant amount of space without much effort.
  • G1 can optionally try to deduplicate duplicate strings on the Java heap concurrently.

The change to the default garbage collector will affect every application differently. If your application suffers decreased performance or increased memory usage from this change then you may wish to tune G1GC’s parameters or use a different garbage collector. You can specify arguments to the JVM used by Apama by prefixing them with “-J”, for example to enable G1GC’s string deduplication you would specify “-J-XX:+G1EnableStringDeduplication“.

Why is it changing?

Java 8 is nearing end of support and Java 11 is the most recent LTS version available.

What does this mean for me?

If you have written any EPL, connectivity or IAF plug-ins for Apama that are affected by the differences between Java 8 and Java 11 then you may need to make some changes to be able to use those plug-ins with Apama 10.11+.

To prepare for this upgrade there are a few things you can do:

  • Run the jdeps tool to identify use of deprecated or internal APIs in your application
  • If you are using any APIs that are not included with Java 11 (e.g. JAXB), then download them and include them with your project separately
  • Update third-party libraries you may be using
  • Resolve any compiler warnings

There are many resources online regarding migration from Java 8 to Java 11, here are a few links to get you started: