8 Replies Latest reply on Jan 28, 2011 5:07 AM by Guofeng Zhang

    Deploying push-demo on JBoss 6 final throws " Not a compound name: ConnectionFactory"

    Guofeng Zhang Novice

      I build the push-demo on the trunk and deploy it to JBoss 6 final. But I got the following error message:

      14:05:01,901 INFO  [TomcatDeployment] deploy, ctxPath=/push-demo

      14:05:01,995 INFO  [StandardContext] The listener "com.sun.faces.config.ConfigureListener" is already configured for this context. The duplicate definition has been ignored.

      14:05:02,260 INFO  [config] Initializing Mojarra 2.0.3 ( b05) for context '/push-demo'

      14:05:12,479 INFO  [Cache] Selected fallback cache factory

      14:05:12,479 INFO  [Cache] Creating LRUMap cache instance using parameters: {com.sun.faces.duplicateJARPattern=^tmp\d+(\S*\.jar), com.sun.faces.injectionProvider=org.jboss.web.jsf.integration.injection.JBossDelegatingInjectionProvider, javax.faces.PROJECT_STAGE=Development}

      14:05:12,511 INFO  [Cache] Creating LRUMap cache instance of 512 items capacity

      14:05:12,589 INFO  [Application] RichFaces Core Implementation by JBoss, a division of Red Hat, Inc., version v.4.0.0-SNAPSHOT SVN r.20823

      14:05:12,948 INFO  [HornetQServerImpl] live server is starting..

      14:05:13,104 WARNING [HornetQServerImpl] Security risk! It has been detected that the cluster admin user and password have not been changed from the installation default. Please see the HornetQ user guide, cluster chapter, for instructionson how to do this.

      14:05:13,776 INFO  [NettyAcceptor] Started Netty Acceptor version 3.2.1.Final-r2319 localhost:5445 for CORE protocol

      14:05:13,776 INFO  [HornetQServerImpl] HornetQ Server version 2.1.2.Final (Colmeia, 120) started

      14:05:13,886 WARNING [JMSServerManagerImpl] Binding for ConnectionFactory already exists

      14:05:14,120 ERROR [[/push-demo]] Exception sending context initialized event to listener instance of class com.sun.faces.config.ConfigureListener: java.lang.ExceptionInInitializerError

              at org.richfaces.application.push.impl.jms.PushContextFactoryImpl.getPushContext(PushContextFactoryImpl.java:54) [:4.0.0-SNAPSHOT]

              at org.richfaces.application.push.TopicsContext.lookup(TopicsContext.java:80) [:4.0.0-SNAPSHOT]

              at demo.TopicsInitializer.processEvent(TopicsInitializer.java:51) [:]

              at javax.faces.event.SystemEvent.processListener(SystemEvent.java:102) [:2.0.3-]

              at com.sun.faces.application.ApplicationImpl.processListeners(ApplicationImpl.java:2040) [:2.0.3-]        ....

      .....

      Caused by: javax.naming.InvalidNameException: Not a compound name: ConnectionFactory

              at javax.naming.CompoundName.addAll(CompoundName.java:445) [:1.6.0_21]

              at org.jnp.server.NamingServer.lookup(NamingServer.java:436) [:5.0.5.Final]

              at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:728) [:5.0.5.Final]

              at javax.naming.InitialContext.lookup(InitialContext.java:396) [:1.6.0_21]

              at org.richfaces.application.push.impl.jms.MessagingContext.start(MessagingContext.java:102) [:4.0.0-SNAPSHOT]

              at org.richfaces.application.push.impl.jms.PushContextImpl.init(PushContextImpl.java:94) [:4.0.0-SNAPSHOT]

       

      I checked in hornetq-jms.xml that the ConnectionFactory has been configured:

         <connection-factory name="NettyConnectionFactory">

            <connectors>

               <connector-ref connector-name="netty"/>

            </connectors>

            <entries>

               <entry name="/ConnectionFactory"/>

               <entry name="/XAConnectionFactory"/>

            </entries>

         </connection-factory>

       

      How could I solve the issue?

       

      To play with the push-demo, do I need to configure a topic?

       

      Thanks for your help.

       

      Guofeng

        • 1. Deploying push-demo on JBoss 6 final throws " Not a compound name: ConnectionFactory"
          Ilya Shaikovsky Master

          Demo just configured to be used with Tomcat. And it shipped with JMS impl which actually already present at Jboss. We already working on making Jboss targetted demo and blog about that.

          • 3. Deploying push-demo on JBoss 6 final throws " Not a compound name: ConnectionFactory"
            Guofeng Zhang Novice

            I deployed on Tomcat 7. It works well. Thanks.

             

            By the way, is there any doc or blog describes how to use the push component?

            • 5. Deploying push-demo on JBoss 6 final throws " Not a compound name: ConnectionFactory"
              Guofeng Zhang Novice

              I update the trunk and find that the push component has made some changes, so I tried the push demo again on JBoss 6 final.

               

              it is deployed successfully and works well when I pay with it for a while. But it still has some issues:

              (1) Google Chrome 10.0.634.0:

                    When I close the demo page, I got:

              11:04:04,501 ERROR [org.apache.catalina.connector.CoyoteAdapter] An exception or error occurred in the container during the request processing: java.lang.IllegalStateException: Invalid async context for servlet Faces Servlet

                      at org.apache.catalina.core.StandardWrapperValve.async(StandardWrapperValve.java:643) [:6.0.0.Final]

                      at org.apache.catalina.core.StandardWrapperValve.event(StandardWrapperValve.java:402) [:6.0.0.Final]

                      at org.apache.catalina.core.StandardContextValve.event(StandardContextValve.java:260) [:6.0.0.Final]

                      at org.jboss.web.tomcat.security.SecurityAssociationValve.event(SecurityAssociationValve.java:328) [:6.0.0.Final]

                      at org.jboss.modcluster.catalina.CatalinaContext$RequestListenerValve.event(CatalinaContext.java:281) [:1.1.0.Final]

                      at org.jboss.web.tomcat.security.JaccContextValve.event(JaccContextValve.java:116) [:6.0.0.Final]

                      at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.event(SecurityContextEstablishmentValve.java:161) [:6.0.0.Final]

                      at org.apache.catalina.core.StandardHostValve.event(StandardHostValve.java:178) [:6.0.0.Final]

                      at org.apache.catalina.valves.ValveBase.event(ValveBase.java:200) [:6.0.0.Final]

                      at org.jboss.web.tomcat.service.jca.CachedConnectionValve.event(CachedConnectionValve.java:186) [:6.0.0.Final]

                      at org.apache.catalina.core.StandardEngineValve.event(StandardEngineValve.java:128) [:6.0.0.Final]

                      at org.jboss.web.tomcat.service.request.ActiveRequestResponseCacheValve.event(ActiveRequestResponseCacheValve.java:70) [:6.0.0.Final]

                      at org.apache.catalina.connector.CoyoteAdapter.event(CoyoteAdapter.java:265) [:6.0.0.Final]

                      at org.apache.coyote.http11.Http11AprProcessor.event(Http11AprProcessor.java:776) [:6.0.0.Final]

                      at org.apache.coyote.http11.Http11AprProtocol$Http11ConnectionHandler.event(Http11AprProtocol.java:553) [:6.0.0.Final]

                      at org.apache.tomcat.util.net.AprEndpoint$Worker.run(AprEndpoint.java:2013) [:6.0.0.Final]

               

              (2) Mozilla Firefox 4.0 Beta 10

              When I play for a while, sometime I got:

              12:00:57,408 ERROR [org.apache.catalina.connector.CoyoteAdapter] An exception or

              error occurred in the container during the request processing:

              java.lang.IllegalStateException: Invalid async context for servlet Faces Servlet

                      at org.apache.catalina.core.StandardWrapperValve.async(StandardWrapperValve.java:643) [:6.0.0.Final]

                      at org.apache.catalina.core.StandardWrapperValve.event(StandardWrapperValve.java:402) [:6.0.0.Final]

                      at org.apache.catalina.core.StandardContextValve.event(StandardContextValve.java:260) [:6.0.0.Final]

                      at org.jboss.web.tomcat.security.SecurityAssociationValve.event(SecurityAssociationValve.java:328) [:6.0.0.Final]

                      at org.jboss.modcluster.catalina.CatalinaContext$RequestListenerValve.event(CatalinaContext.java:281) [:1.1.0.Final]

                      at org.jboss.web.tomcat.security.JaccContextValve.event(JaccContextValve.java:116) [:6.0.0.Final]

                      at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.event(SecurityContextEstablishmentValve.java:161) [:6.0.0.Final]

                      at org.apache.catalina.core.StandardHostValve.event(StandardHostValve.java:178) [:6.0.0.Final]

                      at org.apache.catalina.valves.ValveBase.event(ValveBase.java:200) [:6.0.0.Final]

                      at org.jboss.web.tomcat.service.jca.CachedConnectionValve.event(CachedConnectionValve.java:186) [:6.0.0.Final]

                      at org.apache.catalina.core.StandardEngineValve.event(StandardEngineValve.java:128) [:6.0.0.Final]

                      at org.jboss.web.tomcat.service.request.ActiveRequestResponseCacheValve.event(ActiveRequestResponseCacheValve.java:70) [:6.0.0.Final]

                      at org.apache.catalina.connector.CoyoteAdapter.event(CoyoteAdapter.java:265) [:6.0.0.Final]

                      at org.apache.coyote.http11.Http11Processor.event(Http11Processor.java:757) [:6.0.0.Final]

                      at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.event(Http11Protocol.java:602) [:6.0.0.Final]

                      at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:938) [:6.0.0.Final]

                      at java.lang.Thread.run(Thread.java:619) [:1.6.0_21]

               

              12:00:57,440 ERROR [STDERR] java.lang.NullPointerException

              12:00:57,440 ERROR [STDERR]     at org.atmosphere.container.Servlet30Support.action(Servlet30Support.java:177)

              12:00:57,440 ERROR [STDERR]     at org.atmosphere.container.Servlet30Support.action(Servlet30Support.java:63)

              12:00:57,440 ERROR [STDERR]     at org.atmosphere.cpr.AtmosphereResourceImpl.resume(AtmosphereResourceImpl.java:142)

              12:00:57,440 ERROR [STDERR]     at org.richfaces.application.push.impl.AbstractRequest.resume(AbstractRequest.java:197)

              12:00:57,440 ERROR [STDERR]     at org.richfaces.application.push.impl.AbstractSession.connect(AbstractSession.java:65)

              12:00:57,440 ERROR [STDERR]     at org.richfaces.application.push.impl.AtmospherePushHandler.onRequest(AtmospherePushHandler.java:99)

              12:00:57,440 ERROR [STDERR]     at org.atmosphere.cpr.AsynchronousProcessor.action(AsynchronousProcessor.java:186)

              12:00:57,440 ERROR [STDERR]     at org.atmosphere.cpr.AsynchronousProcessor.suspended(AsynchronousProcessor.java:145)

              12:00:57,440 ERROR [STDERR]     at org.atmosphere.container.Servlet30Support.service(Servlet30Support.java:85)

              12:00:57,440 ERROR [STDERR]     at org.atmosphere.cpr.AtmosphereServlet.doCometSupport(AtmosphereServlet.java:1083)

              12:00:57,455 ERROR [STDERR]     at org.atmosphere.cpr.AtmosphereServlet.doPost(AtmosphereServlet.java:1066)

              12:00:57,455 ERROR [STDERR]     at org.atmosphere.cpr.AtmosphereServlet.doGet(AtmosphereServlet.java:1052)

              12:00:57,455 ERROR [STDERR]     at org.richfaces.webapp.PushFilter.doFilter(PushFilter.java:138)

              12:00:57,455 ERROR [STDERR]     at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:274)

              12:00:57,455 ERROR [STDERR]     at org.apache.catalina.core.ApplicationFilterCha\in.doFilter(ApplicationFilterChain.java:242)

              12:00:57,455 ERROR [STDERR]     at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:275)

              12:00:57,455 ERROR [STDERR]     at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)

              12:00:57,455 ERROR [STDERR]     at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:181)

              12:00:57,455 ERROR [STDERR]     at org.jboss.modcluster.catalina.CatalinaContext$RequestListenerValve.event(CatalinaContext.java:285)

              12:00:57,455 ERROR [STDERR]     at org.jboss.modcluster.catalina.CatalinaContext$RequestListenerValve.invoke(CatalinaContext.java:261)

              12:00:57,455 ERROR [STDERR]     at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:88)

              12:00:57,455 ERROR [STDERR]     at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:100)

              12:00:57,455 ERROR [STDERR]     at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)

              12:00:57,455 ERROR [STDERR]     at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)

              12:00:57,455 ERROR [STDERR]     at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)

              12:00:57,455 ERROR [STDERR]     at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)

              12:00:57,455 ERROR [STDERR]     at org.jboss.web.tomcat.service.request.ActiveRequestResponseCacheValve.invoke(ActiveRequestResponseCacheValve.java:53)

              12:00:57,471 ERROR [STDERR]     at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:362)

              12:00:57,471 ERROR [STDERR]     at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:877)

              12:00:57,471 ERROR [STDERR]     at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:654)

              12:00:57,471 ERROR [STDERR]     at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:951)

              12:00:57,471 ERROR [STDERR]     at java.lang.Thread.run(Thread.java:619)

               

              Note that the push demo works without finding any problem on Tomcat 7.0.6.

               

              I used Atomsphere jquery-pubsub sample on JBoss 6 final, and tried the similliar scenario, and do not find this issue. jquery-pubsub use Jersey, so I guess the implemation of Requst on Richfaces might have some issue.

               

              I tried firing a bug but I cannot find on the issue tracker page how to do it.

               

              Thanks for what you have done for us.

               

              Guofeng

              • 6. Deploying push-demo on JBoss 6 final throws " Not a compound name: ConnectionFactory"
                Nick Belaevski Master

                Guofeng,

                 

                Thanks again for reporting this! Just to confirm: you are using unmodified push-demo at final JBoss 6 with default settings, correct? Please post details for any changes if you have done some.

                 

                P.S. When you log into JIRA (issue tracker) using your JBoss.org credentials, there will be 'create issue' button in the right top corner of the page (just below search field).

                • 7. Deploying push-demo on JBoss 6 final throws " Not a compound name: ConnectionFactory"
                  Guofeng Zhang Novice

                  No, I did not make any change to the code.

                   

                  In Chrome, if I first close the page, then reopen the page without restarting the JBoss, play the demo with Chrome for a while (typing something, click ajax link), I also get the message listed in (1). This is not the same as what happened using Firefox.

                   

                  Thanks.

                   

                  guofeng.

                  • 8. Deploying push-demo on JBoss 6 final throws " Not a compound name: ConnectionFactory"
                    Guofeng Zhang Novice

                    Yes, I use the default settings on JBoss 6 on the last post. I can reproduce it easily.

                     

                    For the first post about the issue, I configured (which is removed to reproduce it in the last post):

                       <topic name="chat">

                          <entry name="/topic/chat"/>

                       </topic>

                    in default\deploy\hornetq\hornetq-jms.xml. but from the console, it does not has any strange messages logged.