During pre-main class execution, there is a call to
ManagementFactory.getPlatformMBeanServer()
at line MBeanSampler.java:33
In JBoss, getPlatformMBeanServer() then tries to initialize a logger before it is safe to do so.
Therefore, we need to find a way to make this initialization take place later or catch the exception here and try again later.