I’ve a Nexus Repository server running on Docker. I’ve also configured an LDAP for log-ins. Also SSL is configured with a certificate. There was around a 30-45 min time period where some of the users could not log-in to the Nexus UI. When I checked the logs I see the following error multiple times (more than 500 times this is logged to nexus.log):
2024-04-25 13:43:13,116+0000 WARN [qtp1894689916-2544] *SYSTEM org.eclipse.jetty.server.HttpChannel - null
java.lang.NullPointerException: null
at org.sonatype.nexus.bootstrap.jetty.DockerSubdomainRequestCustomizer.customize(DockerSubdomainRequestCustomizer.java:44)
at org.eclipse.jetty.server.HttpChannel.lambda$handle$1(HttpChannel.java:483)
at org.eclipse.jetty.server.HttpChannel.dispatch(HttpChannel.java:732)
at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:479)
at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:277)
at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:311)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:105)
at org.eclipse.jetty.io.ChannelEndPoint$1.run(ChannelEndPoint.java:104)
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:883)
at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:1034)
at java.lang.Thread.run(Thread.java:750)
2024-04-25 13:43:13,116+0000 WARN [qtp1894689916-3367] *SYSTEM org.eclipse.jetty.server.HttpChannel - null
java.lang.NullPointerException: null
at org.sonatype.nexus.bootstrap.jetty.DockerSubdomainRequestCustomizer.customize(DockerSubdomainRequestCustomizer.java:44)
at org.eclipse.jetty.server.HttpChannel.lambda$handle$1(HttpChannel.java:483)
at org.eclipse.jetty.server.HttpChannel.dispatch(HttpChannel.java:732)
at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:479)
at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:277)
at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:311)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:105)
at org.eclipse.jetty.io.ChannelEndPoint$1.run(ChannelEndPoint.java:104)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:338)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:315)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:173)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:131)
at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:409)
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:883)
at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:1034)
at java.lang.Thread.run(Thread.java:750)```
I couldn't not find any duplicate errors online. Any ideas?
The code suggests somehow the URI for the request is null. If you’ve made alterations to Jetty’s configuration perhaps these are incorrect, or perhaps you have some software on your network making bogus requests?
Thank you for the reply. I actually changed the jetty-https.xml config location in order to implement the SSL using my own certificate. I’ll explain the steps and configs below.
I’m running the Nexus Repository as a container using docker. Here is my docker-compose.yaml file:
While doing the SSL configurations I noticed that the /nexus-data doesn’t include the etc/jetty directory inside it so here is the nexus.repository file below:
# Jetty section
application-port=8081
application-port-ssl=8443
# application-host=0.0.0.0
nexus-args=${jetty.etc}/jetty.xml,${jetty.etc}/jetty-http.xml,/opt/sonatype/sonatype-work/nexus3/etc/jetty/jetty-https.xml,${jetty.etc}/jetty-requestlog.xml
# As can be seen from above, I've given direct location as /opt/sonatype...
#nexus-context-path=/${NEXUS_CONTEXT}
# Nexus section
# nexus-edition=nexus-pro-edition
# nexus-features=\
# nexus-pro-feature
# nexus.hazelcast.discovery.isEnabled=true
And finally here is the jetty-https.xml file where I’ve defined the keystore location and it’s password:
The error you encountered might indicate that HTTP and HTTPS redirects in the network traffic (such as through a reverse proxy) are not working correctly. I resolved the same issue by configuring a middleware in Traefik reverse proxy and ensuring that requests are redirected to HTTPS.