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

[GitHub] Add RetryInterceptor #53

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

Conversation

joshuawright11
Copy link
Owner

@joshuawright11 joshuawright11 commented Apr 29, 2024

Implements a retry interceptor for handling failed requests in the Papyrus library. This addition allows requests to be retried based on configurable conditions, enhancing the robustness of network communication.

  • Introduces RetryInterceptor class: Adds a new class that implements the Interceptor protocol, enabling retry logic for failed requests. This class allows configuration of retry conditions, maximum retry count, and retry delay.
  • Updates Provider to support retry interceptor: Modifies the Provider class to accept an optional RetryInterceptor instance. This change integrates the retry mechanism into the request flow, allowing failed requests to be retried according to the specified conditions.
  • Enhances unit tests: Extends ProviderTests with a new test case that verifies the functionality of the retry interceptor. This test ensures that requests failing with a specified status code are retried as expected.
  • Documents retry interceptor usage: Updates the README.md file with instructions on configuring and using the retry interceptor. This documentation provides users with the necessary information to leverage the new feature.

For more details, open the Copilot Workspace session.

@joshuawright11 joshuawright11 changed the title [GitHub] Add retry interceptor [GitHub] Add RetryInterceptor Apr 29, 2024
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.

1 participant