Repository navigation
backend: implement retry with exponential backoff for Soroban RPC (#959) - #1093
Merged
ONEONUORA merged 1 commit intoSep 27, 2026
Merged
Conversation
…acverse#959) Add RpcErrorKind enum and classify_rpc_error() to distinguish HTTP 503 (ServiceUnavailable) and timeout errors from permanent failures. Add send_rpc_request_with_retry() with up to 3 total attempts and delays of 1s, 2s, 4s between retries. Non-retryable errors (4xx, unknown) abort immediately without sleeping. Wire submit_transaction() through send_rpc_request_with_retry so all Soroban transaction submissions benefit from the backoff policy. Add retry_tests module (8 tests): 503 -> ServiceUnavailable, 500/429 -> OtherRetryable, 400/404 -> Permanent, backoff schedule 1s/2s/4s, MAX_RETRY_ATTEMPTS == 3, non-retryable abort, integration smoke-test. Closes Fracverse#959
|
@AnnieIj Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits. You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀 |
ONEONUORA
approved these changes
Sep 27, 2026
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
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.
Description
This PR improves the reliability of Soroban transaction submissions by introducing automatic retry handling for temporary RPC failures.
Changes Made
backend/src/services/stellar.rs.Expected Outcome
Temporary network interruptions no longer cause immediate transaction submission failure. The backend retries eligible requests with increasing delays while preventing unlimited retry attempts.
Testing
Closes #959