[jboss-user] [jBPM] - Re: Scalable use of Timer Events

Maciej Swiderski do-not-reply at jboss.com
Thu Jun 14 03:37:42 EDT 2012


Maciej Swiderski [https://community.jboss.org/people/swiderski.maciej] created the discussion

"Re: Scalable use of Timer Events"

To view the discussion, visit: https://community.jboss.org/message/741662#741662

--------------------------------------------------------------
Be default timer service is created with thread pool of size one so that is why you observe this behavior. There are two things you could do:
1. use separate session as timer service is per session
2. increase number of threads in the pool by registering timer service on your own

If you go for option two, here are some hints:
- if using persistence then make use of JpaJDKTimerService 
- if not use JDKTimerService 

both have constructors that accepts integer that will be used as size of the pool.

To set this you should use session configuration and set class name for property *drools.timerService*. As you can see it requires class name and not the instance itself so there is no easy way to set the desired pool size as that uses default constructor. One way to go is to simply extend one of the timer service implementation and make sure that your custom class default constructor will set the pool size to higher value.

HTH
--------------------------------------------------------------

Reply to this message by going to Community
[https://community.jboss.org/message/741662#741662]

Start a new discussion in jBPM at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2034]

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20120614/05d79d60/attachment-0001.html 


More information about the jboss-user mailing list