Posted: Thu Mar 04, 2010 10:06 am Post subject: Retry after few hours ...
Newbie
Joined: 21 Oct 2009 Posts: 1
Hello MQ experts,
Currently we are doing this:
1. Client program get the message from Q
2. Client program calls a webservice
3. if webservice is down, then move the message to failQ
4. Process the messages from failQ manually when the webservice is back up again
Now, we want to do this:
1. Client program get the message from Q
2. Client program calls a webservice
3. if webservice is down, then move the message BACK to original Q with s SLEEP time on it, say 3 hours or so (assuming the webservice comes back up during this time)
4. After 3 hours, this message should be available to be "GET" by the client program and try processing it again.
How can we achieve this? and are there any better ways of doing this?
Sure.
In your program
1) MQGet with Transaction
2) Try webservice
3) If webservice fails
3a) Rollback MQ transaction
3b) sleep() for three hours
3c) wake up, go to 1
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum