The moose likes EJB and Other Java EE Technologies and the fly likes Force delay in message driven beans. Is it possible? Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Java » EJB and Other Java EE Technologies
Reply Bookmark "Force delay in message driven beans. Is it possible?" Watch "Force delay in message driven beans. Is it possible?" New topic
Author

Force delay in message driven beans. Is it possible?

Pablo Fernandez
Greenhorn

Joined: Jan 12, 2010
Posts: 3
Hi guys, can somebody help me with something?

When a message reaches the beginning of a queue, is it possible to force an X amount of time before it gets processed? I don't want to do it by coding into it, but I was wondering if the queue can be configured somehow.

I need to ensured a fixed amount of time between the moment the client transaction sends the message to the queue and the moment it actually gets processed.

Can it be done?

thanks in advance,

pol
domenico febbo
Greenhorn

Joined: Mar 24, 2009
Posts: 4
You should use setTimeToDeliver(timeToDeliver), but the implementation depends on the JMS server.
ramprasad madathil
Ranch Hand

Joined: Jan 24, 2005
Posts: 489

You should use setTimeToDeliver(timeToDeliver), but the implementation depends on the JMS server.


Is that api part of the jms spec? I think it is weblogic specific.

ram.
Pablo Fernandez
Greenhorn

Joined: Jan 12, 2010
Posts: 3
ramprasad madathil wrote:
You should use setTimeToDeliver(timeToDeliver), but the implementation depends on the JMS server.


Is that api part of the jms spec? I think it is weblogic specific.

ram.


I found that it is weblogic specific, but I'm using jboss and got a way to do the same thing.
Something like this:



Anyway, thanks for your answers

pol
 
 
subject: Force delay in message driven beans. Is it possible?
 
Threads others viewed
MDB synchronize onMessage
JMS, MDB, Session bean dan comand patern
Asynchronous message reading in websphere...
Need explanation related to Session.AUTO_ACKNOWLEDGE
duplicate messages JMS
IntelliJ Java IDE