-
Notifications
You must be signed in to change notification settings - Fork 533
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
Support more errors for retries #300
Comments
This is not quite correct. Any 5XX status code will result in a retry. The Throughput and Throttling errors also permit retrying for 4XX errors. However, that chunk of the code could definitely receive some refactoring. Really this ought to be handled at an operation or service level because it's a bit odd to have custom logic for basically just DynamoDB there and not in a module more oriented towards DynamoDB support. That said, I don't see why I would want to retry on a S3 GET. If an item is not there, there's no reason to expect that there will be in the next 15 or so seconds that you get out of a retry. A particular application might have that expectation, but if so that's the responsibility of the application to handle. |
Hopefully this is the right issue to add my comment too. I've just started using ex_aws in conjunction with arc, So it might be an arc issue. I am trying to save an object to S3 and am getting an unmatched case within the ex_aws code. It looks like it does not handle any 3** response code. In my opinion it should automatically retry at the new location. This is the offending case clause https://github.com/CargoSense/ex_aws/blob/master/lib/ex_aws/request.ex#L34 and my error
|
This is unrelated, it generally is an indicator that you tried to access a bucket in a region other than the one configured. |
I've hit the same redirect issue above and have raised it as a separate issue #359 |
SQS returns throttling errors in this format: |
In lib/ex_aws/request.ex, a retry is only attempted when we get ProvisionedThroughputExceededException or ThrottlingException. However, in some cases it would be nice to be able to do that for other types of errors (like NotFound for S3 GET).
I would be convenient if config allowed to specify a list a combinations of http methods and error types we want to attempt retries for.
The text was updated successfully, but these errors were encountered: