Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tweaks to recovery retry #403

Merged
merged 2 commits into from
Aug 29, 2018
Merged

tweaks to recovery retry #403

merged 2 commits into from
Aug 29, 2018

Conversation

vikinghawk
Copy link
Contributor

@vikinghawk vikinghawk commented Aug 28, 2018

Proposed Changes

Changed the helper method to return the builder instead of the built RetryHandler so it is easy to add your own backoff impl and chagne retry attempts. Also a tweak to the logging so it logs each retry loop and how many attempts are remaining.

Types of Changes

What types of changes does your code introduce to this project?
Put an x in the boxes that apply

  • Bugfix (non-breaking change which fixes issue #NNNN)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation (correction or otherwise)
  • Cosmetics (whitespace, appearance)

Checklist

Put an x in the boxes that apply. You can also fill these out after creating
the PR. If you're unsure about any of them, don't hesitate to ask on the
mailing list. We're here to help! This is simply a reminder of what we are
going to look for before merging your code.

  • I have read the CONTRIBUTING.md document
  • I have signed the CA (see https://cla.pivotal.io/sign/rabbitmq)
  • All tests pass locally with my changes
  • I have added tests that prove my fix is effective or that my feature works
  • I have added necessary documentation (if appropriate)
  • Any dependent changes have been merged and published in related repositories

Further Comments

If this is a relatively large or complex change, kick off the discussion by
explaining why you chose the solution you did and what alternatives you
considered, etc.

@@ -122,11 +122,11 @@ protected RetryResult doRetry(BiPredicate<RecordedEntity, Exception> condition,
throw exception;
}
}
throw context.exception();
throw exception;
Copy link
Contributor Author

@vikinghawk vikinghawk Aug 28, 2018

Choose a reason for hiding this comment

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

assuming we want the last exception thrown here rather than the 1st since the others should have been logged already? If not i can change it back.

Copy link
Contributor

Choose a reason for hiding this comment

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

Makes sense.

@vikinghawk vikinghawk changed the title tweaks to recovery retry helper tweaks to recovery retry Aug 28, 2018
@@ -122,11 +122,11 @@ protected RetryResult doRetry(BiPredicate<RecordedEntity, Exception> condition,
throw exception;
}
}
throw context.exception();
throw exception;
Copy link
Contributor

Choose a reason for hiding this comment

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

Makes sense.

@acogoluegnes acogoluegnes merged commit b24a9be into rabbitmq:5.x.x-stable Aug 29, 2018
@acogoluegnes
Copy link
Contributor

Thanks! Changes are minor but I'll release a RC for both 5.x and 4.x today.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants