aspose file tools*
The moose likes EJB and other Java EE Technologies and the fly likes can't receive hornetq  jms message Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "can Watch "can New topic
Author

can't receive hornetq jms message

Prateek Kumar Singh
Greenhorn

Joined: Jan 21, 2011
Posts: 29

Hi,

i'm using hornetq with Tomcat 7.0 JMS my message sint successfully but could not recive it.

session.createQueue(queueName, queueName,true);
session.start();
ClientConsumer consumer = session.createConsumer("queue1");

System.out.println("ClientSession started!");
ClientMessage cmessage=null;
while (true) {//inner loop
System.out.println("in loop:"+consumer);
cmessage = consumer.receive(); // problem is here

System.out.println("message=="+cmessage);
System.out.println(cmessage.getBodyBuffer().readString());
pw.print(cmessage.getStringProperty("RepositoryName"));
System.out.println(cmessage.getStringProperty("FormName").toString());
}
//QueueUtil.receiveMessages("MWS1");

//new Consumer().consumerMsg();
pw.print("<h1>Message receive complete</h1>");
}


can anybody give answer?
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: can't receive hornetq jms message