Skip to content

Conversation

@superhx
Copy link
Collaborator

@superhx superhx commented Dec 5, 2025

cherry-pick #3079

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR improves the performance of the commit operation in the zerozone feature by implementing a "smooth commit" strategy. The changes optimize commit behavior to reduce latency while maintaining data consistency.

Key changes:

  • Modified AsyncNetworkBandwidthLimiter to complete futures outside of locks, improving concurrency
  • Refactored S3Storage's LazyCommit to support separate completion futures for trim and commit operations
  • Enhanced PartitionSnapshotsManager to use delayed commits (1000ms) for non-initial requests, optimizing performance

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
AsyncNetworkBandwidthLimiter.java Moves CompletableFuture completion outside the lock to avoid holding locks during callback execution
S3Storage.java Splits LazyCommit's single CompletableFuture into separate trimCf and commitCf for better control over completion semantics
PartitionSnapshotsManager.java Implements differential commit behavior: immediate (0ms) for new sessions, delayed (1000ms) for subsequent requests to smooth commits

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@superhx superhx merged commit a28603c into main Dec 5, 2025
11 of 12 checks passed
@superhx superhx deleted the cp_3079 branch December 5, 2025 02:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants