We have an OSGi-based application that started consuming all open file handles available. The error observed in the application is ‘error 24 – too many open files’. Upon checking the VM with lsof command we could see that 90% of open file handles point to jar_cache.tmp* files in deleted state.
After some googling we could understand that “jar_cache*” files are created by the JVM process when it loads and caches JAR files.
Does anyone know when JVM is supposed to close these file handles? How can we influence the behavior of jar caching?