Announcement Announcement Module
Collapse
No announcement yet.
Reconnect on a dropped connection Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Reconnect on a dropped connection

    I understand from the documentation that a message listener container restarts on a dropped connection. But is there a property to keep the connection alive and if there is where do we set it (connection factory,listener container)
    Appreciate suggestions

    Thanks

  • #2
    The underlying RabbitClient connection factory has a 'requestedHeartbeat' property.

    This is not exposed in the spring-rabbit namespace, but you can declare a rabbit ConnectionFactory as a <bean/> and then provide it to the Spring connection factory ...

    Code:
    <rabbit:connection-factory id="cf" connection-factory="customizedRabbitCf"/>
    I suggest you read the RabbitMQ docs for more information about the heartbeats.

    Comment

    Working...
    X