Fix bootstrap classpath.

This commit is contained in:
Tyler Benson 2018-08-07 13:22:19 +10:00
parent 9b00a27dce
commit 5e55defeb3
1 changed files with 3 additions and 2 deletions

View File

@ -8,6 +8,7 @@ import java.net.URL;
public class Utils {
/* packages which will be loaded on the bootstrap classloader*/
public static final String[] BOOTSTRAP_PACKAGE_PREFIXES = {
"com.blogspot.mydailyjava.weaklockfree",
"io.opentracing",
"datadog.slf4j",
"datadog.trace.bootstrap",
@ -34,13 +35,13 @@ public class Utils {
private static Method findLoadedClassMethod = null;
private static BootstrapClassLoaderProxy unitTestBootstrapProxy =
private static final BootstrapClassLoaderProxy unitTestBootstrapProxy =
new BootstrapClassLoaderProxy(new URL[0], null);
static {
try {
findLoadedClassMethod = ClassLoader.class.getDeclaredMethod("findLoadedClass", String.class);
} catch (NoSuchMethodException | SecurityException e) {
} catch (final NoSuchMethodException | SecurityException e) {
throw new IllegalStateException(e);
}
}