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

ExecutionInterceptor access to request attempt exceptions #929

Open
devinsba opened this issue Dec 6, 2018 · 3 comments
Open

ExecutionInterceptor access to request attempt exceptions #929

devinsba opened this issue Dec 6, 2018 · 3 comments
Labels
feature-request A feature should be added or improved. p3 This is a minor priority issue

Comments

@devinsba
Copy link

devinsba commented Dec 6, 2018

Maybe this is just a documentation change that is needed but reading through the ExecutionInterceptor comments and traversing through the code I don't see a way to get access to the intermediate exceptions that get retried.

Expected Behavior

ExecutionInterceptor should have a hook like onRequestFailure that would give access to the exception for a specific HTTP request. This would provide the ability to see throttles and other types of events at the request level when it may resolve during the retries.

Current Behavior

The current behavior as I understand it is to add some internal state to the retry handler but to only emit that once the retries have been exhausted.

Possible Solution

Add a new Stage for RequestFailure that the RetryableStage can delegate to for these hooks

Context

When we instrumented the V1 SDK we had the ability to retrieve the intermediate exceptions. With V2 that is not possible at the moment. See openzipkin/zipkin-aws#116 for the corresponding issue on our end.

@shorea
Copy link
Contributor

shorea commented Dec 7, 2018

I don't believe we have a hook for each individual exception. This sounds like a good idea though. Quick question, for the final exception would you expect it to call this per exception hook in addition to the onExecutionFailure method?

@devinsba
Copy link
Author

devinsba commented Dec 7, 2018

I think it would yes. Maybe the exception would state whether the request will be retried, so that we could detect the last request if needed. I don't think it matters to our use case though so just having a hook for the individual http request and exception is enough

@justnance justnance added feature-request A feature should be added or improved. and removed Feature Request labels Apr 19, 2019
@millems millems changed the title ExecutionInterceptor access to Exceptions that are retried ExecutionInterceptor access to request attempt exceptions Jul 8, 2019
aws-sdk-java-automation added a commit that referenced this issue Aug 13, 2020
…01a4c383

Pull request: release <- staging/0c7c8a02-8615-4fc9-99a4-4cf601a4c383
@yasminetalby yasminetalby added the p3 This is a minor priority issue label Nov 14, 2022
@davidvanlaatum
Copy link

is this still not done? I was getting the exception details with retryCondition and adding them to the executionattributes but this has just been marked deprecated so are we back to no way to get the exceptions?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature-request A feature should be added or improved. p3 This is a minor priority issue
Projects
None yet
Development

No branches or pull requests

5 participants