Return-Path: Delivered-To: apmail-activemq-dev-archive@www.apache.org Received: (qmail 13402 invoked from network); 22 Feb 2007 03:16:25 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 22 Feb 2007 03:16:25 -0000 Received: (qmail 9213 invoked by uid 500); 22 Feb 2007 03:16:33 -0000 Delivered-To: apmail-activemq-dev-archive@activemq.apache.org Received: (qmail 9096 invoked by uid 500); 22 Feb 2007 03:16:33 -0000 Mailing-List: contact dev-help@activemq.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@activemq.apache.org Delivered-To: mailing list dev@activemq.apache.org Received: (qmail 9087 invoked by uid 99); 22 Feb 2007 03:16:32 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 21 Feb 2007 19:16:32 -0800 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO brutus.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 21 Feb 2007 19:16:23 -0800 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 9F4B37141E2 for ; Wed, 21 Feb 2007 19:16:03 -0800 (PST) Message-ID: <10447259.1172114163649.JavaMail.jira@brutus> Date: Wed, 21 Feb 2007 19:16:03 -0800 (PST) From: "bhumika thakkar (JIRA)" To: dev@activemq.apache.org Subject: [jira] Commented: (AMQ-1142) TemporaryQueue communication not working MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/activemq/browse/AMQ-1142?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_38561 ] bhumika thakkar commented on AMQ-1142: -------------------------------------- I came across a similar issue with temporaray queues. The message doesn't get sent in even when I use the replyTo property. Here's the test case: public void testQueues() { final JmsTemplate jmsTemplate = getSpringBean("jms.template.quoteProcessor", JmsTemplate.class); try { final Connection connection = jmsTemplate.getConnectionFactory().createConnection(); Session session = connection.createSession(true, 1); final Destination destination = session.createTemporaryQueue(); Thread senderThread = new Thread(new Runnable() { public void run() { try { System.out.println("In Sender Thread"); Session session = connection.createSession(true, 1); session.createProducer(destination).send(session.createTextMessage("my message")); System.out.println("sent message to queue: " + destination); } catch (JMSException e) { // TODO Auto-generated catch block e.printStackTrace(); } } }); senderThread.start(); Thread.currentThread().sleep(6000); Thread receiverThread = new Thread(new Runnable() { public void run() { try { System.out.println("In Receiver Thread"); Session session = connection.createSession(true, 1); System.out.println("my session: " + session + ", queue: " + destination); MessageConsumer consumer = session.createConsumer(destination); System.out.println("my consumer: " + consumer); Message message = consumer.receive(); System.out.println("Got this message: " + message.toString()); } catch (JMSException e) { // TODO Auto-generated catch block e.printStackTrace(); } } }); receiverThread.start(); Thread.currentThread().sleep(6000); System.out.println("Done!"); } catch (InterruptedException e) { // TODO Auto-generated catch block e.printStackTrace(); } catch (JMSException e1) { // TODO Auto-generated catch block e1.printStackTrace(); } } output: In Sender Thread sent message to queue: temp-queue://ID:shell.dev.norvax.net-53936-1172097041334-2:1:1 In Receiver Thread my session: ManagedSessionProxy { ActiveMQSession {id=ID:shell.dev.norvax.net-53936-1172097041334-2:1:3,started=false} }, queue: temp-queue://ID:shell.dev.norvax.net-53936-1172097041334-2:1:1 my consumer: ActiveMQMessageConsumer { value=ID:shell.dev.norvax.net-53936-1172097041334-2:1:3:1, started=false } Done! It did not receive the message. > TemporaryQueue communication not working > ---------------------------------------- > > Key: AMQ-1142 > URL: https://issues.apache.org/activemq/browse/AMQ-1142 > Project: ActiveMQ > Issue Type: Bug > Components: Broker, JMS client > Affects Versions: 4.1.0 > Environment: WinXP, Java 1.4.2 > Reporter: Jos > Attachments: Client.java, Server.java > > > Assume a (old legacy, yes this is out of date and better solutions are available) point to point architecture: > Client creates temporary queues and send the queuename to the server by a fixed queue ('command queue') > Server uses the received queue names to send messages to the client. > See the attached Code snippets: > * Start the Server > * Start the Client > * The Client creates a temporary queue and sends the name to the server > * Server receives message and sends a test message back. > * Client NEVER receives the test message > This works 100% on IBM MQSeries (the only source diff is the line that has a MQSerie getQueue API call, instead a createQueue, because queus are defined, and not dynamical as in ActiveMQ) > ActiveMQ LOG information: > The temporary queue is logged, but later it says that there are no subscriptions > (..) > DEBUG AbstractRegion - Adding destination: topic://ActiveMQ.Advisory.Consumer.Queue.ID:TIGER-2615-1170064714906-1:0:1 > DEBUG JournalPersistenceAdapter - Checkpoint done. > DEBUG TIGER-2615-1170064714906-1:0:1 - No subscriptions registered, will not dispatch message at this time. > (...) > Can this bug be fixed? > Thank you, Jos -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.