Multiple javadriver threads

You can use multiple Java driver threads in one process by setting a USE_LOADER=true directive in the pni file.

This cannot be used on the GUI side.

When the GUI saves NetConfig:

  • If one Java driver is found in one process, then the use_loader key is removed.
  • If multiple Java drivers are found in one process, then the original value of use_loader is retained, if there is any; otherwise, use_loader=true is updated in the pni file.

A warning message then opens, stating that multiple javadriver threads are detected in one process.

The engine with the directive can have each thread load a class in its own thread local urlclassloader without interfering with each other on the process level. However, you can create in your own code a classloader that can be shared among threads. This results in classes that will not be recycled after the CIS engine thread is down. In this case, you must carefully manage the classloader. In a similar manner, this can also happen in the Spring context. This opens an additional warning message..