-
Notifications
You must be signed in to change notification settings - Fork 892
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
Ledger replicate supports throttle #2778
Conversation
below is the throttle results. with @eolivelli @hangc0276 PTAL |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall I support this patch.
I wonder if it is possible to not add new constructors and pass ServerConfiguration down to the various components.
bookkeeper-server/src/main/java/org/apache/bookkeeper/client/BookKeeperAdmin.java
Outdated
Show resolved
Hide resolved
@eolivelli PTAL, thanks |
8c3ae00
to
60305e2
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great work!
bookkeeper-server/src/main/java/org/apache/bookkeeper/client/LedgerFragmentReplicator.java
Show resolved
Hide resolved
bookkeeper-server/src/main/java/org/apache/bookkeeper/client/BookKeeperAdmin.java
Outdated
Show resolved
Hide resolved
@gaozhangmin You'd better use one parameter to control read and write throttle by bytes, which will simplify the configuration for users. |
bookkeeper-server/src/main/java/org/apache/bookkeeper/client/LedgerFragmentReplicator.java
Show resolved
Hide resolved
@gaozhangmin You can just use read throttle by bytes to control replication, maybe no need write throttle. |
463bc15
to
3a16ee7
Compare
@hangc0276 @eolivelli @zymap PTAL again |
22344cb
to
5cb41d2
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
bookkeeper-server/src/main/java/org/apache/bookkeeper/replication/Auditor.java
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall looks good to me. Left some minor comments.
...er-server/src/main/java/org/apache/bookkeeper/tools/cli/commands/bookies/RecoverCommand.java
Outdated
Show resolved
Hide resolved
...er-server/src/main/java/org/apache/bookkeeper/tools/cli/commands/bookies/RecoverCommand.java
Outdated
Show resolved
Hide resolved
bookkeeper-server/src/main/java/org/apache/bookkeeper/client/LedgerFragmentReplicator.java
Outdated
Show resolved
Hide resolved
bookkeeper-server/src/main/java/org/apache/bookkeeper/client/LedgerFragmentReplicator.java
Outdated
Show resolved
Hide resolved
bookkeeper-server/src/main/java/org/apache/bookkeeper/bookie/BookieShell.java
Outdated
Show resolved
Hide resolved
bookkeeper-server/src/main/java/org/apache/bookkeeper/client/BookKeeperAdmin.java
Show resolved
Hide resolved
bookkeeper-server/src/main/java/org/apache/bookkeeper/client/LedgerFragmentReplicator.java
Outdated
Show resolved
Hide resolved
bookkeeper-server/src/main/java/org/apache/bookkeeper/conf/ClientConfiguration.java
Outdated
Show resolved
Hide resolved
bookkeeper-server/src/main/java/org/apache/bookkeeper/client/LedgerFragmentReplicator.java
Outdated
Show resolved
Hide resolved
bookkeeper-server/src/main/java/org/apache/bookkeeper/client/LedgerFragmentReplicator.java
Show resolved
Hide resolved
bookkeeper-server/src/main/java/org/apache/bookkeeper/client/LedgerFragmentReplicator.java
Outdated
Show resolved
Hide resolved
bookkeeper-server/src/main/java/org/apache/bookkeeper/conf/ClientConfiguration.java
Outdated
Show resolved
Hide resolved
bookkeeper-server/src/main/java/org/apache/bookkeeper/conf/ClientConfiguration.java
Outdated
Show resolved
Hide resolved
bookkeeper-server/src/main/java/org/apache/bookkeeper/conf/ServerConfiguration.java
Show resolved
Hide resolved
bf35f4e
to
8b71985
Compare
@hangc0276 @zymap @nicoloboschi PTAL again, Thx. |
8b71985
to
27c38a9
Compare
bookkeeper-server/src/main/java/org/apache/bookkeeper/client/LedgerFragmentReplicator.java
Outdated
Show resolved
Hide resolved
bookkeeper-server/src/main/java/org/apache/bookkeeper/client/LedgerFragmentReplicator.java
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great job!
rerun-failure-tests |
rerun failure checks |
@gaozhangmin Could you please take a look at the conflicts? I want to merge this PR |
ba807aa
to
4d1f82d
Compare
done. |
Descriptions of the changes in this PR: ### Motivation improve the throttle function : old pr: #2778 1. duplicate definition for replicationRateByBytes 2.make sure this update safety when different callback run averageEntrySize updating ### Changes 1.clean code for duplicate definition for replicationRateByBytes 2.add a lock to make sure data safety for updateAverageEntrySize
Ledger replicating puts heavy loads on cluster. Now, ledger replicate only supports split fragments into small pieces. But, throttling is not supported. Add a confiuration `replicationRateByBytes ` support throttling read rate in bytes. Also bookkeeper shell recover command supports throttle. (cherry picked from commit a2d7341)
### Motivation Ledger replicating puts heavy loads on cluster. Now, ledger replicate only supports split fragments into small pieces. But, throttling is not supported. ### Changes Add a confiuration `replicationRateByBytes ` support throttling read rate in bytes. Also bookkeeper shell recover command supports throttle. (cherry picked from commit a2d7341)
Descriptions of the changes in this PR: improve the throttle function : old pr: apache#2778 1. duplicate definition for replicationRateByBytes 2.make sure this update safety when different callback run averageEntrySize updating 1.clean code for duplicate definition for replicationRateByBytes 2.add a lock to make sure data safety for updateAverageEntrySize (cherry picked from commit 7f31748)
### Motivation Ledger replicating puts heavy loads on cluster. Now, ledger replicate only supports split fragments into small pieces. But, throttling is not supported. ### Changes Add a confiuration `replicationRateByBytes ` support throttling read rate in bytes. Also bookkeeper shell recover command supports throttle. (cherry picked from commit a2d7341)
Descriptions of the changes in this PR: improve the throttle function : old pr: apache#2778 1. duplicate definition for replicationRateByBytes 2.make sure this update safety when different callback run averageEntrySize updating 1.clean code for duplicate definition for replicationRateByBytes 2.add a lock to make sure data safety for updateAverageEntrySize (cherry picked from commit 7f31748)
### Motivation Ledger replicating puts heavy loads on cluster. Now, ledger replicate only supports split fragments into small pieces. But, throttling is not supported. ### Changes Add a confiuration `replicationRateByBytes ` support throttling read rate in bytes. Also bookkeeper shell recover command supports throttle. (cherry picked from commit a2d7341) (cherry picked from commit 7267058)
Descriptions of the changes in this PR: improve the throttle function : old pr: apache#2778 1. duplicate definition for replicationRateByBytes 2.make sure this update safety when different callback run averageEntrySize updating 1.clean code for duplicate definition for replicationRateByBytes 2.add a lock to make sure data safety for updateAverageEntrySize (cherry picked from commit 7f31748) (cherry picked from commit a13dfce)
Motivation
Ledger replicating puts heavy loads on cluster.
Now, ledger replicate only supports split fragments into small pieces.
But, throttling is not supported.
Changes
Add a confiuration
replicationRateByBytes
support throttling read rate in bytes.
Also bookkeeper shell recover command supports throttle.