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

Flexible Auto-Retries for any kind of error responses (4xx, 5xx) #121

Open
otsch opened this issue Sep 28, 2023 · 2 comments
Open

Flexible Auto-Retries for any kind of error responses (4xx, 5xx) #121

otsch opened this issue Sep 28, 2023 · 2 comments

Comments

@otsch
Copy link
Member

otsch commented Sep 28, 2023

As discussed in #99 (comment) it would be nice to be able to use the RetryErrorResponseHandler differently. In a way that you're able to configure auto retries for any kind of error response.
Not yet sure about the wait times implemented in the RetryErrorResponseHandler. They should probably only be used for the special error responses (429, 503).
@ruerdev

@ruerdev
Copy link

ruerdev commented Sep 29, 2023

@otsch Good to know about the RetryErrorResponseHandler, I didn't know that. I think it will be very useful when we have more flexibility in how error responses are handled.

It might be a good idea to let users pick a shorter wait time when they get a 429 error while using proxies. As you will switch to a different IP for their next request.

@otsch
Copy link
Member Author

otsch commented Sep 29, 2023

It might be a good idea to let users pick a shorter wait time when they get a 429 error

You can already customize the wait times, see https://www.crwlr.software/packages/crawler/v1.1/the-crawler/politeness#wait-and-retry
I'll think about maybe automatically setting lower default wait times for those two error responses, when calling the new HttpLoader::useRotatingProxies() method 👍🏻

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

No branches or pull requests

2 participants