Package org.apache.sling.event.jobs
Interface QueueConfiguration
The configuration of a queue.
- Since:
- 3.0
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic enumThe thread priority.static enumThe queue type. -
Method Summary
Modifier and TypeMethodDescriptionintReturn the max number of parallel processes.intReturn the max number of retries, -1 for endless retry!intReturn the size for the optional thread pool for this queue.intGet the ranking of this configuration.longReturn the retry delay in msReturn the thread priority for the job threadString[]The list of topics this queue is bound to.getType()Return the queue type.booleanWhether successful jobs are kept for a complete historybooleanPrefer to run the job on the same instance it was created on.
-
Method Details
-
getRetryDelayInMs
long getRetryDelayInMs()Return the retry delay in ms- Returns:
- The retry delay
-
getMaxRetries
int getMaxRetries()Return the max number of retries, -1 for endless retry!- Returns:
- Max number of retries
-
getType
QueueConfiguration.Type getType()Return the queue type.- Returns:
- The queue type
-
getThreadPriority
QueueConfiguration.ThreadPriority getThreadPriority()Return the thread priority for the job thread- Returns:
- Thread priority
-
getMaxParallel
int getMaxParallel()Return the max number of parallel processes.- Returns:
- Max parallel processes
-
getTopics
String[] getTopics()The list of topics this queue is bound to.- Returns:
- All topics for this queue.
-
isKeepJobs
boolean isKeepJobs()Whether successful jobs are kept for a complete history- Returns:
trueif successful jobs are kept.- Since:
- 1.3
-
getOwnThreadPoolSize
int getOwnThreadPoolSize()Return the size for the optional thread pool for this queue.- Returns:
- A positive number or
0if the default thread pool should be used. - Since:
- 1.3
-
getRanking
int getRanking()Get the ranking of this configuration.- Returns:
- The ranking
-
isPreferRunOnCreationInstance
boolean isPreferRunOnCreationInstance()Prefer to run the job on the same instance it was created on.- Returns:
trueif running on the creation instance is preferred.- Since:
- 1.4
-