The Resin console constantly shows this when running Jenkins as users navigate the site:
14-05-01 11:58:46.753] {Handling GET /jenkins/ : resin-port-8080-23} Caught exception evaluating: h.advertiseHeaders(response) in /jenkins/. Reason: java.lang.NullPointerException java.lang.NullPointerException at com.caucho.server.http.AbstractHttpResponse.setHeader(AbstractHttpResponse.java:359) at com.caucho.server.http.HttpServletResponseImpl.setHeader(HttpServletResponseImpl.java:1174) at javax.servlet.http.HttpServletResponseWrapper.setHeader(HttpServletResponseWrapper.java:121) I asked in the Resin Google group and there is a fix, wondered if there is a smarter way to deal with this or if a future Jenkins version might correct it? Thanks: (Snip) The other thing I found is something which again is easy to test but makes me question your comment about a Jenkins misconfig.. If you just drop the jenkins,war (http://jenkins-ci.org/) into resins /webapps folder, then visit http://localhost:8080/jenkins or whatever, the exception is thrown right away before any config is attempted, then again each time you navigatre pages on the site. Seems odd you get this right from the get go and only under resin … ? OK I debugged it further and have a workaround. The NPE is thrown in Resin because hudson.Functions is trying to set the header "X-Jenkins-CLI-Host” to a value it gets from System.getProperty(TcpSlaveAgentListener.class.getName()+".hostName”). For both Resin and Jenkins standalone mode, this value is null. In standalone mode the header does not even show up to the browser. Standalone mode appears to be running with Jetty, so the difference then is Resin vs Jetty handling of null values for setHeader. I have to assume Jetty silently ignores the null header set attempt, while Resin throws a NPE. I also have to assume our handling for this case is correct since Resin has passed Oracle TCK testing. However I didn’t actually lookup this test case to verify which behavior is expected. In any case, if you set the “hudson.TcpSlaveAgentListener.hostName" system property in Resin the exception will go away. I added this to resin.properties: jvm_args : -Xmx2048m -XX:MaxPermSize=256m -Dhudson.TcpSlaveAgentListener.hostName=127.0.0.1 Thanks, Paul -- You received this message because you are subscribed to the Google Groups "Jenkins Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-users+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.