Uploaded image for project: 'Zanata'
  1. ZNTA-1073

NullPointerException when trying to access non-existing project

    Details

    • Type: Bug
    • Status: Merged (View workflow)
    • Priority: unspecified
    • Resolution: Ready for Release
    • Affects Version/s: None
    • Fix Version/s: platform-4.0.0
    • Component/s: None
    • Labels:
      None
    • Sprint:
      16.10, 16.11

      Description

      Apparently, any tries to access to non-existing project through an invalid slug causes NullPointerException.

      To reproduce :

      1. Click "Projects" at the menu
      2. Click one of the Projects
      3. Click one of the version of the projects
      4. write some invalid things as a project slug on the url

      Here is the error trace:

      14:12:24,103 ERROR [org.zanata.exception.handler.AbstractExceptionHandler] (http-0.0.0.0:8080-4) exception happened in view: /iteration/view.xhtml: java.lang.NullPointerException
      	at org.zanata.action.MergeTransAction.setSourceProjectSlug(MergeTransAction.java:115) [classes:]
      	at org.zanata.action.MergeTransAction.setTargetProjectSlug(MergeTransAction.java:106) [classes:]
      	at org.zanata.action.MergeTransAction$Proxy$_$$_WeldClientProxy.setTargetProjectSlug(MergeTransAction$Proxy$_$$_WeldClientProxy.java) [classes:]
      	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [rt.jar:1.8.0_65]
      	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) [rt.jar:1.8.0_65]
      	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) [rt.jar:1.8.0_65]
      	at java.lang.reflect.Method.invoke(Method.java:497) [rt.jar:1.8.0_65]
      	at javax.el.BeanELResolver.setValue(BeanELResolver.java:383) [jboss-el-api_2.2_spec-1.0.4.Final-redhat-1.jar:1.0.4.Final-redhat-1]
      	at com.sun.faces.el.DemuxCompositeELResolver._setValue(DemuxCompositeELResolver.java:255) [jsf-impl-2.1.28.SP9-redhat-1.jar:2.1.28.SP9-redhat-1]
      	at com.sun.faces.el.DemuxCompositeELResolver.setValue(DemuxCompositeELResolver.java:281) [jsf-impl-2.1.28.SP9-redhat-1.jar:2.1.28.SP9-redhat-1]
      	at org.apache.el.parser.AstValue.setValue(AstValue.java:199) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.apache.el.ValueExpressionImpl.setValue(ValueExpressionImpl.java:257) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.jboss.weld.el.WeldValueExpression.setValue(WeldValueExpression.java:64) [weld-core-1.1.33.Final-redhat-1.jar:1.1.33.Final-redhat-1]
      	at com.sun.faces.facelets.el.TagValueExpression.setValue(TagValueExpression.java:131) [jsf-impl-2.1.28.SP9-redhat-1.jar:2.1.28.SP9-redhat-1]
      	at javax.faces.component.UIInput.updateModel(UIInput.java:822) [jboss-jsf-api_2.1_spec-2.1.28.SP1-redhat-1.jar:2.1.28.SP1-redhat-1]
      	at javax.faces.component.UIViewParameter.updateModel(UIViewParameter.java:288) [jboss-jsf-api_2.1_spec-2.1.28.SP1-redhat-1.jar:2.1.28.SP1-redhat-1]
      	at javax.faces.component.UIInput.processUpdates(UIInput.java:739) [jboss-jsf-api_2.1_spec-2.1.28.SP1-redhat-1.jar:2.1.28.SP1-redhat-1]
      	at javax.faces.component.UIComponentBase.processUpdates(UIComponentBase.java:1244) [jboss-jsf-api_2.1_spec-2.1.28.SP1-redhat-1.jar:2.1.28.SP1-redhat-1]
      	at javax.faces.component.UIComponentBase.processUpdates(UIComponentBase.java:1244) [jboss-jsf-api_2.1_spec-2.1.28.SP1-redhat-1.jar:2.1.28.SP1-redhat-1]
      	at javax.faces.component.UIViewRoot.processUpdates(UIViewRoot.java:1223) [jboss-jsf-api_2.1_spec-2.1.28.SP1-redhat-1.jar:2.1.28.SP1-redhat-1]
      	at com.sun.faces.lifecycle.UpdateModelValuesPhase.execute(UpdateModelValuesPhase.java:78) [jsf-impl-2.1.28.SP9-redhat-1.jar:2.1.28.SP9-redhat-1]
      	at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101) [jsf-impl-2.1.28.SP9-redhat-1.jar:2.1.28.SP9-redhat-1]
      	at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118) [jsf-impl-2.1.28.SP9-redhat-1.jar:2.1.28.SP9-redhat-1]
      	at org.apache.deltaspike.jsf.impl.listener.request.DeltaSpikeLifecycleWrapper.execute(DeltaSpikeLifecycleWrapper.java:89) [deltaspike-jsf-module-impl-1.5.4.jar:1.5.4]
      	at javax.faces.webapp.FacesServlet.service(FacesServlet.java:593) [jboss-jsf-api_2.1_spec-2.1.28.SP1-redhat-1.jar:2.1.28.SP1-redhat-1]
      	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:295) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.ocpsoft.rewrite.servlet.RewriteFilter.doFilter(RewriteFilter.java:226) [rewrite-servlet-3.0.0.Alpha10.jar:3.0.0.Alpha10]
      	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:246) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.zanata.servlet.DuplicateParamFilter.doFilter(DuplicateParamFilter.java:66) [classes:]
      	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:246) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:832) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:620) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:553) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:482) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.ocpsoft.rewrite.servlet.impl.HttpRewriteResultHandler.handleResult(HttpRewriteResultHandler.java:42) [rewrite-servlet-3.0.0.Alpha10.jar:3.0.0.Alpha10]
      	at org.ocpsoft.rewrite.servlet.RewriteFilter.rewrite(RewriteFilter.java:297) [rewrite-servlet-3.0.0.Alpha10.jar:3.0.0.Alpha10]
      	at org.ocpsoft.rewrite.servlet.RewriteFilter.doFilter(RewriteFilter.java:198) [rewrite-servlet-3.0.0.Alpha10.jar:3.0.0.Alpha10]
      	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:246) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.zanata.servlet.DuplicateParamFilter.doFilter(DuplicateParamFilter.java:66) [classes:]
      	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:246) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.zanata.servlet.JavaMelodyFilter.doFilter(JavaMelodyFilter.java:65) [classes:]
      	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:246) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.zanata.servlet.CacheControlFilter.doFilter(CacheControlFilter.java:36) [classes:]
      	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:246) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.zanata.servlet.MDCInsertingServletFilter.doFilter(MDCInsertingServletFilter.java:76) [classes:]
      	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:246) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.zanata.servlet.RequestLoggingFilter.doFilter(RequestLoggingFilter.java:88) [classes:]
      	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:246) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:231) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:149) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.jboss.as.jpa.interceptor.WebNonTxEmCloserValve.invoke(WebNonTxEmCloserValve.java:50) [jboss-as-jpa-7.5.7.Final-redhat-3.jar:7.5.7.Final-redhat-3]
      	at org.jboss.as.jpa.interceptor.WebNonTxEmCloserValve.invoke(WebNonTxEmCloserValve.java:50) [jboss-as-jpa-7.5.7.Final-redhat-3.jar:7.5.7.Final-redhat-3]
      	at org.jboss.security.negotiation.NegotiationAuthenticator$WrapperValve.invoke(NegotiationAuthenticator.java:492) [jboss-negotiation-common-2.3.11.Final-redhat-1.jar:2.3.11.Final-redhat-1]
      	at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:420) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.jboss.as.web.security.SecurityContextAssociationValve.invoke(SecurityContextAssociationValve.java:169) [jboss-as-web-7.5.7.Final-redhat-3.jar:7.5.7.Final-redhat-3]
      	at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:150) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:97) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:102) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:344) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:854) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:654) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:926) [jbossweb-7.5.15.Final-redhat-1.jar:7.5.15.Final-redhat-1]
      	at java.lang.Thread.run(Thread.java:745) [rt.jar:1.8.0_65]
      
      

        Attachments

          Activity

            People

            • Assignee:
              armaganersoz armaganersoz
              Reporter:
              armaganersoz armaganersoz
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: