2 Replies Latest reply on Nov 23, 2015 9:33 AM by Abhishek Gupta

    JBWEB000235: Allocate exception for servlet Main: java.lang.NullPointerException: charsetName

    Abhishek Gupta Newbie

      I'm new to JBOSS EAP 6.0

       

      I've successfully deployed EAR on JBOSS but getting below error when hitting http://server_name:8080/sso/main in browser:

       

      04:33:35,229 ERROR [org.apache.catalina.core.ContainerBase.[jboss.web].[default-host].[/sso].[Main]] (http-/135.155.175.224:8080-1) JBWEB000235: Allocate exception for servlet Main: java.lang.NullPointerException: charsetName

              at java.net.URLEncoder.encode(URLEncoder.java:193) [rt.jar:1.6.0_101]

              at web.Main.getCSPValues(Main.java:188) [classes:]

              at web.Main.init(Main.java:86) [classes:]

              at javax.servlet.GenericServlet.init(GenericServlet.java:242) [jboss-servlet-api_3.0_spec-1.0.2.Final-redhat-1.jar:1.0.2.Final-redhat-1]

              at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1194) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4]

              at org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:950) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4]

              at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:152) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4]

              at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:149) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4]

              at org.jboss.as.web.security.SecurityContextAssociationValve.invoke(SecurityContextAssociationValve.java:169) [jboss-as-web-7.4.0.Final-redhat-19.jar:7.4.0.Final-redhat-19]

              at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:145) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4]

              at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:97) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4]

              at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:102) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4]

              at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:344) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4]

              at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:856) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4]

              at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:653) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4]

              at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:926) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4]

              at java.lang.Thread.run(Thread.java:682) [rt.jar:1.6.0_101]

       

      04:35:56,642 ERROR [org.apache.catalina.core.ContainerBase.[jboss.web].[default-host].[/sso].[Main]] (http-/135.155.175.224:8080-2) JBWEB000235: Allocate exception for servlet Main: java.lang.NullPointerException: charsetName

              at java.net.URLEncoder.encode(URLEncoder.java:193) [rt.jar:1.6.0_101]

              at web.Main.getCSPValues(Main.java:188) [classes:]

              at web.Main.init(Main.java:86) [classes:]

              at javax.servlet.GenericServlet.init(GenericServlet.java:242) [jboss-servlet-api_3.0_spec-1.0.2.Final-redhat-1.jar:1.0.2.Final-redhat-1]

              at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1194) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4]

              at org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:950) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4]

              at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:152) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4]

              at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:149) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4]

              at org.jboss.as.web.security.SecurityContextAssociationValve.invoke(SecurityContextAssociationValve.java:169) [jboss-as-web-7.4.0.Final-redhat-19.jar:7.4.0.Final-redhat-19]

              at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:145) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4]

              at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:97) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4]

              at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:102) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4]

              at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:344) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4]

              at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:856) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4]

              at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:653) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4]

              at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:926) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4]

              at java.lang.Thread.run(Thread.java:682) [rt.jar:1.6.0_101]

       

      Could anyone please help with this error?