Class ScheduleService

java.lang.Object
org.chenile.scheduler.db.ScheduleService
All Implemented Interfaces:
SmartInitializingSingleton

public class ScheduleService extends Object implements SmartInitializingSingleton
Saves, reads and deletes the caller tenant's schedules, and keeps ChenileScheduler in step: a change is scheduled after its transaction commits. At startup every stored schedule is scheduled, and the scheduler is told to read definitions from the database when they fire, so that a schedule saved on one node fires correctly on another.

With a database per tenant the stored schedules are loaded tenant by tenant (TenantSupplier, TenantScope); without tenants (one database, or no multi-datasource-utils) they are loaded once.