Class QScheduleManager
java.lang.Object
com.kingsrook.qqq.backend.core.scheduler.QScheduleManager
QQQ service to manage scheduled jobs, using 1 or more Schedulers - implementations
of the QSchedulerInterface
-
Method Summary
Modifier and TypeMethodDescriptionstatic void
defineDefaultSchedulableTypesInInstance
(QInstance qInstance) static QScheduleManager
Singleton accessorstatic QScheduleManager
initInstance
(QInstance qInstance, Supplier<QSession> systemUserSessionSupplier) Singleton initiator - e.g., must be called to initially initialize the singleton before anyone else calls getInstance (they'll get an error if they call that first).void
void
void
setupScheduledJob
(ScheduledJob scheduledJob) void
start()
void
stop()
void
void
unInit()
reset the singleton instance (to null); clear the map of schedulers.void
void
unscheduleScheduledJob
(ScheduledJob scheduledJob)
-
Method Details
-
initInstance
public static QScheduleManager initInstance(QInstance qInstance, Supplier<QSession> systemUserSessionSupplier) throws QException Singleton initiator - e.g., must be called to initially initialize the singleton before anyone else calls getInstance (they'll get an error if they call that first).- Throws:
QException
-
defineDefaultSchedulableTypesInInstance
-
getInstance
Singleton accessor -
start
- Throws:
QException
-
stop
public void stop() -
stopAsync
public void stopAsync() -
setupAllNewSchedules
- Throws:
QException
-
setupAllSchedules
- Throws:
QException
-
setupScheduledJob
- Throws:
QException
-
unscheduleAll
public void unscheduleAll() -
unscheduleScheduledJob
- Throws:
QException
-
unInit
public void unInit()reset the singleton instance (to null); clear the map of schedulers. Not clear it's ever useful to call in main-code - but can be used for tests.
-