Class MirroredQueue

java.lang.Object
org.apache.activemq.broker.region.virtual.MirroredQueue
All Implemented Interfaces:
BrokerServiceAware, DestinationInterceptor

public class MirroredQueue extends Object implements DestinationInterceptor, BrokerServiceAware
Creates Mirrored Queue using a prefix and postfix to define the topic name on which to mirror the queue to.
  • Constructor Details

    • MirroredQueue

      public MirroredQueue()
  • Method Details

    • intercept

      public Destination intercept(Destination destination)
      Specified by:
      intercept in interface DestinationInterceptor
    • remove

      public void remove(Destination destination)
      Specified by:
      remove in interface DestinationInterceptor
    • create

      public void create(Broker broker, ConnectionContext context, org.apache.activemq.command.ActiveMQDestination destination)
      Specified by:
      create in interface DestinationInterceptor
    • getPostfix

      public String getPostfix()
    • setPostfix

      public void setPostfix(String postfix)
      Sets any postix used to identify the queue consumers
    • getPrefix

      public String getPrefix()
    • setPrefix

      public void setPrefix(String prefix)
      Sets the prefix wildcard used to identify the queue consumers for a given topic
    • isCopyMessage

      public boolean isCopyMessage()
    • setCopyMessage

      public void setCopyMessage(boolean copyMessage)
      Sets whether a copy of the message will be sent to each destination. Defaults to true so that the forward destination is set as the destination of the message
    • setBrokerService

      public void setBrokerService(BrokerService brokerService)
      Specified by:
      setBrokerService in interface BrokerServiceAware
    • getMirrorDestination

      protected Destination getMirrorDestination(Destination destination) throws Exception
      Throws:
      Exception
    • getMirrorTopic

      protected org.apache.activemq.command.ActiveMQDestination getMirrorTopic(org.apache.activemq.command.ActiveMQDestination original)