Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jetty-users] Migrating from jetty-9.2.11.v20150529-all.jar to jetty-9.3.2.v20150730-uber.jar results in a HTTP Error 404

There's no servlets or filters on your main ServletContextHandler.
No AppServlet, no SessionFilter, nothing.
There's not even a DefaultServlet or Default404Servlet.
There's no resource base either (its null).
That ServletContextHandler has nothing to serve, not even static content, not even a 404 error.

However, there is a strange com.host.reporter.ServletContainer$1@5069a91b present in your HashSessionManager.


Joakim Erdfelt / joakim@xxxxxxxxxxx

On Wed, Aug 26, 2015 at 11:08 AM, Bryan Coleman <bryan.coleman@xxxxxxxx> wrote:
Here is the content of the server.dump():

2015-08-26 14:01:37,553 [main] INFO  org.eclipse.jetty.server.Server  - jetty-9.3.2.v20150730
2015-08-26 14:01:37,586 [main] INFO  org.eclipse.jetty.server.handler.ContextHandler  - Started o.e.j.s.ServletContextHandler@2e0de20d{/,null,AVAILABLE}
2015-08-26 14:01:37,588 [main] INFO  org.eclipse.jetty.server.handler.ContextHandler  - Started o.e.j.s.ServletContextHandler@121f97fb{/static,file:///static/,AVAILABLE}
2015-08-26 14:01:37,638 [main] INFO  org.eclipse.jetty.util.ssl.SslContextFactory  - x509={host.domain.com=1, host=1} wild={} alias=null for SslContextFactory@1ec98548(file:///host.keystore,null)
2015-08-26 14:01:37,792 [main] INFO  org.eclipse.jetty.server.ServerConnector  - Started ServerConnector@6a2b6031{SSL,[ssl, http/1.1]}{0.0.0.0:8180}
2015-08-26 14:01:37,792 [main] INFO  org.eclipse.jetty.server.Server  - Started @20189ms
org.eclipse.jetty.server.Server@257e8c43 - STARTED
 += qtp470437767{STARTED,8<=8<=200,i=3,q=0} - STARTED
 |   +- 35 qtp470437767-35 RUNNABLE @ sun.nio.ch.EPollArrayWrapper.epollWait(Native Method)
 |   +- 36 qtp470437767-36 RUNNABLE @ sun.nio.ch.EPollArrayWrapper.epollWait(Native Method)
 |   +- 37 qtp470437767-37 RUNNABLE @ sun.nio.ch.EPollArrayWrapper.epollWait(Native Method)
 |   +- 38 qtp470437767-38 RUNNABLE @ sun.nio.ch.EPollArrayWrapper.epollWait(Native Method)
 |   +- 39 qtp470437767-39-acceptor-0@35a955e9-ServerConnector@6a2b6031{SSL,[ssl, http/1.1]}{0.0.0.0:8180} RUNNABLE @ sun.nio.ch.ServerSocketChannelImpl.accept0(Native Method) prio=3
 |   +- 40 qtp470437767-40 TIMED_WAITING @ sun.misc.Unsafe.park(Native Method) IDLE
 |   +- 41 qtp470437767-41 TIMED_WAITING @ sun.misc.Unsafe.park(Native Method) IDLE
 |   +- 42 qtp470437767-42 TIMED_WAITING @ sun.misc.Unsafe.park(Native Method) IDLE
 += ServerConnector@6a2b6031{SSL,[ssl, http/1.1]}{0.0.0.0:8180} - STARTED
 |   +~ org.eclipse.jetty.server.Server@257e8c43 - STARTED
 |   +~ qtp470437767{STARTED,8<=8<=200,i=3,q=0} - STARTED
 |   += org.eclipse.jetty.util.thread.ScheduledExecutorScheduler@4fbed6fc - STARTED
 |   +- org.eclipse.jetty.io.ArrayByteBufferPool@14e54a35
 |   += SslConnectionFactory@20a7ce0{SSL->HTTP/1.1} - STARTED
 |   |   += SslContextFactory@1ec98548(file:///host.keystore,null) - STARTED
 |   += HttpConnectionFactory@4ee80a94[HTTP/1.1] - STARTED
 |   |   +- HttpConfiguration@298cfe89{32768/8192,8192/8192,https://:0,[SecureRequestCustomizer@189fb01b]}
 |   += org.eclipse.jetty.server.ServerConnector$ServerConnectorManager@49522bdf - STARTED
 |   |   +- org.eclipse.jetty.io.ManagedSelector@5c94d4b8 id=0 keys=0 selected=0 id=0
 |   |   |   +- sun.nio.ch.EPollSelectorImpl@78780c0 keys=0
 |   |   +- org.eclipse.jetty.io.ManagedSelector@7c08461b id=1 keys=0 selected=0 id=1
 |   |   |   +- sun.nio.ch.EPollSelectorImpl@3c1e0161 keys=0
 |   |   +- org.eclipse.jetty.io.ManagedSelector@6c37c36 id=2 keys=0 selected=0 id=2
 |   |   |   +- sun.nio.ch.EPollSelectorImpl@1d95181b keys=0
 |   |   +- org.eclipse.jetty.io.ManagedSelector@2060df8 id=3 keys=0 selected=0 id=3
 |   |       +- sun.nio.ch.EPollSelectorImpl@1e5b064 keys=0
 |   +- sun.nio.ch.ServerSocketChannelImpl[/0:0:0:0:0:0:0:0:8180]
 |   +- qtp470437767-39-acceptor-0@35a955e9-ServerConnector@6a2b6031{SSL,[ssl, http/1.1]}{0.0.0.0:8180}
 += org.eclipse.jetty.server.handler.ContextHandlerCollection@5e38329d[o.e.j.s.ServletContextHandler@2e0de20d{/,null,AVAILABLE}, o.e.j.s.ServletContextHandler@121f97fb{/static,file:///static/,AVAILABLE}] - STARTED
 |   += o.e.j.s.ServletContextHandler@2e0de20d{/,null,AVAILABLE} - STARTED
 |   |   += org.eclipse.jetty.server.session.SessionHandler@4f5ad6b7 - STARTED
 |   |   |   += org.eclipse.jetty.server.session.HashSessionManager@3763aafd - STARTED
 |   |   |       +~ com.host.reporter.ServletContainer$1@5069a91b
 |   |   |       += org.eclipse.jetty.util.thread.ScheduledExecutorScheduler@443d94ae - STARTED
 |   |   |       |   +- sun.misc.Unsafe.park(Native Method)
 |   |   |       |   +- java.util.concurrent.locks.LockSupport.parkNanos(LockSupport.java:215)
 |   |   |       |   +- java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.awaitNanos(AbstractQueuedSynchronizer.java:2078)
 |   |   |       |   +- java.util.concurrent.ScheduledThreadPoolExecutor$DelayedWorkQueue.take(ScheduledThreadPoolExecutor.java:1093)
 |   |   |       |   +- java.util.concurrent.ScheduledThreadPoolExecutor$DelayedWorkQueue.take(ScheduledThreadPoolExecutor.java:809)
 |   |   |       |   +- java.util.concurrent.ThreadPoolExecutor.getTask(ThreadPoolExecutor.java:1067)
 |   |   |       |   +- java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1127)
 |   |   |       |   +- java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
 |   |   |       |   +- java.lang.Thread.run(Thread.java:745)
 |   |   |       +~ org.eclipse.jetty.server.session.HashSessionIdManager@322399e6 - STARTED
 |   |   |
 |   |   +> No ClassLoader
 |   |   +> Handler attributes o.e.j.s.ServletContextHandler@2e0de20d{/,null,AVAILABLE}
 |   |   |   +- org.eclipse.jetty.server.Executor=qtp470437767{STARTED,8<=8<=200,i=3,q=0}
 |   |   +> Context attributes o.e.j.s.ServletContextHandler@2e0de20d{/,null,AVAILABLE}
 |   |   |   +- org.eclipse.jetty.util.DecoratedObjectFactory=org.eclipse.jetty.util.DecoratedObjectFactory[decorators=0]
 |   |   +> Initparams o.e.j.s.ServletContextHandler@2e0de20d{/,null,AVAILABLE}
 |   += o.e.j.s.ServletContextHandler@121f97fb{/static,file:///static/,AVAILABLE} - STARTED
 |       += org.eclipse.jetty.servlet.ServletHandler@2b551e7b - STARTED
 |       |   += org.eclipse.jetty.servlet.DefaultServlet-3507200d@fb48a37a==org.eclipse.jetty.servlet.DefaultServlet,-1,false - STARTED
 |       |   +- [/]=>org.eclipse.jetty.servlet.DefaultServlet-3507200d
 |       |
 |       +> No ClassLoader
 |       +> Handler attributes o.e.j.s.ServletContextHandler@121f97fb{/static,file:///static/,AVAILABLE}
 |       |   +- org.eclipse.jetty.server.Executor=qtp470437767{STARTED,8<=8<=200,i=3,q=0}
 |       +> Context attributes o.e.j.s.ServletContextHandler@121f97fb{/static,file:///static/,AVAILABLE}
 |       |   +- org.eclipse.jetty.util.DecoratedObjectFactory=org.eclipse.jetty.util.DecoratedObjectFactory[decorators=0]
 |       +> Initparams o.e.j.s.ServletContextHandler@121f97fb{/static,file:///static/,AVAILABLE}
 += org.eclipse.jetty.server.session.HashSessionIdManager@322399e6 - STARTED
 |
 +> sun.misc.Launcher$AppClassLoader@18b4aac2
     +- file:/usr/java/jdk1.8.0_60/jre/lib/charsets.jar
     +- file:/usr/java/jdk1.8.0_60/jre/lib/deploy.jar
     +- file:/usr/java/jdk1.8.0_60/jre/lib/ext/cldrdata.jar
     +- file:/usr/java/jdk1.8.0_60/jre/lib/ext/dnsns.jar
     +- file:/usr/java/jdk1.8.0_60/jre/lib/ext/jaccess.jar
     +- file:/usr/java/jdk1.8.0_60/jre/lib/ext/jfxrt.jar
     +- file:/usr/java/jdk1.8.0_60/jre/lib/ext/localedata.jar
     +- file:/usr/java/jdk1.8.0_60/jre/lib/ext/nashorn.jar
     +- file:/usr/java/jdk1.8.0_60/jre/lib/ext/sunec.jar
     +- file:/usr/java/jdk1.8.0_60/jre/lib/ext/sunjce_provider.jar
     +- file:/usr/java/jdk1.8.0_60/jre/lib/ext/sunpkcs11.jar
     +- file:/usr/java/jdk1.8.0_60/jre/lib/ext/zipfs.jar
     +- file:/usr/java/jdk1.8.0_60/jre/lib/javaws.jar
     +- file:/usr/java/jdk1.8.0_60/jre/lib/jce.jar
     +- file:/usr/java/jdk1.8.0_60/jre/lib/jfr.jar
     +- file:/usr/java/jdk1.8.0_60/jre/lib/jfxswt.jar
     +- file:/usr/java/jdk1.8.0_60/jre/lib/jsse.jar
     +- file:/usr/java/jdk1.8.0_60/jre/lib/management-agent.jar
     +- file:/usr/java/jdk1.8.0_60/jre/lib/plugin.jar
     +- file:/usr/java/jdk1.8.0_60/jre/lib/resources.jar
     +- file:/usr/java/jdk1.8.0_60/jre/lib/rt.jar
     +- sun.misc.Launcher$ExtClassLoader@3c1df0e9

-----Original Message-----
From: jetty-users-bounces@xxxxxxxxxxx [mailto:jetty-users-bounces@xxxxxxxxxxx] On Behalf Of Lothar Kimmeringer
Sent: Wednesday, August 26, 2015 6:36 AM
To: jetty-users@xxxxxxxxxxx
Subject: Re: [jetty-users] Migrating from jetty-9.2.11.v20150529-all.jar to jetty-9.3.2.v20150730-uber.jar results in a HTTP Error 404

Am 25.08.2015 um 17:02 schrieb Bryan Coleman:
> Any thoughts on the code below and its relation to the HTTP ERROR 404
> when upgrading to version 9.3.2?

Can you do a System.out.println(server.dump()) after the setup of the server? If you see a ServletHandler$Default404Servlet in the dump, you might have the same effect I had when I started the thread with MID <55155AAD.6040309@xxxxxxxxxxxxxx>.

I helped myself with manually removing that servlet from the handler (which wasn't fun but does at least work). Maybe Jetty 9.3 gives you a way to tell the server to not add the 404-servlet automatically (which isn't possible with 9.2), so you might be able to get around the (really ugly) hack.


Cheers, Lothar
_______________________________________________
jetty-users mailing list
jetty-users@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit https://dev.eclipse.org/mailman/listinfo/jetty-users
_______________________________________________
jetty-users mailing list
jetty-users@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/jetty-users


Back to the top