• Post Reply Bookmark Topic Watch Topic
  • New Topic

JMS Query

 
Kathy Watson
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi ranchers,

I have posted this query in the Jboss forum but i guess the question is not bound to one server but may apply to other servers as well.

I am using message driven beans in my application.The MDB does some processing like sending a request to some other system and getting a response from there.This communication happens using a socket connection.What is required is that if I don't get a response fromm the other system the request needs to stay on the queue and keep retrying till a proper response is returned from there.This retry has to be done till the other system is "up" and can return a response to me.
Is this possible and if so how can this be done?.The important thing is that the request should not be lost and should somehow stay on the queue.

Any help is appreciated.
 
Jaikiran Pai
Sheriff
Posts: 10447
227
IntelliJ IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The important thing is that the request should not be lost and should somehow stay on the queue.


If the external system is down, just invoke messageDrivenContext.setRollbackOnly() method which will mean that the message was not processed and hence the JMS server will redeliver it(maybe immidiately , in which case the external system might still be down). You might also be requiring a redelivery delay(and a redelivery limit in your usecase). There was a similar thread in this forum some time back which discussed a similar issue.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!