10 Replies Latest reply on Jan 30, 2013 6:33 AM by Day cq5 developer

    facing org.apache.sling.engine.impl.SlingRequestProcessorImpl service: Uncaught SlingException

    Day cq5 developer

      Hi,

      I am facing below issue in Performance testing does anyone guide why this error is coming. Individually these pages are running fine. Attached logs for your reference.

       

       

      Thank ,

      Yogesh

       

       

      17.01.2013 05:10:57.232 *ERROR* [135.215.244.155 [1358421056013] GET /content/Intranet/microsite/innovation/right.html HTTP/1.1] org.apache.sling.engine.impl.SlingRequestProcessorImpl service: Uncaught SlingException org.apache.sling.api.SlingException:

              at org.apache.sling.scripting.jsp.jasper.servlet.JspServletWrapper.handleJspExceptionInterna l(JspServletWrapper.java:560)

              at org.apache.sling.scripting.jsp.jasper.servlet.JspServletWrapper.handleJspException(JspSer vletWrapper.java:496)

              at org.apache.sling.scripting.jsp.jasper.servlet.JspServletWrapper.service(JspServletWrapper .java:448)

              at org.apache.sling.scripting.jsp.JspServletWrapperAdapter.service(JspServletWrapperAdapter. java:59)

              at org.apache.sling.scripting.jsp.JspScriptEngineFactory.callJsp(JspScriptEngineFactory.java :173)

              at org.apache.sling.scripting.jsp.JspScriptEngineFactory.access$100(JspScriptEngineFactory.j ava:84)

              at org.apache.sling.scripting.jsp.JspScriptEngineFactory$JspScriptEngine.eval(JspScriptEngin eFactory.java:388)

              at org.apache.sling.scripting.core.impl.DefaultSlingScript.call(DefaultSlingScript.java:358)

              at org.apache.sling.scripting.core.impl.DefaultSlingScript.eval(DefaultSlingScript.java:170)

              at org.apache.sling.scripting.core.impl.DefaultSlingScript.service(DefaultSlingScript.java:4 56)

              at org.apache.sling.engine.impl.request.RequestData.service(RequestData.java:491)

              at org.apache.sling.engine.impl.filter.SlingComponentFilterChain.render(SlingComponentFilter Chain.java:45)

              at org.apache.sling.engine.impl.filter.AbstractSlingFilterChain.doFilter(AbstractSlingFilter Chain.java:64)

              at com.day.cq.wcm.core.impl.WCMDebugFilter.doFilter(WCMDebugFilter.java:146)

              at org.apache.sling.engine.impl.filter.AbstractSlingFilterChain.doFilter(AbstractSlingFilter Chain.java:60)

              at com.day.cq.wcm.core.impl.WCMComponentFilter.filterRootInclude(WCMComponentFilter.java:308 )

              at com.day.cq.wcm.core.impl.WCMComponentFilter.doFilter(WCMComponentFilter.java:141)

              at org.apache.sling.engine.impl.filter.AbstractSlingFilterChain.doFilter(AbstractSlingFilter Chain.java:60)

              at org.apache.sling.engine.impl.SlingRequestProcessorImpl.processComponent(SlingRequestProce ssorImpl.java:280)

              at org.apache.sling.engine.impl.filter.RequestSlingFilterChain.render(RequestSlingFilterChai n.java:49)

              at org.apache.sling.engine.impl.filter.AbstractSlingFilterChain.doFilter(AbstractSlingFilter Chain.java:64)

              at com.day.cq.wcm.mobile.core.impl.redirect.RedirectFilter.doFilter(RedirectFilter.java:185)

              at org.apache.sling.engine.impl.filter.AbstractSlingFilterChain.doFilter(AbstractSlingFilter Chain.java:60)

              at org.apache.sling.engine.impl.debug.RequestProgressTrackerLogFilter.doFilter(RequestProgre ssTrackerLogFilter.java:59)

              at org.apache.sling.engine.impl.filter.AbstractSlingFilterChain.doFilter(AbstractSlingFilter Chain.java:60)

              at com.day.cq.wcm.foundation.forms.impl.FormsHandlingServlet.doFilter(FormsHandlingServlet.j ava:220)

              at org.apache.sling.engine.impl.filter.AbstractSlingFilterChain.doFilter(AbstractSlingFilter Chain.java:60)

              at com.day.cq.theme.impl.ThemeResolverFilter.doFilter(ThemeResolverFilter.java:67)

              at org.apache.sling.engine.impl.filter.AbstractSlingFilterChain.doFilter(AbstractSlingFilter Chain.java:60)

              at org.apache.sling.i18n.impl.I18NFilter.doFilter(I18NFilter.java:96)

             at org.apache.sling.engine.impl.filter.AbstractSlingFilterChain.doFilter(AbstractSlingFilter Chain.java:60)

              at org.apache.sling.portal.container.internal.request.PortalFilter.doFilter(PortalFilter.jav a:76)

              at org.apache.sling.engine.impl.filter.AbstractSlingFilterChain.doFilter(AbstractSlingFilter Chain.java:60)

              at org.apache.sling.bgservlets.impl.BackgroundServletStarterFilter.doFilter(BackgroundServle tStarterFilter.java:135)

              at org.apache.sling.engine.impl.filter.AbstractSlingFilterChain.doFilter(AbstractSlingFilter Chain.java:60)

              at org.apache.sling.engine.impl.SlingRequestProcessorImpl.processRequest(SlingRequestProcess orImpl.java:171)

              at org.apache.sling.engine.impl.SlingMainServlet.service(SlingMainServlet.java:199)

              at org.apache.felix.http.base.internal.handler.ServletHandler.doHandle(ServletHandler.java:9 6)

              at org.apache.felix.http.base.internal.handler.ServletHandler.handle(ServletHandler.java:79)

              at org.apache.felix.http.base.internal.dispatch.ServletPipeline.handle(ServletPipeline.java: 42)

              at org.apache.felix.http.base.internal.dispatch.InvocationFilterChain.doFilter(InvocationFil terChain.java:49)

              at org.apache.felix.http.base.internal.dispatch.HttpFilterChain.doFilter(HttpFilterChain.jav a:33)

              at org.apache.sling.security.impl.ReferrerFilter.doFilter(ReferrerFilter.java:249)

              at org.apache.felix.http.base.internal.handler.FilterHandler.doHandle(FilterHandler.java:88)

              at org.apache.felix.http.base.internal.handler.FilterHandler.handle(FilterHandler.java:76)

              at org.apache.felix.http.base.internal.dispatch.InvocationFilterChain.doFilter(InvocationFil terChain.java:47)

              at org.apache.felix.http.base.internal.dispatch.HttpFilterChain.doFilter(HttpFilterChain.jav a:33)

              at org.apache.felix.http.base.internal.dispatch.FilterPipeline.dispatch(FilterPipeline.java: 48)

              at org.apache.felix.http.base.internal.dispatch.Dispatcher.dispatch(Dispatcher.java:39)

              at org.apache.felix.http.base.internal.DispatcherServlet.service(DispatcherServlet.java:67)

              at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)

              at org.apache.felix.http.proxy.ProxyServlet.service(ProxyServlet.java:60)

              at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)

              at org.apache.sling.launchpad.base.webapp.SlingServletDelegate.service(SlingServletDelegate. java:277)

              at org.apache.sling.launchpad.webapp.SlingServlet.service(SlingServlet.java:148)

              at com.day.j2ee.servletengine.ServletRuntimeEnvironment.service(ServletRuntimeEnvironment.ja va:228)

              at com.day.j2ee.servletengine.RequestDispatcherImpl.doFilter(RequestDispatcherImpl.java:315)

              at com.day.j2ee.servletengine.FilterChainImpl.doFilter(FilterChainImpl.java:74)

              at com.day.crx.launchpad.filters.CRXLaunchpadLicenseFilter.doFilter(CRXLaunchpadLicenseFilte r.java:96)

              at com.day.j2ee.servletengine.FilterChainImpl.doFilter(FilterChainImpl.java:72)

              at com.day.j2ee.servletengine.RequestDispatcherImpl.service(RequestDispatcherImpl.java:334)

              at com.day.j2ee.servletengine.RequestDispatcherImpl.service(RequestDispatcherImpl.java:378)

              at com.day.j2ee.servletengine.ServletHandlerImpl.execute(ServletHandlerImpl.java:315)

              at com.day.j2ee.servletengine.DefaultThreadPool$DequeueThread.run(DefaultThreadPool.java:134 )

      Caused by: org.apache.sling.api.SlingException:

              at org.apache.sling.scripting.jsp.jasper.servlet.JspServletWrapper.handleJspExceptionInterna l(JspServletWrapper.java:560)

              at org.apache.sling.scripting.jsp.jasper.servlet.JspServletWrapper.handleJspException(JspSer vletWrapper.java:496)

              at org.apache.sling.scripting.jsp.jasper.servlet.JspServletWrapper.service(JspServletWrapper .java:448)

              at org.apache.sling.scripting.jsp.JspServletWrapperAdapter.service(JspServletWrapperAdapter. java:59)

              at org.apache.sling.scripting.jsp.JspScriptEngineFactory.callJsp(JspScriptEngineFactory.java :173)

              at org.apache.sling.scripting.jsp.JspScriptEngineFactory.access$100(JspScriptEngineFactory.j ava:84)

              at org.apache.sling.scripting.jsp.JspScriptEngineFactory$JspScriptEngine.eval(JspScriptEngin eFactory.java:388)

              at org.apache.sling.scripting.core.impl.DefaultSlingScript.call(DefaultSlingScript.java:358)

              at org.apache.sling.scripting.core.impl.DefaultSlingScript.eval(DefaultSlingScript.java:170)

              at org.apache.sling.scripting.core.impl.DefaultSlingScript.service(DefaultSlingScript.java:4 56)

              at org.apache.sling.engine.impl.request.RequestData.service(RequestData.java:491)

              at org.apache.sling.engine.impl.filter.SlingComponentFilterChain.render(SlingComponentFilter Chain.java:45)

              at org.apache.sling.engine.impl.filter.AbstractSlingFilterChain.doFilter(AbstractSlingFilter Chain.java:64)

              at com.day.cq.wcm.core.impl.WCMDebugFilter.doFilterWithErrorHandling(WCMDebugFilter.java:182 )

              at com.day.cq.wcm.core.impl.WCMDebugFilter.doFilter(WCMDebugFilter.java:149)

              at org.apache.sling.engine.impl.filter.AbstractSlingFilterChain.doFilter(AbstractSlingFilter Chain.java:60)

              at com.day.cq.wcm.core.impl.WCMComponentFilter.doFilter(WCMComponentFilter.java:219)

              at org.apache.sling.engine.impl.filter.AbstractSlingFilterChain.doFilter(AbstractSlingFilter Chain.java:60)

              at org.apache.sling.engine.impl.SlingRequestProcessorImpl.processComponent(SlingRequestProce ssorImpl.java:280)

              at org.apache.sling.engine.impl.SlingRequestProcessorImpl.dispatchRequest(SlingRequestProces sorImpl.java:320)

              at org.apache.sling.engine.impl.request.SlingRequestDispatcher.dispatch(SlingRequestDispatch er.java:208)

              at org.apache.sling.engine.impl.request.SlingRequestDispatcher.include(SlingRequestDispatche r.java:102)

              at com.day.cq.wcm.core.impl.WCMComponentFilter$ForwardRequestDispatcher.include(WCMComponent Filter.java:381)

              at org.apache.jsp.libs.foundation.components.primary.cq.Page.Page_jsp._jspService(Page_jsp.j ava:106)

              at org.apache.sling.scripting.jsp.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)

              at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)

              at org.apache.sling.scripting.jsp.jasper.servlet.JspServletWrapper.service(JspServletWrapper .java:419)

              ... 66 more

      Caused by: java.lang.NullPointerException

              at com.day.cq.wcm.foundation.ELEvaluator.evaluate(ELEvaluator.java:53)

              at org.apache.jsp.libs.foundation.components.page.page_jsp._jspService(page_jsp.java:126)

              at org.apache.sling.scripting.jsp.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)

              at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)

              at org.apache.sling.scripting.jsp.jasper.servlet.JspServletWrapper.service(JspServletWrapper .java:419)

              ... 90 more

        • 1. Re: facing org.apache.sling.engine.impl.SlingRequestProcessorImpl service: Uncaught SlingException
          Ryan Lunka Level 3

          A NullPointerException will not really be diagnosable without a code snippet that shows the line on which the NPE is thrown.  There are many reasons this could have occcurred.

          • 2. Re: facing org.apache.sling.engine.impl.SlingRequestProcessorImpl service: Uncaught SlingException
            Jörg Hoh Adobe Employee

            It seems, that in the class org.apache.jsp.libs.foundation.components.page.page_jsp.java (line 126) there is a EL statement, which causes this NPE. This class is a compiled JSP, which you can lookup at /var/classes/org/apache/jsp/libs/foundation/components/page/page_jsp.java in your repository. Use CRXDE light (it can display you the line numbers).

             

            Jörg

            • 3. Re: facing org.apache.sling.engine.impl.SlingRequestProcessorImpl service: Uncaught SlingException
              Day cq5 developer Level 1

              location = ELEvaluator.evaluate(location, slingRequest, pageContext); 

               

              This is the line which I can see which casuing Null Pointer exception so not sure is it due to some data missing or there is issue while evaluting data.Any guess on this.

               

               

              Thanks,

              Yogesh

              • 4. Re: facing org.apache.sling.engine.impl.SlingRequestProcessorImpl service: Uncaught SlingException
                Jörg Hoh Adobe Employee

                Can you remove /var/classes and force the recompilation of the JSPs? Maybe it goes away that way.

                 

                In your case the ELEvaluator must be null, but I haven't seen such a problem yet.

                 

                kind regards,

                Jörg

                • 5. Re: facing org.apache.sling.engine.impl.SlingRequestProcessorImpl service: Uncaught SlingException
                  Sham HC Level 7

                  Hi Yogesh,

                   

                  I have see this issue during performance testing & cause was in DefineObjects there was a race condition if the internal pool for tags is exceeded.  Which version of cq you are using?  

                   

                  Assuming your cause is related to the same issue please make sure the bundle org.apache.sling.scripting.jsp.taglib is 2.1.1-Rev1096696.jar OR above is used.

                   

                  Thanks,

                  Sham

                  • 6. Re: facing org.apache.sling.engine.impl.SlingRequestProcessorImpl service: Uncaught SlingException
                    Day cq5 developer Level 1

                    Hi Sham,

                       We are using CQ5.4 and I can see jar version 2.1.0. So will you guide from where can I download higer version of org.apache.sling.scripting.jsp.taglib.

                     

                     

                    Regards,

                    Yogesh

                    • 7. Re: facing org.apache.sling.engine.impl.SlingRequestProcessorImpl service: Uncaught SlingException
                      Day cq5 developer Level 1

                      I can find one on Apache site and its version is 2.1.6 so is it fine if I use it ?

                      http://sling.apache.org/downloads.cgi

                       

                      Regards,

                      Yogesh

                      • 8. Re: facing org.apache.sling.engine.impl.SlingRequestProcessorImpl service: Uncaught SlingException
                        Day cq5 developer Level 1

                        Also we are facing one more issue in PT testing and that is related to segment.So not sure what is issue. We have tested all sgement defined by us its working fine individually. But same fails in PT.

                         

                        Thanks,

                        Yogesh

                         

                        This is log we get in PT

                        ERROR GET /etc/segmentation.segment.js HTTP/1.1] libs.cq.personalization.components.segmentpage.segment$js$jsp error while building a segment /etc/segmentation/intranet/California/jcr:content/traits org.apache.sling.api.scripting.ScriptEvaluationException: javax.servlet.ServletException: javax.servlet.jsp.JspException: Error while executing script ../trait.js.jsp
                        at org.apache.sling.scripting.core.impl.DefaultSlingScript.call(DefaultSlingScript.java:385)
                        at org.apache.sling.scripting.core.impl.DefaultSlingScript.eval(DefaultSlingScript.java:170)
                        at org.apache.sling.scripting.core.impl.DefaultSlingScript.service(DefaultSlingScript.java:4 56)
                        at org.apache.sling.engine.impl.request.RequestData.service(RequestData.java:491)
                        at org.apache.sling.engine.impl.filter.SlingComponentFilterChain.render(SlingComponentFilter Chain.java:45)
                        at org.apache.sling.engine.impl.filter.AbstractSlingFilterChain.doFilter(AbstractSlingFilter Chain.java:64)
                        at com.day.cq.wcm.core.impl.WCMDebugFilter.doFilterWithErrorHandling(WCMDebugFilter.java:182 )
                        at com.day.cq.wcm.core.impl.WCMDebugFilter.doFilter(WCMDebugFilter.java:149)
                        at org.apache.sling.engine.impl.filter.AbstractSlingFilterChain.doFilter(AbstractSlingFilter Chain.java:60)
                        at com.day.cq.wcm.core.impl.WCMComponentFilter.doFilter(WCMComponentFilter.java:219)
                        at org.apache.sling.engine.impl.filter.AbstractSlingFilterChain.doFilter(AbstractSlingFilter Chain.java:60)
                        at org.apache.sling.engine.impl.SlingRequestProcessorImpl.processComponent(SlingRequestProce ssorImpl.java:280)
                        at org.apache.sling.engine.impl.SlingRequestProcessorImpl.dispatchRequest(SlingRequestProces sorImpl.java:320)
                        at org.apache.sling.engine.impl.request.SlingRequestDispatcher.dispatch(SlingRequestDispatch er.java:208)
                        at org.apache.sling.engine.impl.request.SlingRequestDispatcher.include(SlingRequestDispatche r.java:102)
                        at com.day.cq.wcm.core.impl.WCMComponentFilter$ForwardRequestDispatcher.include(WCMComponent Filter.java:381)
                        at org.apache.jsp.libs.cq.personalization.components.segmentpage.segment_js_jsp._jspService( segment_js_jsp.java:188)
                        at org.apache.sling.scripting.jsp.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
                        at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
                        at org.apache.sling.scripting.jsp.jasper.servlet.JspServletWrapper.service(JspServletWrapper .java:419)
                        at org.apache.sling.scripting.jsp.JspServletWrapperAdapter.service(JspServletWrapperAdapter. java:59)
                        at org.apache.sling.scripting.jsp.JspScriptEngineFactory.callJsp(JspScriptEngineFactory.java :173)
                        at org.apache.sling.scripting.jsp.JspScriptEngineFactory.access$100(JspScriptEngineFactory.j ava:84)
                        at org.apache.sling.scripting.jsp.JspScriptEngineFactory$JspScriptEngine.eval(JspScriptEngin eFactory.java:388)
                        at org.apache.sling.scripting.core.impl.DefaultSlingScript.call(DefaultSlingScript.java:358)
                        at org.apache.sling.scripting.core.impl.DefaultSlingScript.eval(DefaultSlingScript.java:170)
                        at org.apache.sling.scripting.core.impl.DefaultSlingScript.service(DefaultSlingScript.java:4 56)
                        at org.apache.sling.engine.impl.request.RequestData.service(RequestData.java:491)
                        at org.apache.sling.engine.impl.filter.SlingComponentFilterChain.render(SlingComponentFilter Chain.java:45)
                        at org.apache.sling.engine.impl.filter.AbstractSlingFilterChain.doFilter(AbstractSlingFilter Chain.java:64)
                        8293,2-9 89%
                        Caused by: java.lang.NullPointerException
                        at com.day.cq.wcm.api.WCMMode.toRequest(WCMMode.java:71)
                        at org.apache.jsp.libs.cq.personalization.components.traits.logic.trait_js_jsp._jspService(t rait_js_jsp.java:204)
                        at org.apache.sling.scripting.jsp.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
                        at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
                        at org.apache.sling.scripting.jsp.jasper.servlet.JspServletWrapper.service(JspServletWrapper .java:419)

                        • 9. Re: facing org.apache.sling.engine.impl.SlingRequestProcessorImpl service: Uncaught SlingException
                          Sham HC Level 7

                          I have not tried with 2.1.6 it should work. After installing make sure all bundles are running.

                          For PT create separate thread for better tracking.

                          • 10. Re: facing org.apache.sling.engine.impl.SlingRequestProcessorImpl service: Uncaught SlingException
                            Day cq5 developer Level 1

                            I have used 2.1.6 jar of org.apache.sling.scripting.jsp.taglib and I can see problem mentioned in the discussion is resolved.

                             

                            Thanks,

                            Yogesh