milleruntime commented on issue #1976:
URL: https://github.com/apache/accumulo/issues/1976#issuecomment-808507891
The obfuscation in the classloading code makes it difficult to debug what is
going on. I was seeing a null context on the server side but I think that was a
red herring as it appears it wasn't making it to the server code. I finally
just printed the exception in the shell:
<pre>
java.lang.ClassNotFoundException: org.apache.accumulo.test.FooFilter
at java.net.URLClassLoader.findClass(URLClassLoader.java:471) ~[?:?]
at java.lang.ClassLoader.loadClass(ClassLoader.java:589) ~[?:?]
at
org.apache.accumulo.start.classloader.AccumuloClassLoader$1.loadClass(AccumuloClassLoader.java:212)
~[accumulo-start-2.1.0-SNAPSHOT.jar:2.1.0-SNAPSHOT]
at java.lang.ClassLoader.loadClass(ClassLoader.java:522) ~[?:?]
at
org.apache.accumulo.shell.commands.SetIterCommand.setUpOptions(SetIterCommand.java:211)
~[accumulo-shell-2.1.0-SNAPSHOT.jar:2.1.0-SNAPSHOT]
at
org.apache.accumulo.shell.commands.SetIterCommand.execute(SetIterCommand.java:103)
~[accumulo-shell-2.1.0-SNAPSHOT.jar:2.1.0-SNAPSHOT]
at org.apache.accumulo.shell.Shell.execCommand(Shell.java:779)
~[accumulo-shell-2.1.0-SNAPSHOT.jar:2.1.0-SNAPSHOT]
at org.apache.accumulo.shell.Shell.start(Shell.java:598)
~[accumulo-shell-2.1.0-SNAPSHOT.jar:2.1.0-SNAPSHOT]
at org.apache.accumulo.shell.Shell.execute(Shell.java:528)
~[accumulo-shell-2.1.0-SNAPSHOT.jar:2.1.0-SNAPSHOT]
at org.apache.accumulo.start.Main.lambda$execKeyword$0(Main.java:126)
~[accumulo-start-2.1.0-SNAPSHOT.jar:2.1.0-SNAPSHOT]
</pre>
I am not sure why the URLClassLoader is being used in this case as I would
assume DefaultContextClassLoaderFactory would be the default.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]