Amazing story about crashing JVM

A few days ago I’ve investigated API of one over price external library. One note this library is native, written using C++ and provides ports to other language in particular for Java using JNI.

So, I’ve started to run provided example all is OK, and I’ve decided to use this application to write my API using OSGI and Spring. Native example implements 5 interfaces and provides a lot of methods that I do not need to implement and I’ve used just a 3. Implemented methods of these interfaces and try to run tests, so, I was very surprised JVM was crashed!

I’ve started to investigate this problem, check all implementation of methods, all input parameters to the external library, tests but did not find any problems that can crache JVM. After it I’ve downloaded decompiler for java and C++ codes and start to investigate external library. And what was my astonishment when I found that JVM will be crashed if class (MY CLASS)/MY API does not implement one of the interface from external library(I did’t do it).

It is a hard story about API architecture and in what places JVM can be crashed..

Leave a Reply

Your email address will not be published.