Question

I have bind terracotteJobStore with Quartz-Scheduler

how can terracotteJobStore determine which job should next for which node for execution?

which algorithm uses for node selection in terracotteJobStore any idea ??

Was it helpful?

Solution

With OS Terracotta's JobStore you don't get to decide which node the job will be executed on. Not that it really happens randomly, but the scheduler behaves as in non-clustered mode. So basically, every node will, at a regular interval and, based on the next trigger to fire when to acquire the next trigger(s). Since all the nodes in cluster behave the same way, the first to acquire the lock, will also be able to acquire triggers first.

Terracotta EE comes with the Quartz Where feature that lets you describe where jobs should be fired. You learn more on Quartz Where by watching this short screencast I did: http://www.codespot.net/blog/2011/03/quartz-where-screencast/

Hope that'll help.

OTHER TIPS

If 'Quartz Scheduler' is used with 'TerracotteJobStore' ,and there is any Job next to execute then selection of Node for that Job will be Random.

Using 'Qurtz Where' it is possible to make Job on criteria base. Means if u want to make a Job that must run on a Node which have core at least 2 or to make a Job which run on a Node which have 70% CPU load average or to make a Job which run on a Node which have at least Java Heap Free memory 330 MB in such case 'Quartz Where' is useful.

It is predictable on which Node , Job will execute only in the case of "Quartz Where'.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top