Class ExchangeInfo

java.lang.Object
org.acemq.rabbitmq.admin.ExchangeInfo

public final class ExchangeInfo extends Object
An exchange as the broker holds it.

Worth having for the same reason as QueueInfo and one more: AMQP cannot inspect an exchange at all. A passive declare fails the channel when it is absent, and a real declare refuses when the type differs — so a topology planner over AMQP alone reports every exchange as a creation, whether or not it is already there. That limitation is documented in TopologyPlanner; this is what removes it.

  • Constructor Details

    • ExchangeInfo

      public ExchangeInfo(String name, String vhost, String type, boolean durable, boolean autoDelete, boolean internal, Map<String,Object> arguments)
  • Method Details

    • name

      public String name()
      Returns:
      the exchange's name. The default exchange is the empty string, which is a real exchange rather than an absence, and appears in listings as one
    • vhost

      public String vhost()
    • type

      public String type()
      Returns:
      direct, topic, fanout or headers
    • durable

      public boolean durable()
    • autoDelete

      public boolean autoDelete()
    • internal

      public boolean internal()
      Returns:
      whether it is internal, meaning a publisher cannot publish to it directly. The retry ladder's exchange is one: messages reach it by dead-lettering, never by being sent
    • arguments

      public Map<String,Object> arguments()
    • toString

      public String toString()
      Overrides:
      toString in class Object