Add retry support for removeObjects()/completeMultipartUpload() APIs#1704
Open
balamurugana wants to merge 1 commit into
Open
Conversation
0de4406 to
2124db9
Compare
rraulinio
reviewed
May 22, 2026
2124db9 to
b1f0244
Compare
There was a problem hiding this comment.
Pull request overview
This PR adds higher-level retry behavior for S3 operations where failures can be returned as HTTP 2xx responses (notably DeleteObjects / CompleteMultipartUpload), and exposes retry tuning knobs through new delayMs / maxRetries fields on several args types.
Changes:
- Add retry configuration (
delayMs,maxRetries) to multiple argument classes and propagate them into multipart completion / composition flows. - Implement retry loops for
MinioAsyncClient.removeObjects()(based on S3 error codes) andBaseS3Client.completeMultipartUpload()(on exceptional completion). - Improve HTTP trace behavior to avoid dumping raw request bodies in some cases, and refactor Admin client tracing to rely on
Http.StatusRetryInterceptor.
Reviewed changes
Copilot reviewed 9 out of 9 changed files in this pull request and generated 12 comments.
Show a summary per file
| File | Description |
|---|---|
| functional/TestMinioClient.java | Adjusts functional cleanup to surface MinioException during remove-objects iteration. |
| api/src/main/java/io/minio/RemoveObjectsArgs.java | Adds retry/backoff parameters for remove-objects operations. |
| api/src/main/java/io/minio/PutObjectBaseArgs.java | Adds retry/backoff parameters intended to propagate into multipart completion. |
| api/src/main/java/io/minio/MinioAsyncClient.java | Adds retry/backoff loop for removeObjects() based on retryable S3 error codes. |
| api/src/main/java/io/minio/Http.java | Avoids tracing raw bytes for some PUT/POST bodies by emitting a placeholder. |
| api/src/main/java/io/minio/ComposeObjectArgs.java | Adds retry/backoff parameters for compose flows. |
| api/src/main/java/io/minio/CompleteMultipartUploadArgs.java | Adds retry/backoff parameters and propagates them from compose/put args. |
| api/src/main/java/io/minio/BaseS3Client.java | Adds retryable S3 error code set and implements retry logic for complete multipart upload. |
| adminapi/src/main/java/io/minio/admin/MinioAdminClient.java | Refactors tracing and adds retry configuration support via interceptor replacement. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
As S3 error response of DeleteObjects and CompleteMultipartUpload S3 APIs is returned with HTTP status code 2xx, MinIO Client retries at high level by S3 error codes `InternalError`, `RequestTimeout`, `ServiceUnavailable` and `SlowDown`. Signed-off-by: Bala.FA <bala@minio.io>
b1f0244 to
629ec18
Compare
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.
As S3 error response of DeleteObjects and CompleteMultipartUpload S3 APIs is returned with HTTP status code 2xx, MinIO Client retries at high level by S3 error codes
InternalError,RequestTimeout,ServiceUnavailableandSlowDown.