Class DefaultChannelListener

java.lang.Object
net.jodah.lyra.event.DefaultChannelListener
All Implemented Interfaces:
ChannelListener

public abstract class DefaultChannelListener
extends java.lang.Object
implements ChannelListener
No-op channel listener for sub-classing.
  • Constructor Summary

    Constructors 
    Constructor Description
    DefaultChannelListener()  
  • Method Summary

    Modifier and Type Method Description
    void onCreate​(com.rabbitmq.client.Channel channel)
    Called when the channel is successfully created.
    void onCreateFailure​(java.lang.Throwable failure)
    Called when channel creation fails.
    void onRecovery​(com.rabbitmq.client.Channel channel)
    Called when the channel is successfully recovered from an unexpected closure but before its consumers and their associated queues, exchanges, and bindings are recovered.
    void onRecoveryCompleted​(com.rabbitmq.client.Channel channel)
    Called when recovery of the channel and its consumers is completed.
    void onRecoveryFailure​(com.rabbitmq.client.Channel channel, java.lang.Throwable failure)
    Called when the channel fails to recover from an unexpected closure.
    void onRecoveryStarted​(com.rabbitmq.client.Channel channel)
    Called when recovery of the channel is started.

    Methods inherited from class java.lang.Object

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

  • Method Details

    • onCreate

      public void onCreate​(com.rabbitmq.client.Channel channel)
      Description copied from interface: ChannelListener
      Called when the channel is successfully created.
      Specified by:
      onCreate in interface ChannelListener
    • onCreateFailure

      public void onCreateFailure​(java.lang.Throwable failure)
      Description copied from interface: ChannelListener
      Called when channel creation fails.
      Specified by:
      onCreateFailure in interface ChannelListener
    • onRecovery

      public void onRecovery​(com.rabbitmq.client.Channel channel)
      Description copied from interface: ChannelListener
      Called when the channel is successfully recovered from an unexpected closure but before its consumers and their associated queues, exchanges, and bindings are recovered. This is useful for performing any pre-consumer setup that is required such as declaring exchanges and queues, and creating queue to exchange bindings.
      Specified by:
      onRecovery in interface ChannelListener
    • onRecoveryCompleted

      public void onRecoveryCompleted​(com.rabbitmq.client.Channel channel)
      Description copied from interface: ChannelListener
      Called when recovery of the channel and its consumers is completed. Note: The success or failure of an individual consumer's recovery can be tracked with a ConsumerListener.
      Specified by:
      onRecoveryCompleted in interface ChannelListener
    • onRecoveryFailure

      public void onRecoveryFailure​(com.rabbitmq.client.Channel channel, java.lang.Throwable failure)
      Description copied from interface: ChannelListener
      Called when the channel fails to recover from an unexpected closure.
      Specified by:
      onRecoveryFailure in interface ChannelListener
    • onRecoveryStarted

      public void onRecoveryStarted​(com.rabbitmq.client.Channel channel)
      Description copied from interface: ChannelListener
      Called when recovery of the channel is started.
      Specified by:
      onRecoveryStarted in interface ChannelListener