public class ResourceQueueProvider extends Object implements DistributionQueueProvider
Modifier and Type | Field and Description |
---|---|
static String |
QUEUES_ROOT |
static String |
TYPE |
Constructor and Description |
---|
ResourceQueueProvider(org.osgi.framework.BundleContext context,
org.apache.sling.api.resource.ResourceResolverFactory resolverFactory,
String serviceName,
String agentName,
org.apache.sling.commons.scheduler.Scheduler scheduler,
boolean isActive) |
Modifier and Type | Method and Description |
---|---|
void |
close() |
void |
disableQueueProcessing()
disables queue processing
|
void |
enableQueueProcessing(@NotNull DistributionQueueProcessor queueProcessor,
String... queueNames)
enables queue processing
|
@NotNull DistributionQueue |
getQueue(@NotNull String queueName)
provide an
DistributionQueueType.ORDERED queue with the given name |
@NotNull DistributionQueue |
getQueue(@NotNull String queueName,
@NotNull DistributionQueueType type)
provde a queue of the given type with the given name
|
public static final String TYPE
public static final String QUEUES_ROOT
@NotNull public @NotNull DistributionQueue getQueue(@NotNull @NotNull String queueName) throws DistributionException
DistributionQueueProvider
DistributionQueueType.ORDERED
queue with the given namegetQueue
in interface DistributionQueueProvider
queueName
- the name of the queue to retrieveDistributionQueue
DistributionException
@NotNull public @NotNull DistributionQueue getQueue(@NotNull @NotNull String queueName, @NotNull @NotNull DistributionQueueType type)
DistributionQueueProvider
getQueue
in interface DistributionQueueProvider
queueName
- the name of the queuetype
- the type of the queueDistributionQueue
public void enableQueueProcessing(@NotNull @NotNull DistributionQueueProcessor queueProcessor, String... queueNames) throws DistributionException
DistributionQueueProvider
enableQueueProcessing
in interface DistributionQueueProvider
queueProcessor
- the queue processor to be usedDistributionException
public void disableQueueProcessing() throws DistributionException
DistributionQueueProvider
disableQueueProcessing
in interface DistributionQueueProvider
DistributionException
public void close()
Copyright © 2007–2021 The Apache Software Foundation. All rights reserved.