Class QueueManager

java.lang.Object
org.apache.sling.event.impl.jobs.queues.QueueManager
All Implemented Interfaces:
Runnable, ConfigurationChangeListener, org.osgi.service.event.EventHandler

public class QueueManager extends Object implements Runnable, org.osgi.service.event.EventHandler, ConfigurationChangeListener
Implementation of the queue manager.
  • Constructor Details

    • QueueManager

      public QueueManager()
  • Method Details

    • activate

      protected void activate(Map<String,Object> props)
      Activate this component.
      Parameters:
      props - Configuration properties
    • deactivate

      protected void deactivate()
      Deactivate this component.
    • run

      public void run()
      This method is invoked periodically by the scheduler. In the default configuration every minute
      Specified by:
      run in interface Runnable
      See Also:
    • getQueue

      public org.apache.sling.event.jobs.Queue getQueue(String name)
      Parameters:
      name - The queue name
      Returns:
      The queue or null.
      See Also:
      • JobManager.getQueue(java.lang.String)
    • getQueues

      public Iterable<org.apache.sling.event.jobs.Queue> getQueues()
      Returns:
      An iterator for the available queues.
      See Also:
      • JobManager.getQueues()
    • configurationChanged

      public void configurationChanged(boolean active)
      This method is called whenever the topology or queue configurations change.
      Specified by:
      configurationChanged in interface ConfigurationChangeListener
      Parameters:
      active - Whether the job handling is active atm.
    • handleEvent

      public void handleEvent(org.osgi.service.event.Event event)
      Specified by:
      handleEvent in interface org.osgi.service.event.EventHandler
      See Also:
      • EventHandler.handleEvent(org.osgi.service.event.Event)
    • bindThreadPool

      protected void bindThreadPool(org.apache.sling.event.impl.EventingThreadPool etp)
    • unbindThreadPool

      protected void unbindThreadPool(org.apache.sling.event.impl.EventingThreadPool etp)