0 Replies Latest reply on Jun 3, 2011 12:30 AM by Baskar Dhanapal

    How to solve Seam solder BeanManagerUnavilableException?

    Baskar Dhanapal Newbie
      Hi,

      I developed sample maven enterprise application with seam 3.0.0.Final. I have included necessary modules in my project. I build it successfully and my ear structure is below

      Seam3Test-EAR
         |
         |--- lib ( includes all seam 3 modules )
         |
         |--- META-INF
         |
         |--- Seam3Test-ejb.jar
         |
         |--- Seam3Test-web.war

      Below are the contents of my web.xml

      <?xml version="1.0" encoding="UTF-8"?>
      <web-app xmlns="http://java.sun.com/xml/ns/javaee"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd"
         version="3.0">

         <display-name>Seam 3 Test</display-name>

         <context-param>
            <param-name>javax.faces.PROJECT_STAGE</param-name>
            <param-value>Development</param-value>
         </context-param>

         <servlet>
            <servlet-name>Faces Servlet</servlet-name>
            <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
            <load-on-startup>1</load-on-startup>
         </servlet>
             <servlet-mapping>
            <servlet-name>Faces Servlet</servlet-name>
            <url-pattern>*.seam</url-pattern>
         </servlet-mapping>

         <session-config>
            <session-timeout>10</session-timeout>
         </session-config>

         <security-constraint>
            <display-name>Restrict access to XHTML documents</display-name>
            <web-resource-collection>
               <web-resource-name>XHTML</web-resource-name>
               <url-pattern>*.xhtml</url-pattern>
            </web-resource-collection>
            <auth-constraint/>
         </security-constraint>

      </web-app>

      I have included empty bean.xml file also.

      I am getting the below error when i tried to deploy the application in GlassFish 3.1.

      WARNING: Failed to locate BeanManager using any of these providers:
      org.jboss.seam.solder.beanManager.BeanManagerUnavailableException: Failed to locate BeanManager using any of these providers:
              at org.jboss.seam.solder.beanManager.BeanManagerLocator.getBeanManager(BeanManagerLocator.java:91)
              at org.jboss.seam.faces.event.SeamPreNavigationHandler.handleNavigation(SeamPreNavigationHandler.java:37)
              at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:130)
              at javax.faces.component.UICommand.broadcast(UICommand.java:315)
              at com.sun.webui.jsf.component.WebuiCommand.broadcast(WebuiCommand.java:166)
              at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:794)
              at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:1259)
              at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:81)
              at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101)
              at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
              at javax.faces.webapp.FacesServlet.service(FacesServlet.java:409)
              at org.apache.catalina.core.StandardWrapper.service(StandardWrapper.java:1534)
              at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:343)
              at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:215)
              at com.sun.webui.jsf.util.UploadFilter.doFilter(UploadFilter.java:223)
              at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:256)
              at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:215)
              at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:279)
              at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
              at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:655)
              at org.apache.catalina.core.StandardPipeline.doChainInvoke(StandardPipeline.java:600)
              at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:96)
              at com.sun.enterprise.web.PESessionLockingStandardPipeline.invoke(PESessionLockingStandardPipeline.java:91)
              at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:162)
              at org.apache.catalina.connector.CoyoteAdapter.doService(CoyoteAdapter.java:326)
              at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:227)
              at com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:228)
              at com.sun.grizzly.http.ProcessorTask.invokeAdapter(ProcessorTask.java:822)
              at com.sun.grizzly.http.ProcessorTask.doProcess(ProcessorTask.java:719)
              at com.sun.grizzly.http.ProcessorTask.process(ProcessorTask.java:1013)
              at com.sun.grizzly.http.DefaultProtocolFilter.execute(DefaultProtocolFilter.java:225)
              at com.sun.grizzly.DefaultProtocolChain.executeProtocolFilter(DefaultProtocolChain.java:137)
              at com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:104)
              at com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:90)
              at com.sun.grizzly.http.HttpProtocolChain.execute(HttpProtocolChain.java:79)
              at com.sun.grizzly.ProtocolChainContextTask.doCall(ProtocolChainContextTask.java:54)
              at com.sun.grizzly.SelectionKeyContextTask.call(SelectionKeyContextTask.java:59)
              at com.sun.grizzly.ContextTask.run(ContextTask.java:71)
              at com.sun.grizzly.util.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:532)
              at com.sun.grizzly.util.AbstractThreadPool$Worker.run(AbstractThreadPool.java:513)
              at java.lang.Thread.run(Thread.java:619)

      INFO: Exception when handling error trying to reset the response.
      org.jboss.seam.solder.beanManager.BeanManagerUnavailableException: Failed to locate BeanManager using any of these providers:
              at org.jboss.seam.solder.beanManager.BeanManagerLocator.getBeanManager(BeanManagerLocator.java:91)
              at org.jboss.seam.faces.event.SeamPreNavigationHandler.handleNavigation(SeamPreNavigationHandler.java:37)
              at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:130)
              at javax.faces.component.UICommand.broadcast(UICommand.java:315)
              at com.sun.webui.jsf.component.WebuiCommand.broadcast(WebuiCommand.java:166)
              at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:794)
              at javax.faces.c
              at org.glassfish.internal.data.ModuleInfo.start(ModuleInfo.java:269)
      .
      .
      .

      I searched on net a lot but i didnt get any idea to resolve this error. Even i added the weld module mentioned in this link http://seamframework.org/Seam3/Compatibility but still i think i have missed some configuration in glassfish 3.1. I need help from anybody to solve this error..