• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Redelivery problem in JMS

 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello,
Here is my problem:
I use Java Message Service 1.0.2 Reference Implementation.
I have container managed MDB. If application cannot process message in
onMessage method it calls setRollBackOnly() method to return message
to MQ. But container imidiatly calls again onMessage() method and
deliver that message. As application is still unable to process that
message (waiting for some event to happend) it returns message back to
MQ.
Questions are:
1. How can I force the redelivery of a rolled back JMS message to
happen in a few minutes instead of immediately?
2. What happens with message when max number of attempts exides? How
can I get that message after that? It seems to me as if they
disappear.
3. Is it possible to set the redelivery delay time or error
destinations in JMS 1.0.2 Reference Implementation or in Sun ONE
Message Queue Version 3.0?
Thanks for any help
 
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Attila Barbocz:
Hello,
Here is my problem:
I use Java Message Service 1.0.2 Reference Implementation.
I have container managed MDB. If application cannot process message in
onMessage method it calls setRollBackOnly() method to return message
to MQ. But container imidiatly calls again onMessage() method and
deliver that message. As application is still unable to process that
message (waiting for some event to happend) it returns message back to
MQ.
Questions are:
1. How can I force the redelivery of a rolled back JMS message to
happen in a few minutes instead of immediately?
2. What happens with message when max number of attempts exides? How
can I get that message after that? It seems to me as if they
disappear.
3. Is it possible to set the redelivery delay time or error
destinations in JMS 1.0.2 Reference Implementation or in Sun ONE
Message Queue Version 3.0?
Thanks for any help

 
Kiran Bandi
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by prasanth reddy:
[QB][/QB]



Sorry my previous posting was a mistake ...
When you rollback are you rolling back to same queue/topic ?
Looks like you are doing exactly that. Create another topic/queue and send the rolled back message to that topic/queue.
when you send it to the same topic it come back instantly to onMessage().
I dont understand what you are going to do by sending the message to the source system you can as well log the failed message to a log file and look in to it later .
 
Ranch Hand
Posts: 2713
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The answer to your questions are entirely dependent on the JMS implementation.
Most JMS implementations allow you to configure a delay period between redelivery, however I am not sure if this feature is part of the reference implementation. I would venture that it is not.
Likewise, a max resend count can typically be configured in JMS implementations. After the resend count is reached the message can be configured to go to a "dead letter" queue in most implementations. Again, it is unlikely that the reference implementation addresses this.
For questions on the Sun One JMS implementation, I suggest you post to the Sun[tm] ONE Application Server Forum.
[ April 22, 2003: Message edited by: Chris Mathews ]
 
reply
    Bookmark Topic Watch Topic
  • New Topic