aspose file tools
The moose likes EJB and other Java EE Technologies and the fly likes JMS Consumer not receiving any messages. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCA Java SE 8 Programmer I Study Guide 1Z0-808 this week in the OCAJP forum!
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "JMS Consumer not receiving any messages." Watch "JMS Consumer not receiving any messages." New topic
Author

JMS Consumer not receiving any messages.

Jigar Naik
Ranch Hand

Joined: Dec 12, 2006
Posts: 760
Hi bellow is the code for JMS Consumer. I have tried to debug the code but the program is not calling onMessage() even though there are messages.

am i missing something ?



Jigar Naik


Jigar Naik
Ranch Hand

Joined: Dec 12, 2006
Posts: 760
Hey,

I have commented the following line of code, and i received all the messages.



but then when should i close the consumer, session and connection ???
Scott Selikoff
author
Saloon Keeper

Joined: Oct 23, 2005
Posts: 3738
    
  10

In a finally block, to guarantee they get closed.


[OCA 8 Book] [Blog]
Jigar Naik
Ranch Hand

Joined: Dec 12, 2006
Posts: 760
all right.. thanks
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: JMS Consumer not receiving any messages.