DevOps Zone is brought to you in partnership with:

Rob Gordon is a seasoned Java developer and a big fan of open source. Oddjob is his own open source project to make job scheduling and task automation in Java much much easier. Rob is based in London. Rob is a DZone MVB and is not an employee of DZone and has posted 17 posts at DZone. You can read more from them at their website. View Full User Profile

Feature Comparison of Java Job Schedulers – Plus One

  • submit to reddit

Poor Oddjob, I thought as I read Craig Flichel’s Feature Comparison of Java Job Schedulers featuring Obsidian, Quartz, Cron4j and Spring. Yet again it hasn’t made the grade, it’s been passed over for the scheduling team.

Never mind I say, you’re just a little bit different and misunderstood. Let’s have a kick about in the back yard and see what you can do…

Real-time Schedule Changes / Real-time Job Configuration

Oddjob: Yes

Here is Oddjob’s Client GUI, connecting to an instance of Oddjob running as a Windows Service on my home PC.

My Oddjob InstanceMy Oddob instance sends me a reminder email when it’s someone’s birthday, and also tells me when it’s going to rain. The swing UI allows complete configuration of the server. With it I can configure the jobs and their schedules, but unfortunately I can’t control the weather!

Ad-hoc Job Submission: Yes
Configurable Job Conflicts: Not Really Applicable

Ad-hoc job submission is really what Oddjob is all about. Many jobs won’t be scheduled at all and will sit in a folder to be manually run as required. To run a job, scheduled or not, just click ‘run’ from the job menu.

Job conflicts aren’t really a problem for Oddjob because it won’t reschedule a job again until it’s finished. If a job’s next slot has passed, you have the choice to run immediately or skip missed runs and reschedule from the current time. If you want concurrent execution you can configure different jobs to run at the same time or use a single schedule and launch the jobs in parallel.

Manually Stopping a job is just as easy as running it. Click ‘stop’ from the job menu.

Code- and XML-Free Job Configuration

Oddjob: Yes

You saw this in the first section. Oddjob’s configuration is via a UI and is done in real time. In fact I often start one job as I’m configuring the next. It’s all very interactive.

Oddjob uses XML behind the scenes for those that like to see under the hood.

Job Event Subscription/Notification

Oddjob: Yes

It’s very easy to trigger a job based on the completion state of another job. You would have to write code to listen to configuration changes though.

Custom Listeners: Undocumented
Job Chaining: Yes

There’s lots of options for job chaining, sequential, parallel, or cascade, and any nested combinations thereof.

Adding a custom Stateful listener would be easy enough, and might be useful if embedding Oddjob but this isn’t the normal use case. The unit tests do this extensively however.

Monitoring & Management UI

Oddjob: Yes

The same UI allows you to see the job state, job by job log messages, the console of an Exec Job, and the run time properties of all the jobs.

Zero Configuration Clustering and Load Sharing

Oddjob: Kind Of

Oddjob has a Grab Job so you can run the same configuration on several servers and have them compete for work. I wrote it as a proof of concept but I’ve never had cause to use it in the field and I haven’t had any reports that others have either.

Job Execution Host Affinity: Kind Of

In the same way that you add the ‘Grab job’ to many servers to share work, you could in theory just add Grab for a particular job to only certain servers. I guess this is server Affinity?

Scripting Language Support in Jobs

Oddjob: Yes

Oddjob has a Script Job for any language that supports the Java Scripting Framework. JavaScript is shipped by default.With the Script Job you can also interact with Oddjob to use the properties of other jobs, and set variables for other jobs to use.

Scheduling Precision

Oddjob: Millisecond

In theory Oddjob can schedule with millisecond precision, but this isn’t usual practice. Polling for a file every 30 seconds, for instance, is normally fine.

Job Scheduling & Management REST API

Oddjob: JMX Only

No REST API. You can embed the JMX Client easily enough and control everything from Java, but not for other languages. Not yet.

Custom Calendar Support

Oddjob: Yes

Oddjob has the concept of breaking a schedule with another. The breaks can be as flexible as the job schedule itself – define days, weeks or just a few hours off for a task. The Scheduling section of the User Guide has much more on Oddjob’s flexible scheduling capabilities.


Oddjob has many other features to make automating repetitive tasks easy. One noteworthy feature is the ease of adding custom jobs by just implementing java.lang.Runnable.

Oddjob is undeniably an amateur player in the Scheduler league, and one that is often overlooked. With its Apache licence it is completely free and open. Why not check it out when you have an hour or two? You might be pleasantly surprised by the quality of play.

Published at DZone with permission of Rob Gordon, author and DZone MVB. (source)

(Note: Opinions expressed in this article and its replies are the opinions of their respective authors and not those of DZone, Inc.)


Rauf Issa replied on Fri, 2013/03/08 - 4:19pm

JobServer  is another option. Has rich scheduling rules and jobs can be triggered manually or via api. Has feature set of web UIs for real-time and historical reporting. Also includes cool prediction reports that will tell what jobs are expected to run at any time range in the future. And has all other basic stuff for alerting and triggering...etc

For developers, JobServer leverages a cool open source SDK called soafaces  that makes developing new java Tasklets fun.

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.