Class AmqpMessageChannelSpec<S extends AmqpMessageChannelSpec<S,​T>,​T extends AbstractAmqpChannel>

java.lang.Object
org.springframework.beans.factory.config.AbstractFactoryBean<T>
org.springframework.integration.dsl.IntegrationComponentSpec<S,​C>
org.springframework.integration.dsl.MessageChannelSpec<S,​T>
org.springframework.integration.amqp.dsl.AmqpPollableMessageChannelSpec<S,​T>
org.springframework.integration.amqp.dsl.AmqpMessageChannelSpec<S,​T>
Type Parameters:
S - the target AmqpMessageChannelSpec implementation type.
T - the target channel type.
All Implemented Interfaces:
org.springframework.beans.factory.Aware, org.springframework.beans.factory.BeanClassLoaderAware, org.springframework.beans.factory.BeanFactoryAware, org.springframework.beans.factory.DisposableBean, org.springframework.beans.factory.FactoryBean<T>, org.springframework.beans.factory.InitializingBean, org.springframework.context.Lifecycle, org.springframework.context.Phased, org.springframework.context.SmartLifecycle, org.springframework.integration.dsl.ComponentsRegistration
Direct Known Subclasses:
AmqpPublishSubscribeMessageChannelSpec

public class AmqpMessageChannelSpec<S extends AmqpMessageChannelSpec<S,​T>,​T extends AbstractAmqpChannel>
extends AmqpPollableMessageChannelSpec<S,​T>
Since:
5.0
  • Field Summary

    Fields 
    Modifier and Type Field Description
    protected java.util.List<org.aopalliance.aop.Advice> adviceChain  

    Fields inherited from class org.springframework.integration.amqp.dsl.AmqpPollableMessageChannelSpec

    amqpChannelFactoryBean

    Fields inherited from class org.springframework.integration.dsl.MessageChannelSpec

    channel

    Fields inherited from class org.springframework.integration.dsl.IntegrationComponentSpec

    PARSER, target

    Fields inherited from class org.springframework.beans.factory.config.AbstractFactoryBean

    logger

    Fields inherited from interface org.springframework.beans.factory.FactoryBean

    OBJECT_TYPE_ATTRIBUTE

    Fields inherited from interface org.springframework.context.SmartLifecycle

    DEFAULT_PHASE
  • Constructor Summary

    Constructors 
    Modifier Constructor Description
    protected AmqpMessageChannelSpec​(org.springframework.amqp.rabbit.connection.ConnectionFactory connectionFactory)  
  • Method Summary

    Modifier and Type Method Description
    S acknowledgeMode​(org.springframework.amqp.core.AcknowledgeMode acknowledgeMode)  
    S advice​(org.aopalliance.aop.Advice... advice)  
    S autoStartup​(boolean autoStartup)  
    S batchSize​(int batchSize)
    Configure the batch size.
    S concurrentConsumers​(int concurrentConsumers)  
    protected T doGet()  
    S errorHandler​(org.springframework.util.ErrorHandler errorHandler)  
    S exposeListenerChannel​(boolean exposeListenerChannel)  
    S maxSubscribers​(int maxSubscribers)  
    S phase​(int phase)  
    S prefetchCount​(int prefetchCount)  
    S receiveTimeout​(long receiveTimeout)  
    S recoveryInterval​(long recoveryInterval)  
    S shutdownTimeout​(long shutdownTimeout)  
    S taskExecutor​(java.util.concurrent.Executor taskExecutor)
    Configure an Executor used to invoke the message listener.
    S transactionAttribute​(org.springframework.transaction.interceptor.TransactionAttribute transactionAttribute)
    Configure a TransactionAttribute to be used with the transactionManager(PlatformTransactionManager).
    S transactionManager​(org.springframework.transaction.PlatformTransactionManager transactionManager)
    Configure a PlatformTransactionManager; used to synchronize the rabbit transaction with some other transaction(s).

    Methods inherited from class org.springframework.integration.dsl.MessageChannelSpec

    datatype, getComponentsToRegister, interceptor, messageConverter, wireTap, wireTap, wireTap

    Methods inherited from class org.springframework.integration.dsl.IntegrationComponentSpec

    _this, createInstance, destroyInstance, get, getId, getObjectType, getPhase, isAutoStartup, isRunning, start, stop, stop

    Methods inherited from class org.springframework.beans.factory.config.AbstractFactoryBean

    afterPropertiesSet, destroy, getBeanFactory, getBeanTypeConverter, getEarlySingletonInterfaces, getObject, isSingleton, setBeanClassLoader, setBeanFactory, setSingleton

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • adviceChain

      protected final java.util.List<org.aopalliance.aop.Advice> adviceChain
  • Constructor Details

    • AmqpMessageChannelSpec

      protected AmqpMessageChannelSpec​(org.springframework.amqp.rabbit.connection.ConnectionFactory connectionFactory)
  • Method Details

    • maxSubscribers

      public S maxSubscribers​(int maxSubscribers)
      Parameters:
      maxSubscribers - the maxSubscribers.
      Returns:
      the spec.
      See Also:
      AbstractSubscribableAmqpChannel.setMaxSubscribers(int)
    • acknowledgeMode

      public S acknowledgeMode​(org.springframework.amqp.core.AcknowledgeMode acknowledgeMode)
      Parameters:
      acknowledgeMode - the acknowledgeMode.
      Returns:
      the spec.
      See Also:
      AbstractMessageListenerContainer.setAcknowledgeMode(AcknowledgeMode)
    • advice

      public S advice​(org.aopalliance.aop.Advice... advice)
      Parameters:
      advice - the advice.
      Returns:
      the spec.
      See Also:
      AbstractMessageListenerContainer.setAdviceChain(Advice[])
    • autoStartup

      public S autoStartup​(boolean autoStartup)
      Parameters:
      autoStartup - the autoStartup.
      Returns:
      the spec.
      See Also:
      SmartLifecycle
    • concurrentConsumers

      public S concurrentConsumers​(int concurrentConsumers)
      Parameters:
      concurrentConsumers - the concurrentConsumers
      Returns:
      the spec.
      See Also:
      SimpleMessageListenerContainer.setConcurrentConsumers(int)
    • errorHandler

      public S errorHandler​(org.springframework.util.ErrorHandler errorHandler)
      Parameters:
      errorHandler - the errorHandler.
      Returns:
      the spec.
      See Also:
      AbstractMessageListenerContainer.setErrorHandler(ErrorHandler)
    • exposeListenerChannel

      public S exposeListenerChannel​(boolean exposeListenerChannel)
      Parameters:
      exposeListenerChannel - the exposeListenerChannel.
      Returns:
      the spec.
      See Also:
      AbstractMessageListenerContainer.setExposeListenerChannel(boolean)
    • phase

      public S phase​(int phase)
      Parameters:
      phase - the phase.
      Returns:
      the spec.
      See Also:
      SmartLifecycle
    • prefetchCount

      public S prefetchCount​(int prefetchCount)
      Parameters:
      prefetchCount - the prefetchCount.
      Returns:
      the spec.
      See Also:
      AbstractMessageListenerContainer.setPrefetchCount(int)
    • receiveTimeout

      public S receiveTimeout​(long receiveTimeout)
      Parameters:
      receiveTimeout - the receiveTimeout
      Returns:
      the spec.
      See Also:
      SimpleMessageListenerContainer.setReceiveTimeout(long)
    • recoveryInterval

      public S recoveryInterval​(long recoveryInterval)
      Parameters:
      recoveryInterval - the recoveryInterval
      Returns:
      the spec.
      See Also:
      AbstractMessageListenerContainer.setRecoveryInterval(long)
    • shutdownTimeout

      public S shutdownTimeout​(long shutdownTimeout)
      Parameters:
      shutdownTimeout - the shutdownTimeout.
      Returns:
      the spec.
      See Also:
      AbstractMessageListenerContainer.setShutdownTimeout(long)
    • taskExecutor

      public S taskExecutor​(java.util.concurrent.Executor taskExecutor)
      Configure an Executor used to invoke the message listener.
      Parameters:
      taskExecutor - the taskExecutor.
      Returns:
      the spec.
    • transactionAttribute

      public S transactionAttribute​(org.springframework.transaction.interceptor.TransactionAttribute transactionAttribute)
      Configure a TransactionAttribute to be used with the transactionManager(PlatformTransactionManager).
      Parameters:
      transactionAttribute - the transactionAttribute.
      Returns:
      the spec.
    • transactionManager

      public S transactionManager​(org.springframework.transaction.PlatformTransactionManager transactionManager)
      Configure a PlatformTransactionManager; used to synchronize the rabbit transaction with some other transaction(s).
      Parameters:
      transactionManager - the transactionManager.
      Returns:
      the spec.
    • batchSize

      public S batchSize​(int batchSize)
      Configure the batch size.
      Parameters:
      batchSize - the batchSize.
      Returns:
      the spec.
      Since:
      5.2
      See Also:
      SimpleMessageListenerContainer.setBatchSize(int)
    • doGet

      protected T doGet()
      Overrides:
      doGet in class AmqpPollableMessageChannelSpec<S extends AmqpMessageChannelSpec<S,​T>,​T extends AbstractAmqpChannel>