Package com.github.sonus21.rqueue.core
Class MessageScheduler
java.lang.Object
com.github.sonus21.rqueue.core.MessageScheduler
- All Implemented Interfaces:
EventListener,org.springframework.beans.factory.DisposableBean,org.springframework.context.ApplicationListener<RqueueBootstrapEvent>
- Direct Known Subclasses:
ProcessingQueueMessageScheduler,ScheduledQueueMessageScheduler
public abstract class MessageScheduler
extends Object
implements org.springframework.beans.factory.DisposableBean, org.springframework.context.ApplicationListener<RqueueBootstrapEvent>
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoiddestroy()protected abstract StringgetChannelName(String queueName) protected abstract org.slf4j.Loggerprotected longprotected abstract longgetNextScheduleTime(String queueName, Long value) protected longprotected com.github.sonus21.rqueue.core.ScheduledTaskDetailgetScheduledTask(String queueName) protected abstract Stringprotected abstract intprotected abstract StringgetZsetName(String queueName) protected voidprotected abstract booleanisProcessingQueue(String queueName) voidprotected void
-
Field Details
-
rqueueSchedulerConfig
-
rqueueConfig
-
-
Constructor Details
-
MessageScheduler
public MessageScheduler()
-
-
Method Details
-
getLogger
protected abstract org.slf4j.Logger getLogger() -
getNextScheduleTime
-
getChannelName
-
getZsetName
-
getThreadNamePrefix
-
getThreadPoolSize
protected abstract int getThreadPoolSize() -
isProcessingQueue
-
getQueueStartTime
protected long getQueueStartTime() -
destroy
- Specified by:
destroyin interfaceorg.springframework.beans.factory.DisposableBean- Throws:
Exception
-
getScheduledTask
-
schedule
-
initialize
protected void initialize() -
onApplicationEvent
- Specified by:
onApplicationEventin interfaceorg.springframework.context.ApplicationListener<RqueueBootstrapEvent>
-
getMinDelay
protected long getMinDelay()
-