Scheduling services

A common requirement is to schedule a process or service to run at regular intervals. For example, the oBay accountBilling process is required to be run once every night. One approach would be to use a scheduling tool; there are a number of tools available for this, including:

  • Quartz: This is an open source, Java-based scheduler. The advantage of Quartz is that it is already used internally by the BPEL engine for scheduling, so is available to use as part of the SOA Suite platform. However, this approach requires knowledge of the API as well as Java.
  • Oracle Database Job Scheduler: Provided as part of the Oracle Database, such as Quartz. It is available regardless of which platform you are running the SOA Suite on (assuming you are using Oracle as the backend database). However, it requires knowledge of PL/SQL.

While these are all perfectly valid approaches, they all require knowledge of components outside the SOA suite; an alternate approach is to use BPEL to implement the scheduler.

One approach is to implement a BPEL process which continuously loops, with the sole purpose of launching other scheduled BPEL processes. However, as the process never dies, this will result in an ever increasing audit trail, causing the objects persisted in the database as well as the in-memory size of the process to grow over time, which eventually will have a negative impact on the performance of the engine.

A better approach is to have an XML file that specifies a series of one or more services (or jobs) to be scheduled. We can then use the file adapter to read this file and trigger a scheduling process which can invoke each of the scheduled jobs. Once all jobs have been triggered then the scheduling process can be allowed to complete.

The trick with this approach is to re-cycle the scheduling file; that is, in the process of reading the file, the file adapter will move it to an archive directory. To ensure the scheduling process is re-run every day, we need to move the file back into the directory being polled by the adapter. We can do this using the scheduling process.

Do you need help with Oracle? Gain advice from Builder AU forums

Comments

1

apple - 02/07/10

There is a efficient tool called Microsoft Online Services, based on Microsoft Office SharePoint Server 2007, SharePoint Online delivers collaboration capabilities to enable team members to collaborate, find organizational resources, search your intranet site, and manage content and workflow.We can handle multiple exchanges of messages and message interaction pattern.More content click http://www.onlinesc.com

» Report offensive content

1

apple - 07/02/10

There is a efficient tool called Microsoft Online Services, based on Microsoft Office SharePoint Server 2007, SharePoint Online delivers collaboration capabilities ... more

Log in


Sign up | Forgot your password?

What's on?

  • Optus Deal

    Broadband + home phone + PlayStation®3 in a single package price!