Skip to content

Commit

Permalink
rereplicationEntryBatchSize should be smaller than `maxPendingReadR… (
Browse files Browse the repository at this point in the history
  • Loading branch information
zymap authored and sijie committed May 23, 2019
1 parent 4f9eecc commit f824410
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion conf/bookkeeper.conf
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@ maxPendingAddRequestsPerThread=10000
auditorPeriodicBookieCheckInterval=86400

# The number of entries that a replication will rereplicate in parallel.
rereplicationEntryBatchSize=5000
rereplicationEntryBatchSize=100

# Auto-replication
# The grace period, in seconds, that the replication worker waits before fencing and
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,11 @@ private static ServerConfiguration readBookieConfFile(String bookieConfigFile) t
log.error("Malformed configuration file: {}", bookieConfigFile, e);
throw new IllegalArgumentException("Malformed configuration file");
}

if (bookieConf.getMaxPendingReadRequestPerThread() < bookieConf.getRereplicationEntryBatchSize()) {
throw new IllegalArgumentException(
"rereplicationEntryBatchSize should be smaller than " + "maxPendingReadRequestPerThread");
}
return bookieConf;
}

Expand Down

0 comments on commit f824410

Please sign in to comment.