I'm having a problem using Java Mission Control when the application being profiled sets the XX:MaxJavaStackTraceDepth system property to -1.
To reproduce:
System: Ubuntu 14.04/amd64. Java 1.8.0_72.
Any suggestions to why this happens? I'd like to keep my stacktraces unlimited (due to some rare stack overflow exceptions which are very hard to find unless you have the beginning of the stack trace).
The -1 value comes from here: http://stas-blogspot.blogspot.se/2011/07/most-complete-list-of-xx-options-for.html#MaxJavaStackTraceDepth
Edit: The original question wrongly put the blame on java.endorsed.dirs system property. I had a bunch of property set and must have gotten confused in the process of elimination.
I've been able to reproduce the problem with -XX:MaxJavaStackTraceDepth=-1, and found at least one related bug - https://bugs.openjdk.java.net/browse/JDK-7179701, which is a low priority bug currently targeted for JDK 10.... My advice would be to use -XX:FlightRecorderOptions=stackdepth=2048 instead. I can't say I've done much experimenting with this option either, but at least it's designed to work with JFR.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With