For some strange reason, I have a line of code that gets stuck in an infinite loop. This is the line:
this.logger = LogManager.getLogger(getClass().getName());
A small context may be useful:
I have a machine that stores all the code and java files .class. I access this device through sshfsand work directly with files .javathrough Eclipse.
If I log on to the remote computer and execute my class, the code runs:
$ ssh remote-machine
$ cd /path/to/eclipse-project
$ export CLASSPATH="..."
$ java path.to.MyClass
Welcome, please do stuff
>>>
If I use the file system sshfsinstalled on my machine:
$ cd /mount-point/to/remote-machine
$ cd path/to/eclipse-project
$ export CLASSPATH="..."
$ java path.to.MyClass
<nothing happens>
I debugged through Eclipse what LogManager#getLoggeris the culprit. In fact, a little deeper, I saw that there is a cycle starting with index=2and ending only at class==null, at ClassLoaderContextSelector.java:86.