Stacktrace lambdas authentication in Java 8

I am trying to profile a Java application that uses lambdas using JProfiler. I am having trouble identifying, which will scan the profiler as a hot spot:

profiler screenshot

I would appreciate any help in understanding the stack trace format using lambda, for example, "edu.indiana.soci.spidal.vectorclass.lambda $ PairwiseThread_SecDrv $ 23"

Thanks!

+4
source share
1 answer

Unfortunately, there is no direct way to identify a lambda, because lambdas have no name by nature. At runtime, lambdas are currently implemented with anonymous classes. They are numbered sequentially after the $ sign relative to the containing class.

If you enable line number resolution in the JProfiler parameter (session settings-> tab profiling-> configure-> on the "record the method call" tab), you will see the line number in the "run" method in the trail of the back spot, which should help you find the lambda if this is the only lambda on this line.

+1
source

All Articles