Class RabbitProperties

java.lang.Object
org.springframework.boot.autoconfigure.amqp.RabbitProperties

@ConfigurationProperties(prefix="spring.rabbitmq") public class RabbitProperties extends Object
Configuration properties for Rabbit.
Since:
1.0.0
Author:
Greg Turnquist, Dave Syer, Stephane Nicoll, Andy Wilkinson, Josh Thornhill, Gary Russell, Artsiom Yudovin, Franjo Zilic, EddĂș MelĂ©ndez, Rafael Carvalho, Scott Frederick, Lasse Wulff, Yanming Zhou
  • Constructor Details

    • RabbitProperties

      public RabbitProperties()
  • Method Details

    • getHost

      public String getHost()
    • determineHost

      public String determineHost()
      Returns the host from the first address, or the configured host if no addresses have been set.
      Returns:
      the host
      See Also:
    • setHost

      public void setHost(String host)
    • getPort

      public Integer getPort()
    • determinePort

      public int determinePort()
      Returns the port from the first address, or the configured port if no addresses have been set.
      Returns:
      the port
      See Also:
    • setPort

      public void setPort(Integer port)
    • getAddresses

      public List<String> getAddresses()
    • determineAddresses

      public List<String> determineAddresses()
      Returns the configured addresses or a single address (host:port) created from the configured host and port if no addresses have been set.
      Returns:
      the addresses
    • setAddresses

      public void setAddresses(List<String> addresses)
    • getUsername

      public String getUsername()
    • determineUsername

      public String determineUsername()
      If addresses have been set and the first address has a username it is returned. Otherwise returns the result of calling getUsername().
      Returns:
      the username
      See Also:
    • setUsername

      public void setUsername(String username)
    • getPassword

      public String getPassword()
    • determinePassword

      public String determinePassword()
      If addresses have been set and the first address has a password it is returned. Otherwise returns the result of calling getPassword().
      Returns:
      the password or null
      See Also:
    • setPassword

      public void setPassword(String password)
    • getSsl

      public RabbitProperties.Ssl getSsl()
    • getVirtualHost

      public String getVirtualHost()
    • determineVirtualHost

      public String determineVirtualHost()
      If addresses have been set and the first address has a virtual host it is returned. Otherwise returns the result of calling getVirtualHost().
      Returns:
      the virtual host or null
      See Also:
    • setVirtualHost

      public void setVirtualHost(String virtualHost)
    • getAddressShuffleMode

      public org.springframework.amqp.rabbit.connection.AbstractConnectionFactory.AddressShuffleMode getAddressShuffleMode()
    • setAddressShuffleMode

      public void setAddressShuffleMode(org.springframework.amqp.rabbit.connection.AbstractConnectionFactory.AddressShuffleMode addressShuffleMode)
    • getRequestedHeartbeat

      public Duration getRequestedHeartbeat()
    • setRequestedHeartbeat

      public void setRequestedHeartbeat(Duration requestedHeartbeat)
    • getRequestedChannelMax

      public int getRequestedChannelMax()
    • setRequestedChannelMax

      public void setRequestedChannelMax(int requestedChannelMax)
    • isPublisherReturns

      public boolean isPublisherReturns()
    • setPublisherReturns

      public void setPublisherReturns(boolean publisherReturns)
    • getConnectionTimeout

      public Duration getConnectionTimeout()
    • setPublisherConfirmType

      public void setPublisherConfirmType(org.springframework.amqp.rabbit.connection.CachingConnectionFactory.ConfirmType publisherConfirmType)
    • getPublisherConfirmType

      public org.springframework.amqp.rabbit.connection.CachingConnectionFactory.ConfirmType getPublisherConfirmType()
    • setConnectionTimeout

      public void setConnectionTimeout(Duration connectionTimeout)
    • getChannelRpcTimeout

      public Duration getChannelRpcTimeout()
    • setChannelRpcTimeout

      public void setChannelRpcTimeout(Duration channelRpcTimeout)
    • getMaxInboundMessageBodySize

      public DataSize getMaxInboundMessageBodySize()
    • setMaxInboundMessageBodySize

      public void setMaxInboundMessageBodySize(DataSize maxInboundMessageBodySize)
    • getCache

      public RabbitProperties.Cache getCache()
    • getListener

      public RabbitProperties.Listener getListener()
    • getTemplate

      public RabbitProperties.Template getTemplate()
    • getStream

      public RabbitProperties.Stream getStream()