generated from amazon-archives/__template_Apache-2.0
-
Notifications
You must be signed in to change notification settings - Fork 83
feat(amazonq): adding classification based retry strategy for chat #2409
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
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…2234) * feat(amazonq): adding classification based retry strategy for chat requests * fix(amazonq): added abortController back * fix: fix to add aws retry strategy * revert: revert package-lock.json changes from commit 22358a3 * fix: remove completed TODO for chat result stream integration The delay notification integration with chat result stream is already implemented via the setDelayNotificationCallback mechanism in the AgenticChatController. Removed the TODO comment as the functionality is complete. * refactor: extract retry attempts to constant Replace hardcoded retry attempts value (3) with DEFAULT_RETRY_ATTEMPTS constant to improve maintainability and follow best practices. * fix: refatcor hardcoded values for retry * fix: fix to add custom AWS retry startegy wrapper * fix: fix for unit test failures * fix: fix to move sanitizeLogInput to utils * fix(amazonq): fix to move to adaptiveRetryStrategy * fix: fix for compilation errors * revert: revert for package-lock * fix(amazonq): fix for retry classification * fix: fix for test failures * fix: fix to cover more non-retryable exceptions * fix: fix for nits to use constants --------- Co-authored-by: Laxman Reddy <[email protected]>
chungjac
approved these changes
Oct 8, 2025
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #2409 +/- ##
==========================================
+ Coverage 61.87% 62.25% +0.38%
==========================================
Files 261 266 +5
Lines 58505 59090 +585
Branches 3672 3786 +114
==========================================
+ Hits 36199 36788 +589
+ Misses 22235 22227 -8
- Partials 71 75 +4
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
rli
approved these changes
Oct 8, 2025
laileni-aws
approved these changes
Oct 8, 2025
manodnyab
approved these changes
Oct 8, 2025
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Copy of #2234 for main branch
Problem
Current chat request strategy is insufficient and we need to be in parity with Q CLI's unified approach.
Solution
Implements a simplified AWS retry strategy for agentic chat operations that matches AWS CLI behavior with exponential backoff and proper error handling.
Changes Made
AwsRetryStrategyclass with AWS SDK-compatible retry logicKey Features
Error Types Handled
Testing
License
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.