The relevant Java code:
// its class extends Thread
// assigned a value in static initializer
public static volatile ClassLoader classLoader = null;
What happens when I try access it from Clojure:
user=> vemv.NGSession/classLoader
IllegalAccessException Class clojure.lang.Reflector can not access a member of class vemv.NGSession with modifiers "public static volatile" sun.reflect.Reflection.ensureMemberAccess (Reflection.java:95)
Fortunately I could reproduce the issue isolatedly, in the following class which has no dependencies/etc: https://gist.github.com/vemv/5180168If I try reproduce the issue absolutely from scratch though, it disappears:
package vemv;
public class Foo extends Thread {
public static volatile ClassLoader classLoader = null;
static {
try {
classLoader = Foo.class.getClassLoader();
} catch (SecurityException e) {
throw e;
}
}
}
Any ideas? Should I just open a bug report?