Fix for Issue #1684 Changes in handleTimeoutCausedException in Timeou… #2220
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
…tExceptionHandlingStage
Description
Some of the Retry attempts which failed due to the API TimeOuts did not successfully retried but ended up with AbortedException.
Motivation and Context
Refer Issue 1684
Root Cause
-Occurs in below scenario
Fix Options
Do changes in ApiCallTimeoutTrackingStage's handleInterruptedException() not to clear the interrupt .
Cons :- However this fix doesnot looks feasible since as per ApiCallTimeoutTrackingStage it rightly resets the Interrupt of the current Thread as part of had handleInterruptedException
translatePipelineException of TimeoutExceptionHandlingStage should check (e.getCause instance of AbortedException)
Cons :- We are getting too specifics to AbortedException and assuming that all the APIs fail with AbortedException whenever the request is aborted due to TimeOuts. So this looks we might miss some other exceptions or new exception added in future/
In translatePipelineException check if the isCausedByApiCallAttemptTimeout and its SdkClientException
Pros : This handles all the cases also in handleTimeoutCausedException we have if clauses which does the filtering.
Cons : not aware.
Testing
Screenshots (if appropriate)
Types of changes
Checklist
mvn install
succeedsLicense