Package org.graylog.scheduler
Class JobSchedulerService
java.lang.Object
com.google.common.util.concurrent.AbstractExecutionThreadService
org.graylog.scheduler.JobSchedulerService
- All Implemented Interfaces:
com.google.common.util.concurrent.Service
@Singleton
public class JobSchedulerService
extends com.google.common.util.concurrent.AbstractExecutionThreadService
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.google.common.util.concurrent.Service
com.google.common.util.concurrent.Service.Listener, com.google.common.util.concurrent.Service.State
-
Constructor Summary
ConstructorDescriptionJobSchedulerService
(JobExecutionEngine.Factory engineFactory, JobWorkerPool.Factory workerPoolFactory, JobSchedulerConfig schedulerConfig, JobSchedulerClock clock, JobSchedulerEventBus schedulerEventBus, ServerStatus serverStatus, com.github.joschi.jadconfig.util.Duration loopSleepDuration) -
Method Summary
Modifier and TypeMethodDescriptionvoid
handleJobCompleted
(JobCompletedEvent triggerCompletedEvent) protected void
run()
protected void
startUp()
protected void
Methods inherited from class com.google.common.util.concurrent.AbstractExecutionThreadService
addListener, awaitRunning, awaitRunning, awaitRunning, awaitTerminated, awaitTerminated, awaitTerminated, executor, failureCause, isRunning, serviceName, shutDown, startAsync, state, stopAsync, toString
-
Constructor Details
-
JobSchedulerService
@Inject public JobSchedulerService(JobExecutionEngine.Factory engineFactory, JobWorkerPool.Factory workerPoolFactory, JobSchedulerConfig schedulerConfig, JobSchedulerClock clock, JobSchedulerEventBus schedulerEventBus, ServerStatus serverStatus, @Named("job_scheduler_loop_sleep_duration") com.github.joschi.jadconfig.util.Duration loopSleepDuration)
-
-
Method Details
-
startUp
- Overrides:
startUp
in classcom.google.common.util.concurrent.AbstractExecutionThreadService
- Throws:
Exception
-
run
- Specified by:
run
in classcom.google.common.util.concurrent.AbstractExecutionThreadService
- Throws:
Exception
-
handleJobCompleted
-
triggerShutdown
protected void triggerShutdown()- Overrides:
triggerShutdown
in classcom.google.common.util.concurrent.AbstractExecutionThreadService
-