Classes on the stack trace (was: getElementClass/StackTraceElement, was: @CallerSensitive public API, was: sun.reflect.Reflection.getCallerClass)

Paul Benedict pbenedict at apache.org
Mon Jul 29 13:50:07 UTC 2013


If it is not possible in the remaining dev time for JDK8 to expose
Reflection.getCallerClass() functionality through some public API, why must
-Djdk.reflect.allowGetCallerClass be discontinued so soon? Why the hot
potato? I don't see how impacting the many (most? or all?) open source
logging libraries is a good idea.

With the argument of "you shouldn't be using private sun.* classes" aside,
it seriously needs to be evaulted rather causing such commotion is
worthwhile. I would like Oracle to reconsider dropping the System property
workaround until an API can be put in place.

-- 
Cheers,
Paul



More information about the core-libs-dev mailing list