Uploaded image for project: 'Seam 2'
  1. Seam 2
  2. JBSEAM-2055

NPE in UIComponent when ViewRoot not available

    Details

      Description

      I have an @Observer("org.jboss.seam.beforePhase") in a component that injects a UIComponent via #

      {uicomponent[...]}

      java.lang.NullPointerException
      at org.jboss.seam.faces.UiComponent$1.get(UiComponent.java:56)
      at org.jboss.seam.faces.UiComponent$1.get(UiComponent.java:45)
      at javax.el.MapELResolver.getValue(MapELResolver.java:51)
      at javax.el.CompositeELResolver.getValue(CompositeELResolver.java:53)
      at com.sun.faces.el.FacesCompositeELResolver.getValue(FacesCompositeELResolver.java:64)
      at org.jboss.el.parser.AstBracketSuffix.getValue(AstBracketSuffix.java:59)
      at org.jboss.el.parser.AstValue.getValue(AstValue.java:67)
      at org.jboss.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:186)
      at org.jboss.seam.core.Expressions$1.getValue(Expressions.java:112)
      at org.jboss.seam.Component.getValueToInject(Component.java:2126)
      at org.jboss.seam.Component.injectAttributes(Component.java:1599)
      at org.jboss.seam.Component.inject(Component.java:1417)
      at org.jboss.seam.core.BijectionInterceptor.aroundInvoke(BijectionInterceptor.java:45)
      at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:68)
      at org.jboss.seam.core.MethodContextInterceptor.aroundInvoke(MethodContextInterceptor.java:42)
      at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:68)
      at org.jboss.seam.intercept.RootInterceptor.invoke(RootInterceptor.java:106)
      at org.jboss.seam.intercept.JavaBeanInterceptor.interceptInvocation(JavaBeanInterceptor.java:155)
      at org.jboss.seam.intercept.JavaBeanInterceptor.invoke(JavaBeanInterceptor.java:91)
      ...
      at org.jboss.seam.Component.callComponentMethod(Component.java:2087)
      at org.jboss.seam.core.Events.raiseEvent(Events.java:83)
      at org.jboss.seam.jsf.SeamPhaseListener.raiseEventsBeforePhase(SeamPhaseListener.java:381)
      at org.jboss.seam.jsf.SeamPhaseListener.beforePhase(SeamPhaseListener.java:118)
      at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:222)
      at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:117)
      at javax.faces.webapp.FacesServlet.service(FacesServlet.java:244)
      ...

        Gliffy Diagrams

          Attachments

            Activity

              People

              • Assignee:
                pmuir Pete Muir
                Reporter:
                matt.drees Matt Drees
              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: