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

Implement retry logic in the econnect-python Client #152

Open
palazzem opened this issue May 16, 2024 · 0 comments
Open

Implement retry logic in the econnect-python Client #152

palazzem opened this issue May 16, 2024 · 0 comments

Comments

@palazzem
Copy link
Owner

Is your feature request related to a problem? Please describe.
Integrations using the econnect-python library currently need to implement their own retry logic for handling temporary errors such as token expiration. This results in duplicated code and inconsistent retry mechanisms across different integrations. It also increases the complexity of the client code.

Describe the solution you'd like
Incorporate a retry mechanism within the econnect-python library itself. The retry logic should handle temporary errors, such as InvalidToken exceptions, by attempting to re-authenticate and retry the operation. The retry mechanism should be configurable to allow customization of retry conditions and limits.

Describe alternatives you've considered

  • Leaving the retry logic to the client applications, leading to duplicated code and inconsistent retry strategies.
  • Using third-party libraries such as Tenacity, which would introduce an additional dependency and potential overhead.

Additional context
n/a

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

No branches or pull requests

1 participant