Class RabbitMQQueueConfig


  • public class RabbitMQQueueConfig
    extends java.lang.Object
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected static java.util.Collection<java.lang.String> EXCHANGE_TYPES  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected boolean canEqual​(java.lang.Object other)  
      boolean equals​(java.lang.Object o)  
      java.lang.String getDefaultRoutingKey()  
      java.lang.String getExchangeName()
      exchange name, default is nameless rabbitMQ default exchange
      java.lang.String getExchangeType()
      exchange tpe, accept 4 values: "direct", "fanout", "topic", "headers"
      java.lang.String getQueueName()
      affect when the exchangeName is blank, create queue on default nameless exchange
      java.util.List<java.lang.String> getRoutingKeys()
      affect on consumer, bind queue to all the configured routing keys
      int hashCode()  
      boolean isAckOnFail()
      if true, consumer send ack event the process is failed
      boolean isAutoAck()
      only affect on consumer, set autoAck value in channel.basicConsume
      boolean isAutoDelete()
      set auto delete when declaring queue
      boolean isDurable()
      is queue durable?
      boolean isExclusive()
      make the queue visible only on the current connection
      boolean isMultipleAck()
      affect on consumer only, the second arg in channel.basicAck method
      boolean isRpc()
      auto create response queue for producer, not affect on consumer
      RabbitMQQueueConfig makeCopy()  
      void readFromBObject​(io.gridgo.bean.BObject sourceConfig)  
      void setAckOnFail​(boolean ackOnFail)
      if true, consumer send ack event the process is failed
      void setAutoAck​(boolean autoAck)
      only affect on consumer, set autoAck value in channel.basicConsume
      void setAutoDelete​(boolean autoDelete)
      set auto delete when declaring queue
      void setDurable​(boolean durable)
      is queue durable?
      void setExchangeName​(java.lang.String exchangeName)
      exchange name, default is nameless rabbitMQ default exchange
      void setExchangeType​(java.lang.String exchangeType)
      exchange tpe, accept 4 values: "direct", "fanout", "topic", "headers"
      void setExclusive​(boolean exclusive)
      make the queue visible only on the current connection
      void setMultipleAck​(boolean multipleAck)
      affect on consumer only, the second arg in channel.basicAck method
      void setQueueName​(java.lang.String queueName)
      affect when the exchangeName is blank, create queue on default nameless exchange
      void setRpc​(boolean rpc)
      auto create response queue for producer, not affect on consumer
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, notify, notifyAll, wait, wait, wait
    • Field Detail

      • EXCHANGE_TYPES

        protected static final java.util.Collection<java.lang.String> EXCHANGE_TYPES
    • Constructor Detail

      • RabbitMQQueueConfig

        public RabbitMQQueueConfig​(io.gridgo.bean.BObject sourceConfig)
      • RabbitMQQueueConfig

        public RabbitMQQueueConfig()
    • Method Detail

      • getDefaultRoutingKey

        public java.lang.String getDefaultRoutingKey()
        Returns:
        the queueName if exchangeName is blank, otherwise return the first element found in list rountingKeys. If the list routingKeys is empty, return null;
      • readFromBObject

        public void readFromBObject​(io.gridgo.bean.BObject sourceConfig)
      • getExchangeName

        public java.lang.String getExchangeName()
        exchange name, default is nameless rabbitMQ default exchange
      • getExchangeType

        public java.lang.String getExchangeType()
        exchange tpe, accept 4 values: "direct", "fanout", "topic", "headers"
      • getQueueName

        public java.lang.String getQueueName()
        affect when the exchangeName is blank, create queue on default nameless exchange
      • isDurable

        public boolean isDurable()
        is queue durable?
      • isExclusive

        public boolean isExclusive()
        make the queue visible only on the current connection
      • isAutoDelete

        public boolean isAutoDelete()
        set auto delete when declaring queue
      • isRpc

        public boolean isRpc()
        auto create response queue for producer, not affect on consumer
      • isAutoAck

        public boolean isAutoAck()
        only affect on consumer, set autoAck value in channel.basicConsume
      • isMultipleAck

        public boolean isMultipleAck()
        affect on consumer only, the second arg in channel.basicAck method
      • isAckOnFail

        public boolean isAckOnFail()
        if true, consumer send ack event the process is failed
      • getRoutingKeys

        public java.util.List<java.lang.String> getRoutingKeys()
        affect on consumer, bind queue to all the configured routing keys
      • setExchangeName

        public void setExchangeName​(java.lang.String exchangeName)
        exchange name, default is nameless rabbitMQ default exchange
      • setExchangeType

        public void setExchangeType​(java.lang.String exchangeType)
        exchange tpe, accept 4 values: "direct", "fanout", "topic", "headers"
      • setQueueName

        public void setQueueName​(java.lang.String queueName)
        affect when the exchangeName is blank, create queue on default nameless exchange
      • setDurable

        public void setDurable​(boolean durable)
        is queue durable?
      • setExclusive

        public void setExclusive​(boolean exclusive)
        make the queue visible only on the current connection
      • setAutoDelete

        public void setAutoDelete​(boolean autoDelete)
        set auto delete when declaring queue
      • setRpc

        public void setRpc​(boolean rpc)
        auto create response queue for producer, not affect on consumer
      • setAutoAck

        public void setAutoAck​(boolean autoAck)
        only affect on consumer, set autoAck value in channel.basicConsume
      • setMultipleAck

        public void setMultipleAck​(boolean multipleAck)
        affect on consumer only, the second arg in channel.basicAck method
      • setAckOnFail

        public void setAckOnFail​(boolean ackOnFail)
        if true, consumer send ack event the process is failed
      • equals

        public boolean equals​(java.lang.Object o)
        Overrides:
        equals in class java.lang.Object
      • canEqual

        protected boolean canEqual​(java.lang.Object other)
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object