Skip to content

Conversation

@Kami
Copy link
Member

@Kami Kami commented Jan 22, 2019

This pull request includes two improvements to our RabbitMQ connection retry code:

  1. Fix the code so we don't try to re-establish a connection for indefinitely in a place where we are calling connection.ensure_connection. Previously we didn't pass max_retries argument to that method so the connection was tried to be re-established for indefinitely and we didn't log any error.
  2. Log an error which is received when failing to re-establish a connection on each retry attempt. This is intentionally logged as DEBUG because it's only fatal if we exhaust all the retry attempts and still fail to re-establish a connection (in that case we re-throw the exception and issue is considered as fatal).

This should help and give more insight in #4508 (it's likely that RabbitMQ server is not running there or similar).

indefinetly if connection to RabbitMQ cannot be established.

Also add errback which logs an actual error when trying to re-establish
a connection.
@Kami Kami requested a review from bigmstone January 22, 2019 12:49
Copy link
Contributor

@bigmstone bigmstone left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@Kami Kami merged commit a588698 into master Jan 22, 2019
@Kami Kami deleted the update_rabbitmq_connection_retry_code branch January 22, 2019 17:43
@Kami Kami modified the milestones: 3.0.0, 2.10.2 Jan 24, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants