com.sun.faces.mgbean.ManagedBeanCreationException:在托管 bean 上执行资源注入时发生错误

发布于 2024-11-10 10:40:56 字数 27282 浏览 7 评论 0原文

我有一个 JSF 托管 bean

当从 WebSphere AppServer 中的 JSF 页面引用托管 bean 时,我收到错误。

<h:inputText value=#{bean}/>

该 bean 在 faces-config.xml 中定义为

<managed-bean>
  <managed-bean-name>bean</managed-bean-name>
  <managed-bean-class>com.test.Bean</managed-bean-class>
  <managed-bean-scope>session</managed-bean-scope>
</managed-bean>

这是例外情况:

com.sun.faces.mgbean.ManagedBeanCreationException:在托管 bean mailingCitySuggestions 上执行资源注入时发生错误


更新:这是堆栈跟踪:

 com.sun.faces.mgbean.ManagedBeanCreationException: An error occurred performing resource injection on managed bean mailingCitySuggestions
[5/31/11 13:37:10:506 CDT] 00000126 SystemErr     R     at com.sun.faces.mgbean.BeanBuilder.injectResources(BeanBuilder.java:213)
[5/31/11 13:37:10:506 CDT] 00000126 SystemErr     R     at com.sun.faces.mgbean.BeanBuilder.build(BeanBuilder.java:108)
[5/31/11 13:37:10:506 CDT] 00000126 SystemErr     R     at com.sun.faces.mgbean.BeanManager.createAndPush(BeanManager.java:374)
[5/31/11 13:37:10:506 CDT] 00000126 SystemErr     R     at com.sun.faces.mgbean.BeanManager.create(BeanManager.java:222)
[5/31/11 13:37:10:506 CDT] 00000126 SystemErr     R     at com.sun.faces.el.ManagedBeanELResolver.getValue(ManagedBeanELResolver.java:88)
[5/31/11 13:37:10:506 CDT] 00000126 SystemErr     R     at javax.el.CompositeELResolver.getValue(CompositeELResolver.java:143)
[5/31/11 13:37:10:506 CDT] 00000126 SystemErr     R     at com.sun.faces.el.FacesCompositeELResolver.getValue(FacesCompositeELResolver.java:73)
[5/31/11 13:37:10:506 CDT] 00000126 SystemErr     R     at com.sun.faces.el.ChainAwareVariableResolver.resolveVariable(ChainAwareVariableResolver.java:107)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at com.ibm.faces.portlet.PortletVariableResolver.resolveVariable(PortletVariableResolver.java:91)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at com.sun.faces.el.VariableResolverChainWrapper.getValue(VariableResolverChainWrapper.java:112)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at javax.el.CompositeELResolver.getValue(CompositeELResolver.java:143)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at com.sun.faces.el.FacesCompositeELResolver.getValue(FacesCompositeELResolver.java:73)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at org.apache.el.parser.AstIdentifier.getValue(AstIdentifier.java:45)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at org.apache.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:185)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at com.sun.faces.application.ValueBindingValueExpressionAdapter.getValue(ValueBindingValueExpressionAdapter.java:113)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at com.ibm.faces.renderkit.html_extended.TypeaheadRenderer.doAnswer(TypeaheadRenderer.java:278)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at com.ibm.faces.renderkit.html_extended.TypeaheadRenderer.encodeBegin(TypeaheadRenderer.java:81)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at com.ibm.faces.renderkit.DefaultAjaxRenderer.encodeBegin(DefaultAjaxRenderer.java:64)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at javax.faces.component.UIComponentBase.encodeBegin(UIComponentBase.java:802)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at javax.faces.component.UIComponent.encodeAll(UIComponent.java:934)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at javax.faces.render.Renderer.encodeChildren(Renderer.java:148)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at com.ibm.faces.renderkit.DefaultAjaxRenderer.encodeChildren(DefaultAjaxRenderer.java:73)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:826)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at com.sun.faces.renderkit.html_basic.HtmlBasicRenderer.encodeRecursive(HtmlBasicRenderer.java:234)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at com.sun.faces.renderkit.html_basic.GroupRenderer.encodeChildren(GroupRenderer.java:118)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at com.ibm.faces.renderkit.DefaultAjaxRenderer.encodeChildren(DefaultAjaxRenderer.java:73)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:826)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at com.sun.faces.renderkit.html_basic.HtmlBasicRenderer.encodeRecursive(HtmlBasicRenderer.java:234)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at com.sun.faces.renderkit.html_basic.GroupRenderer.encodeChildren(GroupRenderer.java:118)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at com.ibm.faces.renderkit.DefaultAjaxRenderer.encodeChildren(DefaultAjaxRenderer.java:73)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:826)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at com.sun.faces.renderkit.html_basic.HtmlBasicRenderer.encodeRecursive(HtmlBasicRenderer.java:234)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at com.sun.faces.renderkit.html_basic.GroupRenderer.encodeChildren(GroupRenderer.java:118)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at com.ibm.faces.renderkit.DefaultAjaxRenderer.encodeChildren(DefaultAjaxRenderer.java:73)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:826)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at javax.faces.component.UIComponent.encodeAll(UIComponent.java:936)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at javax.faces.render.Renderer.encodeChildren(Renderer.java:148)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at com.ibm.faces.renderkit.DefaultAjaxRenderer.encodeChildren(DefaultAjaxRenderer.java:73)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:826)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at javax.faces.component.UIComponent.encodeAll(UIComponent.java:936)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at javax.faces.component.UIComponent.encodeAll(UIComponent.java:942)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at javax.faces.component.UIComponent.encodeAll(UIComponent.java:942)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at javax.faces.component.UIComponent.encodeAll(UIComponent.java:942)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at com.sun.faces.application.ViewHandlerImpl.doRenderView(ViewHandlerImpl.java:289)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at com.sun.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:220)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at com.ibm.faces.portlet.PortletViewHandlerImpl.renderView(PortletViewHandlerImpl.java:79)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:110)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:139)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at hhsc.it.mtp.core.listner.InterceptingLifecycle.render(InterceptingLifecycle.java:84)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at com.ibm.faces.portlet.FacesPortlet.doRender(FacesPortlet.java:374)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at com.ibm.faces.portlet.FacesPortlet.doView(FacesPortlet.java:415)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at hhsc.it.mtp.portlet.IndividualSearchPortlet.doView(IndividualSearchPortlet.java:36)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at com.ibm.faces.portlet.FacesPortlet.doDispatch(FacesPortlet.java:303)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at javax.portlet.GenericPortlet.render(GenericPortlet.java:233)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletFilterChainImpl.doFilter(PortletFilterChainImpl.java:128)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at com.ibm.wps.propertybroker.standard.filter.C2APortletFilter.doFilter(C2APortletFilter.java:183)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletFilterChainImpl.doFilter(PortletFilterChainImpl.java:120)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletServlet.doDispatch(PortletServlet.java:573)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletServletCollaboratorChainImpl.doCollaborator(PortletServletCollaboratorChainImpl.java:114)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.rrd.RRDServerPortletServletCollaborator.doRender(RRDServerPortletServletCollaborator.java:123)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletServletCollaboratorChainImpl.doCollaborator(PortletServletCollaboratorChainImpl.java:105)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.cache.CacheCollaborator.doRender(CacheCollaborator.java:92)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletServletCollaboratorChainImpl.doCollaborator(PortletServletCollaboratorChainImpl.java:105)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.wps.pe.pc.waspc.core.impl.PortletServletCollaboratorImpl.doRender(PortletServletCollaboratorImpl.java:156)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletServletCollaboratorChainImpl.doCollaborator(PortletServletCollaboratorChainImpl.java:105)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletServlet.doDispatch(PortletServlet.java:273)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletServletCollaboratorChainImpl.doCollaborator(PortletServletCollaboratorChainImpl.java:82)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.rrd.RRDServerPortletServletCollaborator.doDispatch(RRDServerPortletServletCollaborator.java:60)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletServletCollaboratorChainImpl.doCollaborator(PortletServletCollaboratorChainImpl.java:74)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.cache.CacheCollaborator.doDispatch(CacheCollaborator.java:74)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletServletCollaboratorChainImpl.doCollaborator(PortletServletCollaboratorChainImpl.java:74)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.wps.pe.pc.waspc.core.impl.PortletServletCollaboratorImpl.doDispatch(PortletServletCollaboratorImpl.java:121)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletServletCollaboratorChainImpl.doCollaborator(PortletServletCollaboratorChainImpl.java:74)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletServlet.dispatch(PortletServlet.java:208)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletServlet.service(PortletServlet.java:165)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at javax.servlet.http.HttpServlet.service(HttpServlet.java:831)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:1655)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:1595)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:104)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.WebAppFilterChain._doFilter(WebAppFilterChain.java:77)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.WebAppFilterManager.doFilter(WebAppFilterManager.java:895)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:932)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:500)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.handleRequest(ServletWrapperImpl.java:178)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.wsspi.webcontainer.servlet.GenericServletWrapper.handleRequest(GenericServletWrapper.java:121)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.include(WebAppRequestDispatcher.java:673)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletInvokerImpl.invoke(PortletInvokerImpl.java:214)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletInvokerCollaboratorChainImpl.doCollaborator(PortletInvokerCollaboratorChainImpl.java:78)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.cache.PortletInvokerCacheCollaborator.doRender(PortletInvokerCacheCollaborator.java:58)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletInvokerCollaboratorChainImpl.doCollaborator(PortletInvokerCollaboratorChainImpl.java:67)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.ext.PortletInvokerPerformanceCollaborator.invoke(PortletInvokerPerformanceCollaborator.java:313)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.ext.PortletInvokerPerformanceCollaborator.doInvoke(PortletInvokerPerformanceCollaborator.java:101)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.ext.PortletInvokerPerformanceCollaborator.invokePMI(PortletInvokerPerformanceCollaborator.java:163)
[5/31/11 13:37:10:512 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.ext.PortletInvokerPerformanceCollaborator.doInvoke(PortletInvokerPerformanceCollaborator.java:91)
[5/31/11 13:37:10:512 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.ext.PortletInvokerPerformanceCollaborator.doRender(PortletInvokerPerformanceCollaborator.java:74)
[5/31/11 13:37:10:512 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletInvokerCollaboratorChainImpl.doCollaborator(PortletInvokerCollaboratorChainImpl.java:67)
[5/31/11 13:37:10:512 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletInvokerImpl.render(PortletInvokerImpl.java:97)
[5/31/11 13:37:10:512 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.PortletContainerImpl.doRender(PortletContainerImpl.java:119)
[5/31/11 13:37:10:512 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.PortletContainerInvokerCollaboratorChainImpl.doCollaborator(PortletContainerInvokerCollaboratorChainImpl.java:80)
[5/31/11 13:37:10:512 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.ext.ExtCollaborator.doRender(ExtCollaborator.java:74)
[5/31/11 13:37:10:512 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.PortletContainerInvokerCollaboratorChainImpl.doCollaborator(PortletContainerInvokerCollaboratorChainImpl.java:67)
[5/31/11 13:37:10:512 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.cache.CacheInvokerCollaborator.doRender(CacheInvokerCollaborator.java:66)
[5/31/11 13:37:10:512 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.PortletContainerInvokerCollaboratorChainImpl.doCollaborator(PortletContainerInvokerCollaboratorChainImpl.java:67)
[5/31/11 13:37:10:512 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.PortletContainerImpl.renderPortlet(PortletContainerImpl.java:89)
[5/31/11 13:37:10:512 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.pcinvoker.PortletInvokerImpl$2.run(PortletInvokerImpl.java:100)
[5/31/11 13:37:10:512 CDT] 00000126 SystemErr     R     at java.security.AccessController.doPrivileged(AccessController.java:251)
[5/31/11 13:37:10:512 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.pcinvoker.PortletInvokerImpl.invokeRender(PortletInvokerImpl.java:96)
[5/31/11 13:37:10:512 CDT] 00000126 SystemErr     R     at com.ibm.wps.pe.pc.waspc.core.impl.PortletInvokerImpl$1.invoke(PortletInvokerImpl.java:98)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.pe.pc.waspc.core.impl.PortletInvokerImpl.invoke(PortletInvokerImpl.java:182)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.pe.pc.waspc.core.impl.PortletInvokerImpl.invokeRender(PortletInvokerImpl.java:96)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.pe.pc.waspc.PortletContainerImpl.renderPortlet(PortletContainerImpl.java:116)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.pe.pc.PortletContainerImpl.doRenderPortlet(PortletContainerImpl.java:641)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.pe.ext.render.AbstractRenderManager.performService(AbstractRenderManager.java:264)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.pe.pc.PortletContainerImpl.renderPortlet(PortletContainerImpl.java:132)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.engine.extension.render.PortletFragmentRenderer.render(PortletFragmentRenderer.java:218)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.engine.extension.render.PortletFragmentRenderer.render(PortletFragmentRenderer.java:166)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.engine.phases.WPFragmentRenderPhase.processRendering(WPFragmentRenderPhase.java:248)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.engine.phases.WPFragmentRenderPhase.processRendering(WPFragmentRenderPhase.java:186)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.engine.phases.WPBaseRenderPhase.execute(WPBaseRenderPhase.java:194)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.state.phases.AbstractRenderPhase.next(AbstractRenderPhase.java:106)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.engine.phases.WPAbstractRenderPhase.next(WPAbstractRenderPhase.java:97)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.engine.Servlet.callPortal(Servlet.java:860)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.engine.Servlet.doGet(Servlet.java:617)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.engine.Servlet.doPost(Servlet.java:888)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at javax.servlet.http.HttpServlet.service(HttpServlet.java:738)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.wps.engine.Servlet.doFilter(Servlet.java:1257)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.wps.resolver.servlet.ContentHandlerCleanup.doFilter(ContentHandlerCleanup.java:648)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.wps.resolver.servlet.AbstractFilter.doFilter(AbstractFilter.java:93)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.wps.engine.Servlet.service(Servlet.java:1248)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:1655)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:1595)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:131)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.wps.engine.ExtendedLocaleFilter.doFilter(ExtendedLocaleFilter.java:113)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilter(FilterInstanceWrapper.java:184)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:116)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.wps.resolver.friendly.servlet.FriendlySelectionFilter.doFilter(FriendlySelectionFilter.java:191)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilter(FilterInstanceWrapper.java:184)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:116)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.wps.mappingurl.impl.URLAnalyzer.doFilter(URLAnalyzer.java:381)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilter(FilterInstanceWrapper.java:184)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:116)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.wps.engine.VirtualPortalFilter.doFilter(VirtualPortalFilter.java:88)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilter(FilterInstanceWrapper.java:184)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:116)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.wps.state.filter.StateCleanup.doFilter(StateCleanup.java:94)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilter(FilterInstanceWrapper.java:184)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:116)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.WebAppFilterChain._doFilter(WebAppFilterChain.java:77)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.WebAppFilterManager.doFilter(WebAppFilterManager.java:895)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:932)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:500)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.handleRequest(ServletWrapperImpl.java:178)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:3810)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:276)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:931)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.WSWebContainer.handleRequest(WSWebContainer.java:1583)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:183)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:455)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(HttpInboundLink.java:384)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(HttpICLReadCallback.java:83)
[5/31/11 13:37:10:516 CDT] 00000126 SystemErr     R     at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:165)
[5/31/11 13:37:10:516 CDT] 00000126 SystemErr     R     at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:217)
[5/31/11 13:37:10:516 CDT] 00000126 SystemErr     R     at com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(AsyncChannelFuture.java:161)
[5/31/11 13:37:10:516 CDT] 00000126 SystemErr     R     at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:138)
[5/31/11 13:37:10:516 CDT] 00000126 SystemErr     R     at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:204)
[5/31/11 13:37:10:516 CDT] 00000126 SystemErr     R     at com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHandler.java:775)
[5/31/11 13:37:10:516 CDT] 00000126 SystemErr     R     at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:905)
[5/31/11 13:37:10:516 CDT] 00000126 SystemErr     R     at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1550)
[5/31/11 13:37:10:516 CDT] 00000126 SystemErr     R Caused by: com.sun.faces.spi.InjectionProviderException: java.lang.NullPointerException
[5/31/11 13:37:10:517 CDT] 00000126 SystemErr     R     at com.sun.faces.vendor.WebSphereInjectionProvider.inject(WebSphereInjectionProvider.java:51)
[5/31/11 13:37:10:517 CDT] 00000126 SystemErr     R     at com.sun.faces.mgbean.BeanBuilder.injectResources(BeanBuilder.java:207)
[5/31/11 13:37:10:517 CDT] 00000126 SystemErr     R     ... 168 more
[5/31/11 13:37:10:517 CDT] 00000126 SystemErr     R Caused by: java.lang.NullPointerException
[5/31/11 13:37:10:518 CDT] 00000126 SystemErr     R     at java.lang.String.valueOf(String.java:1511)
[5/31/11 13:37:10:518 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.annotation.WASAnnotationHelper.inject(WASAnnotationHelper.java:261)
[5/31/11 13:37:10:518 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.annotation.WASAnnotationHelper.inject(WASAnnotationHelper.java:248)
[5/31/11 13:37:10:518 CDT] 00000126 SystemErr     R     at com.sun.faces.vendor.WebSphereInjectionProvider.inject(WebSphereInjectionProvider.java:49)
[5/31/11 13:37:10:518 CDT] 00000126 SystemErr     R     ... 169 more
[5/31/11 13:37:10:562 CDT] 00000126 SystemErr     R FATAL ERROR:  'java.lang.IllegalStateException: prepareThread not called for Thread Thread[WebContainer : 23,5,main]'

I have a JSF managedbean

I am getting the error when a managed bean is referred from from JSF page in WebSphere AppServer.

<h:inputText value=#{bean}/>

The bean is defined in the faces-config.xml as

<managed-bean>
  <managed-bean-name>bean</managed-bean-name>
  <managed-bean-class>com.test.Bean</managed-bean-class>
  <managed-bean-scope>session</managed-bean-scope>
</managed-bean>

This is the exception:

com.sun.faces.mgbean.ManagedBeanCreationException: An error occurred performing resource injection on managed bean mailingCitySuggestions


Update: this is the stacktrace:

 com.sun.faces.mgbean.ManagedBeanCreationException: An error occurred performing resource injection on managed bean mailingCitySuggestions
[5/31/11 13:37:10:506 CDT] 00000126 SystemErr     R     at com.sun.faces.mgbean.BeanBuilder.injectResources(BeanBuilder.java:213)
[5/31/11 13:37:10:506 CDT] 00000126 SystemErr     R     at com.sun.faces.mgbean.BeanBuilder.build(BeanBuilder.java:108)
[5/31/11 13:37:10:506 CDT] 00000126 SystemErr     R     at com.sun.faces.mgbean.BeanManager.createAndPush(BeanManager.java:374)
[5/31/11 13:37:10:506 CDT] 00000126 SystemErr     R     at com.sun.faces.mgbean.BeanManager.create(BeanManager.java:222)
[5/31/11 13:37:10:506 CDT] 00000126 SystemErr     R     at com.sun.faces.el.ManagedBeanELResolver.getValue(ManagedBeanELResolver.java:88)
[5/31/11 13:37:10:506 CDT] 00000126 SystemErr     R     at javax.el.CompositeELResolver.getValue(CompositeELResolver.java:143)
[5/31/11 13:37:10:506 CDT] 00000126 SystemErr     R     at com.sun.faces.el.FacesCompositeELResolver.getValue(FacesCompositeELResolver.java:73)
[5/31/11 13:37:10:506 CDT] 00000126 SystemErr     R     at com.sun.faces.el.ChainAwareVariableResolver.resolveVariable(ChainAwareVariableResolver.java:107)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at com.ibm.faces.portlet.PortletVariableResolver.resolveVariable(PortletVariableResolver.java:91)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at com.sun.faces.el.VariableResolverChainWrapper.getValue(VariableResolverChainWrapper.java:112)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at javax.el.CompositeELResolver.getValue(CompositeELResolver.java:143)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at com.sun.faces.el.FacesCompositeELResolver.getValue(FacesCompositeELResolver.java:73)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at org.apache.el.parser.AstIdentifier.getValue(AstIdentifier.java:45)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at org.apache.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:185)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at com.sun.faces.application.ValueBindingValueExpressionAdapter.getValue(ValueBindingValueExpressionAdapter.java:113)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at com.ibm.faces.renderkit.html_extended.TypeaheadRenderer.doAnswer(TypeaheadRenderer.java:278)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at com.ibm.faces.renderkit.html_extended.TypeaheadRenderer.encodeBegin(TypeaheadRenderer.java:81)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at com.ibm.faces.renderkit.DefaultAjaxRenderer.encodeBegin(DefaultAjaxRenderer.java:64)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at javax.faces.component.UIComponentBase.encodeBegin(UIComponentBase.java:802)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at javax.faces.component.UIComponent.encodeAll(UIComponent.java:934)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at javax.faces.render.Renderer.encodeChildren(Renderer.java:148)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at com.ibm.faces.renderkit.DefaultAjaxRenderer.encodeChildren(DefaultAjaxRenderer.java:73)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:826)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at com.sun.faces.renderkit.html_basic.HtmlBasicRenderer.encodeRecursive(HtmlBasicRenderer.java:234)
[5/31/11 13:37:10:507 CDT] 00000126 SystemErr     R     at com.sun.faces.renderkit.html_basic.GroupRenderer.encodeChildren(GroupRenderer.java:118)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at com.ibm.faces.renderkit.DefaultAjaxRenderer.encodeChildren(DefaultAjaxRenderer.java:73)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:826)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at com.sun.faces.renderkit.html_basic.HtmlBasicRenderer.encodeRecursive(HtmlBasicRenderer.java:234)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at com.sun.faces.renderkit.html_basic.GroupRenderer.encodeChildren(GroupRenderer.java:118)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at com.ibm.faces.renderkit.DefaultAjaxRenderer.encodeChildren(DefaultAjaxRenderer.java:73)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:826)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at com.sun.faces.renderkit.html_basic.HtmlBasicRenderer.encodeRecursive(HtmlBasicRenderer.java:234)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at com.sun.faces.renderkit.html_basic.GroupRenderer.encodeChildren(GroupRenderer.java:118)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at com.ibm.faces.renderkit.DefaultAjaxRenderer.encodeChildren(DefaultAjaxRenderer.java:73)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:826)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at javax.faces.component.UIComponent.encodeAll(UIComponent.java:936)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at javax.faces.render.Renderer.encodeChildren(Renderer.java:148)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at com.ibm.faces.renderkit.DefaultAjaxRenderer.encodeChildren(DefaultAjaxRenderer.java:73)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:826)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at javax.faces.component.UIComponent.encodeAll(UIComponent.java:936)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at javax.faces.component.UIComponent.encodeAll(UIComponent.java:942)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at javax.faces.component.UIComponent.encodeAll(UIComponent.java:942)
[5/31/11 13:37:10:508 CDT] 00000126 SystemErr     R     at javax.faces.component.UIComponent.encodeAll(UIComponent.java:942)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at com.sun.faces.application.ViewHandlerImpl.doRenderView(ViewHandlerImpl.java:289)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at com.sun.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:220)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at com.ibm.faces.portlet.PortletViewHandlerImpl.renderView(PortletViewHandlerImpl.java:79)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:110)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:139)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at hhsc.it.mtp.core.listner.InterceptingLifecycle.render(InterceptingLifecycle.java:84)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at com.ibm.faces.portlet.FacesPortlet.doRender(FacesPortlet.java:374)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at com.ibm.faces.portlet.FacesPortlet.doView(FacesPortlet.java:415)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at hhsc.it.mtp.portlet.IndividualSearchPortlet.doView(IndividualSearchPortlet.java:36)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at com.ibm.faces.portlet.FacesPortlet.doDispatch(FacesPortlet.java:303)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at javax.portlet.GenericPortlet.render(GenericPortlet.java:233)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletFilterChainImpl.doFilter(PortletFilterChainImpl.java:128)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at com.ibm.wps.propertybroker.standard.filter.C2APortletFilter.doFilter(C2APortletFilter.java:183)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletFilterChainImpl.doFilter(PortletFilterChainImpl.java:120)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletServlet.doDispatch(PortletServlet.java:573)
[5/31/11 13:37:10:509 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletServletCollaboratorChainImpl.doCollaborator(PortletServletCollaboratorChainImpl.java:114)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.rrd.RRDServerPortletServletCollaborator.doRender(RRDServerPortletServletCollaborator.java:123)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletServletCollaboratorChainImpl.doCollaborator(PortletServletCollaboratorChainImpl.java:105)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.cache.CacheCollaborator.doRender(CacheCollaborator.java:92)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletServletCollaboratorChainImpl.doCollaborator(PortletServletCollaboratorChainImpl.java:105)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.wps.pe.pc.waspc.core.impl.PortletServletCollaboratorImpl.doRender(PortletServletCollaboratorImpl.java:156)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletServletCollaboratorChainImpl.doCollaborator(PortletServletCollaboratorChainImpl.java:105)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletServlet.doDispatch(PortletServlet.java:273)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletServletCollaboratorChainImpl.doCollaborator(PortletServletCollaboratorChainImpl.java:82)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.rrd.RRDServerPortletServletCollaborator.doDispatch(RRDServerPortletServletCollaborator.java:60)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletServletCollaboratorChainImpl.doCollaborator(PortletServletCollaboratorChainImpl.java:74)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.cache.CacheCollaborator.doDispatch(CacheCollaborator.java:74)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletServletCollaboratorChainImpl.doCollaborator(PortletServletCollaboratorChainImpl.java:74)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.wps.pe.pc.waspc.core.impl.PortletServletCollaboratorImpl.doDispatch(PortletServletCollaboratorImpl.java:121)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletServletCollaboratorChainImpl.doCollaborator(PortletServletCollaboratorChainImpl.java:74)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletServlet.dispatch(PortletServlet.java:208)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletServlet.service(PortletServlet.java:165)
[5/31/11 13:37:10:510 CDT] 00000126 SystemErr     R     at javax.servlet.http.HttpServlet.service(HttpServlet.java:831)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:1655)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:1595)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:104)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.WebAppFilterChain._doFilter(WebAppFilterChain.java:77)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.WebAppFilterManager.doFilter(WebAppFilterManager.java:895)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:932)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:500)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.handleRequest(ServletWrapperImpl.java:178)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.wsspi.webcontainer.servlet.GenericServletWrapper.handleRequest(GenericServletWrapper.java:121)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.include(WebAppRequestDispatcher.java:673)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletInvokerImpl.invoke(PortletInvokerImpl.java:214)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletInvokerCollaboratorChainImpl.doCollaborator(PortletInvokerCollaboratorChainImpl.java:78)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.cache.PortletInvokerCacheCollaborator.doRender(PortletInvokerCacheCollaborator.java:58)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletInvokerCollaboratorChainImpl.doCollaborator(PortletInvokerCollaboratorChainImpl.java:67)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.ext.PortletInvokerPerformanceCollaborator.invoke(PortletInvokerPerformanceCollaborator.java:313)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.ext.PortletInvokerPerformanceCollaborator.doInvoke(PortletInvokerPerformanceCollaborator.java:101)
[5/31/11 13:37:10:511 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.ext.PortletInvokerPerformanceCollaborator.invokePMI(PortletInvokerPerformanceCollaborator.java:163)
[5/31/11 13:37:10:512 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.ext.PortletInvokerPerformanceCollaborator.doInvoke(PortletInvokerPerformanceCollaborator.java:91)
[5/31/11 13:37:10:512 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.ext.PortletInvokerPerformanceCollaborator.doRender(PortletInvokerPerformanceCollaborator.java:74)
[5/31/11 13:37:10:512 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletInvokerCollaboratorChainImpl.doCollaborator(PortletInvokerCollaboratorChainImpl.java:67)
[5/31/11 13:37:10:512 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.invoker.impl.PortletInvokerImpl.render(PortletInvokerImpl.java:97)
[5/31/11 13:37:10:512 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.PortletContainerImpl.doRender(PortletContainerImpl.java:119)
[5/31/11 13:37:10:512 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.PortletContainerInvokerCollaboratorChainImpl.doCollaborator(PortletContainerInvokerCollaboratorChainImpl.java:80)
[5/31/11 13:37:10:512 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.ext.ExtCollaborator.doRender(ExtCollaborator.java:74)
[5/31/11 13:37:10:512 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.PortletContainerInvokerCollaboratorChainImpl.doCollaborator(PortletContainerInvokerCollaboratorChainImpl.java:67)
[5/31/11 13:37:10:512 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.cache.CacheInvokerCollaborator.doRender(CacheInvokerCollaborator.java:66)
[5/31/11 13:37:10:512 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.PortletContainerInvokerCollaboratorChainImpl.doCollaborator(PortletContainerInvokerCollaboratorChainImpl.java:67)
[5/31/11 13:37:10:512 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.PortletContainerImpl.renderPortlet(PortletContainerImpl.java:89)
[5/31/11 13:37:10:512 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.pcinvoker.PortletInvokerImpl$2.run(PortletInvokerImpl.java:100)
[5/31/11 13:37:10:512 CDT] 00000126 SystemErr     R     at java.security.AccessController.doPrivileged(AccessController.java:251)
[5/31/11 13:37:10:512 CDT] 00000126 SystemErr     R     at com.ibm.ws.portletcontainer.pcinvoker.PortletInvokerImpl.invokeRender(PortletInvokerImpl.java:96)
[5/31/11 13:37:10:512 CDT] 00000126 SystemErr     R     at com.ibm.wps.pe.pc.waspc.core.impl.PortletInvokerImpl$1.invoke(PortletInvokerImpl.java:98)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.pe.pc.waspc.core.impl.PortletInvokerImpl.invoke(PortletInvokerImpl.java:182)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.pe.pc.waspc.core.impl.PortletInvokerImpl.invokeRender(PortletInvokerImpl.java:96)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.pe.pc.waspc.PortletContainerImpl.renderPortlet(PortletContainerImpl.java:116)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.pe.pc.PortletContainerImpl.doRenderPortlet(PortletContainerImpl.java:641)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.pe.ext.render.AbstractRenderManager.performService(AbstractRenderManager.java:264)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.pe.pc.PortletContainerImpl.renderPortlet(PortletContainerImpl.java:132)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.engine.extension.render.PortletFragmentRenderer.render(PortletFragmentRenderer.java:218)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.engine.extension.render.PortletFragmentRenderer.render(PortletFragmentRenderer.java:166)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.engine.phases.WPFragmentRenderPhase.processRendering(WPFragmentRenderPhase.java:248)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.engine.phases.WPFragmentRenderPhase.processRendering(WPFragmentRenderPhase.java:186)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.engine.phases.WPBaseRenderPhase.execute(WPBaseRenderPhase.java:194)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.state.phases.AbstractRenderPhase.next(AbstractRenderPhase.java:106)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.engine.phases.WPAbstractRenderPhase.next(WPAbstractRenderPhase.java:97)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.engine.Servlet.callPortal(Servlet.java:860)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.engine.Servlet.doGet(Servlet.java:617)
[5/31/11 13:37:10:513 CDT] 00000126 SystemErr     R     at com.ibm.wps.engine.Servlet.doPost(Servlet.java:888)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at javax.servlet.http.HttpServlet.service(HttpServlet.java:738)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.wps.engine.Servlet.doFilter(Servlet.java:1257)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.wps.resolver.servlet.ContentHandlerCleanup.doFilter(ContentHandlerCleanup.java:648)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.wps.resolver.servlet.AbstractFilter.doFilter(AbstractFilter.java:93)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.wps.engine.Servlet.service(Servlet.java:1248)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:1655)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:1595)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:131)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.wps.engine.ExtendedLocaleFilter.doFilter(ExtendedLocaleFilter.java:113)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilter(FilterInstanceWrapper.java:184)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:116)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.wps.resolver.friendly.servlet.FriendlySelectionFilter.doFilter(FriendlySelectionFilter.java:191)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilter(FilterInstanceWrapper.java:184)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:116)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.wps.mappingurl.impl.URLAnalyzer.doFilter(URLAnalyzer.java:381)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilter(FilterInstanceWrapper.java:184)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:116)
[5/31/11 13:37:10:514 CDT] 00000126 SystemErr     R     at com.ibm.wps.engine.VirtualPortalFilter.doFilter(VirtualPortalFilter.java:88)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilter(FilterInstanceWrapper.java:184)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:116)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.wps.state.filter.StateCleanup.doFilter(StateCleanup.java:94)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilter(FilterInstanceWrapper.java:184)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:116)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.WebAppFilterChain._doFilter(WebAppFilterChain.java:77)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.filter.WebAppFilterManager.doFilter(WebAppFilterManager.java:895)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:932)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:500)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.handleRequest(ServletWrapperImpl.java:178)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:3810)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:276)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:931)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.WSWebContainer.handleRequest(WSWebContainer.java:1583)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:183)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:455)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(HttpInboundLink.java:384)
[5/31/11 13:37:10:515 CDT] 00000126 SystemErr     R     at com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(HttpICLReadCallback.java:83)
[5/31/11 13:37:10:516 CDT] 00000126 SystemErr     R     at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:165)
[5/31/11 13:37:10:516 CDT] 00000126 SystemErr     R     at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:217)
[5/31/11 13:37:10:516 CDT] 00000126 SystemErr     R     at com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(AsyncChannelFuture.java:161)
[5/31/11 13:37:10:516 CDT] 00000126 SystemErr     R     at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:138)
[5/31/11 13:37:10:516 CDT] 00000126 SystemErr     R     at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:204)
[5/31/11 13:37:10:516 CDT] 00000126 SystemErr     R     at com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHandler.java:775)
[5/31/11 13:37:10:516 CDT] 00000126 SystemErr     R     at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:905)
[5/31/11 13:37:10:516 CDT] 00000126 SystemErr     R     at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1550)
[5/31/11 13:37:10:516 CDT] 00000126 SystemErr     R Caused by: com.sun.faces.spi.InjectionProviderException: java.lang.NullPointerException
[5/31/11 13:37:10:517 CDT] 00000126 SystemErr     R     at com.sun.faces.vendor.WebSphereInjectionProvider.inject(WebSphereInjectionProvider.java:51)
[5/31/11 13:37:10:517 CDT] 00000126 SystemErr     R     at com.sun.faces.mgbean.BeanBuilder.injectResources(BeanBuilder.java:207)
[5/31/11 13:37:10:517 CDT] 00000126 SystemErr     R     ... 168 more
[5/31/11 13:37:10:517 CDT] 00000126 SystemErr     R Caused by: java.lang.NullPointerException
[5/31/11 13:37:10:518 CDT] 00000126 SystemErr     R     at java.lang.String.valueOf(String.java:1511)
[5/31/11 13:37:10:518 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.annotation.WASAnnotationHelper.inject(WASAnnotationHelper.java:261)
[5/31/11 13:37:10:518 CDT] 00000126 SystemErr     R     at com.ibm.ws.webcontainer.annotation.WASAnnotationHelper.inject(WASAnnotationHelper.java:248)
[5/31/11 13:37:10:518 CDT] 00000126 SystemErr     R     at com.sun.faces.vendor.WebSphereInjectionProvider.inject(WebSphereInjectionProvider.java:49)
[5/31/11 13:37:10:518 CDT] 00000126 SystemErr     R     ... 169 more
[5/31/11 13:37:10:562 CDT] 00000126 SystemErr     R FATAL ERROR:  'java.lang.IllegalStateException: prepareThread not called for Thread Thread[WebContainer : 23,5,main]'

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

梦年海沫深 2024-11-17 10:40:56

com.sun.faces.mgbean.ManagedBeanCreationException:在托管 bean 上执行资源注入时发生错误

此异常仅意味着托管 bean 创建失败,因为在托管 bean 的资源注入期间发生错误。哦等等,这就是异常已经说明的内容。

好吧,假设您在 bean 上有一个 @Resource@EJBManagedProperty 等注释,这些注释将在 bean 构造期间注入。当该资源的构造期间发生异常时,您将收到此异常。

但是,在堆栈跟踪的底部,您应该找到创建该资源期间发生的异常原因的详细信息。相应地修复这个原因,它应该可以正常工作。


更新:最后,这是答案,跟踪的最底部部分:

Caused by: java.lang.NullPointerException
     at java.lang.String.valueOf(String.java:1511)
     at com.ibm.ws.webcontainer.annotation.WASAnnotationHelper.inject(WASAnnotationHelper.java:261)
     at com.ibm.ws.webcontainer.annotation.WASAnnotationHelper.inject(WASAnnotationHelper.java:248)
     at com.sun.faces.vendor.WebSphereInjectionProvider.inject(WebSphereInjectionProvider.java:49)
     ... 169 more

这显然是 com.ibm.ws.webcontainer.annotation.WASAnnotationHelper 类中的错误。然而,这超出了您的控制范围,因此您需要咨询 IBM 进行修复。在 Google 中挖掘会给出 对此异常有一些点击,其中包括 官方 IBM 错误报告。您可以在此处下载修订包。

com.sun.faces.mgbean.ManagedBeanCreationException: An error occurred performing resource injection on managed bean

This exception just means that the managed bean creation has failed because an error occurred during resource injection of the managed bean. Oh wait, that is what the exception is already telling.

Well, imagine that you've a @Resource, @EJB, ManagedProperty, etc annotation on the bean which is to be injected during bean's construction. When an exception occurs during construction of that resource, then you will get this exception.

However, at the bottom of the stacktrace you should find the details of the cause of the exception which occurred during creation of that resource. Fix that cause accordingly and it should work properly.


Update: finally, here is the answer, the bottommost part of the trace:

Caused by: java.lang.NullPointerException
     at java.lang.String.valueOf(String.java:1511)
     at com.ibm.ws.webcontainer.annotation.WASAnnotationHelper.inject(WASAnnotationHelper.java:261)
     at com.ibm.ws.webcontainer.annotation.WASAnnotationHelper.inject(WASAnnotationHelper.java:248)
     at com.sun.faces.vendor.WebSphereInjectionProvider.inject(WebSphereInjectionProvider.java:49)
     ... 169 more

This is clearly a bug in com.ibm.ws.webcontainer.annotation.WASAnnotationHelper class. This is however outside your control, so you need to consult IBM for the fix. Digging in Google gives some hits on this exception, among others an official IBM bug report. You can download fix packs here.

◇流星雨 2024-11-17 10:40:56

我最近在 Weblogic 12c 上运行的 Java EE 6/JSF 应用程序上遇到了类似的错误。

每当我尝试编辑 JSF 支持 bean“UsersController”,然后使用 Maven 进行重建时,我都会得到以下信息:

com.sun.faces.mgbean.ManagedBeanCreationException: An error occurred performing resource injection on managed bean usersController
    at com.sun.faces.mgbean.BeanBuilder.injectResources(BeanBuilder.java:211)
    at com.sun.faces.mgbean.BeanBuilder.build(BeanBuilder.java:103)
    at com.sun.faces.mgbean.BeanManager.createAndPush(BeanManager.java:408)

...

weblogic.servlet.internal.WebComponentContributor.inject(WebComponentContributor.java:299)
    at com.bea.faces.WeblogicInjectionProvider.inject(WeblogicInjectionProvider.java:29)
    ... 62 more
**Caused by**: com.bea.core.repackaged.springframework.beans.factory.NoSuchBeanDefinitionException: No unique bean of type [jpa.session.UsersFacade] is defined: No beans of type jpa.session.UsersFacade; 

我的解决方案是这样的:在 Netbeans 中构建应用程序后,我必须进入Weblogic 控制台并更新 Web 应用程序。这似乎消除了错误。

我已经发布了症状和治疗方法。如果有人知道这个问题的“原因”,请随时插话。

I recently got a similar error on a Java EE 6/JSF application running on Weblogic 12c.

Whenever I try to edit the JSF backing bean, "UsersController", and then rebuild using maven, I would get this:

com.sun.faces.mgbean.ManagedBeanCreationException: An error occurred performing resource injection on managed bean usersController
    at com.sun.faces.mgbean.BeanBuilder.injectResources(BeanBuilder.java:211)
    at com.sun.faces.mgbean.BeanBuilder.build(BeanBuilder.java:103)
    at com.sun.faces.mgbean.BeanManager.createAndPush(BeanManager.java:408)

...

weblogic.servlet.internal.WebComponentContributor.inject(WebComponentContributor.java:299)
    at com.bea.faces.WeblogicInjectionProvider.inject(WeblogicInjectionProvider.java:29)
    ... 62 more
**Caused by**: com.bea.core.repackaged.springframework.beans.factory.NoSuchBeanDefinitionException: No unique bean of type [jpa.session.UsersFacade] is defined: No beans of type jpa.session.UsersFacade; 

My solution was this: After building the application in Netbeans, I had to go into the Weblogic console and update the web application. That seemed to eliminate the error.

I've posted the symptoms and the cure. If anyone knows the "why" to this problem, feel free to chime in.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文