0 Replies Latest reply on Oct 31, 2005 4:16 PM by teknomad

    This destination does not exist!

      Consider two clustered JBoss Servers JBossA and JBossB.

      On JBossA:
      A Queue called myQueue was added to jbossmq-destinations-service.xml of JBossA and appears in its JNDIView.

      On JBossB:
      From a MessageProducerServlet on JBossB the following code leads to an error:

      ...
      1. QueueConnectionFactory factory = (QueueConnectionFactory) ictx.lookup("ConnectionFactory");
      2. QueueConnection qcon = factory.createQueueConnection();
      3. Queue queue = (Queue) ictx.lookup("queue/myQueue"); // fails here if myQueue is not defined as above on JBossA
      4. QueueSession qsess = qcon.createQueueSession(true, 0);
      5. QueueSender sender = qsess.createSender(queue);
      6. TextMessage tmsg = qsess.createTextMessage("DUMMY_MESSAGE");
      7. sender.send(tmsg);
      8. qsess.commit(); // fails here, even though line 3 returned an apparently bound queue
      9. qsess.close();
      ...

      Note:
      a. When myQueue is removed from JBossA, the lookup fails at line 3, with "javax.naming.NameNotFoundException: myQueue not bound",
      BUT when it is there, the lookup succeeds only to fail at line 8, now complaining that the destination (or queue)
      does not exist (the error listing can be located below).

      b. If line 8 is removed, then there is no error, but then again no messages appear in myQueue.


      Why would the queue be bound, returned, appear to be usable, but mysteriously not exist at commit time, just five lines
      later?

      Thanks in advance...



      11:53:07,202 INFO [STDOUT] javax.jms.InvalidDestinationException: This destination does not exist! QUEUE.myQueue
      11:53:07,202 INFO [STDOUT] at org.jboss.mq.server.JMSDestinationManager.addMessage(JMSDestinationManager.java:389)
      11:53:07,202 INFO [STDOUT] at org.jboss.mq.server.JMSDestinationManager.addMessage(JMSDestinationManager.java:373)
      11:53:07,202 INFO [STDOUT] at org.jboss.mq.server.JMSServerInterceptorSupport.addMessage(JMSServerInterceptorSupport.java:136)
      11:53:07,202 INFO [STDOUT] at org.jboss.mq.security.ServerSecurityInterceptor.addMessage(ServerSecurityInterceptor.java:153)
      11:53:07,202 INFO [STDOUT] at org.jboss.mq.server.TracingInterceptor.addMessage(TracingInterceptor.java:256)
      11:53:07,202 INFO [STDOUT] at org.jboss.mq.server.JMSServerInvoker.addMessage(JMSServerInvoker.java:136)
      11:53:07,202 INFO [STDOUT] at org.jboss.mq.il.jvm.JVMServerIL.addMessage(JVMServerIL.java:136)
      11:53:07,202 INFO [STDOUT] at org.jboss.mq.Connection.sendToServer(Connection.java:965)
      11:53:07,202 INFO [STDOUT] at org.jboss.mq.SpyXAResourceManager.addMessage(SpyXAResourceManager.java:106)
      11:53:07,202 INFO [STDOUT] at org.jboss.mq.SpySession.sendMessage(SpySession.java:969)
      11:53:07,202 INFO [STDOUT] at org.jboss.mq.SpyMessageProducer.send(SpyMessageProducer.java:265)
      11:53:07,202 INFO [STDOUT] at org.jboss.mq.SpyMessageProducer.send(SpyMessageProducer.java:199)
      11:53:07,202 INFO [STDOUT] at MessageProducerServlet.doPost(MessageProducerServlet.java:80)
      11:53:07,202 INFO [STDOUT] at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
      11:53:07,202 INFO [STDOUT] at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
      11:53:07,202 INFO [STDOUT] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
      11:53:07,202 INFO [STDOUT] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      11:53:07,202 INFO [STDOUT] at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:81)
      11:53:07,202 INFO [STDOUT] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
      11:53:07,202 INFO [STDOUT] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      11:53:07,202 INFO [STDOUT] at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
      11:53:07,202 INFO [STDOUT] at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
      11:53:07,202 INFO [STDOUT] at org.jboss.web.tomcat.security.CustomPrincipalValve.invoke(CustomPrincipalValve.java:39)
      11:53:07,202 INFO [STDOUT] at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:159)
      11:53:07,202 INFO [STDOUT] at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:59)
      11:53:07,202 INFO [STDOUT] at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
      11:53:07,202 INFO [STDOUT] at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
      11:53:07,202 INFO [STDOUT] at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
      11:53:07,202 INFO [STDOUT] at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
      11:53:07,202 INFO [STDOUT] at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:856)
      11:53:07,202 INFO [STDOUT] at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:744)
      11:53:07,202 INFO [STDOUT] at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
      11:53:07,202 INFO [STDOUT] at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
      11:53:07,202 INFO [STDOUT] at java.lang.Thread.run(Thread.java:595)