Jetty ClassNotFoundException on Jetty 9.2.10.v20150310
See original GitHub issueI am running a custom build of specialagent. I tried using the rule ‘specialagent-web-servlet-filter’, by setting the Jetty version to the one I needed, but keeping everything else unchanged. When I do so, I seem to get some strange classloading issues.
One that I can’t overcome yet is this ClassNotFoundException:
2019-08-07 14:18:51,95947 java.lang.NoClassDefFoundError: org/eclipse/jetty/http/HttpMethod
2019-08-07 14:18:51,95950 at org.eclipse.jetty.servlets.GzipFilter.init(GzipFilter.java:200)
2019-08-07 14:18:51,95950 at org.eclipse.jetty.servlets.IncludableGzipFilter.init(IncludableGzipFilter.java:59)
2019-08-07 14:18:51,95950 at org.eclipse.jetty.servlet.FilterHolder.initialize(FilterHolder.java:138)
2019-08-07 14:18:51,95951 at org.eclipse.jetty.servlet.ServletHandler.initialize(ServletHandler.java:852)
2019-08-07 14:18:51,95951 at org.eclipse.jetty.servlet.ServletContextHandler.startContext(ServletContextHandler.java:298)
2019-08-07 14:18:51,95952 at org.eclipse.jetty.webapp.WebAppContext.startWebapp(WebAppContext.java:1349)
2019-08-07 14:18:51,95952 at org.eclipse.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1342)
2019-08-07 14:18:51,95953 at org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandler.java:741)
2019-08-07 14:18:51,95955 at org.eclipse.jetty.webapp.WebAppContext.doStart(WebAppContext.java:505)
2019-08-07 14:18:51,95956 at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68)
2019-08-07 14:18:51,95956 at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:132)
2019-08-07 14:18:51,95957 at org.eclipse.jetty.server.Server.start(Server.java:387)
2019-08-07 14:18:51,95957 at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:114)
2019-08-07 14:18:51,95957 at org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:61)
2019-08-07 14:18:51,95958 at org.eclipse.jetty.server.Server.doStart(Server.java:354)
2019-08-07 14:18:51,95959 at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68)
2019-08-07 14:18:51,95960 at com.example.eslauncher.CoreServerInstance.startAndJoinThread(CoreServerInstance.java:139)
2019-08-07 14:18:51,95960 at com.example.eslauncher.JettyServer.main(JettyServer.java:87)
2019-08-07 14:18:51,95960 Caused by: java.lang.ClassNotFoundException: org.eclipse.jetty.http.HttpMethod
2019-08-07 14:18:51,95961 at java.net.URLClassLoader.findClass(URLClassLoader.java:382)
2019-08-07 14:18:51,95962 at org.eclipse.jetty.webapp.WebAppClassLoader.findClass(WebAppClassLoader.java:510)
2019-08-07 14:18:51,95962 at org.eclipse.jetty.webapp.WebAppClassLoader.loadClass(WebAppClassLoader.java:441)
2019-08-07 14:18:51,95962 at org.eclipse.jetty.webapp.WebAppClassLoader.loadClass(WebAppClassLoader.java:403)
2019-08-07 14:18:51,95963 ... 18 common frames omitted
Any ideas of what is causing this? I realize that it is likely a Jetty version mismatch, since these rules targeted a later version, but any ideas would be helpful of where to start.
Issue Analytics
- State:
- Created 4 years ago
- Comments:60
Top Results From Across the Web
Getting java.lang.ClassNotFoundException: org.eclipse.jetty ...
cd jetty-distribution-9.2.10.v20150310 $ jar -xvf ... MF Export-Package: org.eclipse.jetty.servlet;version="9.2.10",org.eclipse ...
Read more >[jetty-users] Trouble with CGI - Eclipse
ClassNotFoundException : org.eclipse.jetty.servlets.CGI ... I'm on jetty-distribution-9.2.10.v20150310 (on Oracle Java 1.8.0_40 on Linux).
Read more >VERSION.txt - jetty/org.eclipse.jetty.project - Git at Google
MF with version 9.2.10 / 9.2.13. ... jetty-9.2.10.v20150310 - 10 March 2015 ... + 403122 Session replication fails with ClassNotFoundException when session.
Read more >Serialized Form (Jetty :: Security 9.2.10.v20150310 API)
Package org.eclipse.jetty.security ... private void readObject(ObjectInputStream stream) throws IOException, ClassNotFoundException.
Read more >ContextHandler (Jetty :: Server Core 7.0.0.RC0 API) - javadoc.io
ContextHandler. This handler wraps a call to handle by setting the context and servlet path, plus setting the context classloader. If the context...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Looks like we are good to go. We aren’t seeing any issues so far. Awesome job! When do you think this might see a stable release?
Alright. Thanks for the analysis. Please let me know if there is anything I can do to help further debug or to try out custom instrumented builds.