hangc0276 commented on code in PR #4015:
URL: https://github.com/apache/bookkeeper/pull/4015#discussion_r1264989909
##########
bookkeeper-server/src/main/java/org/apache/bookkeeper/bookie/storage/ldb/SingleDirectoryDbLedgerStorage.java:
##########
@@ -1147,21 +1151,28 @@ private LedgerDirsManager.LedgerDirsListener
getLedgerDirsListener() {
@Override
public void diskAlmostFull(File disk) {
- if (gcThread.isForceGCAllowWhenNoSpace()) {
- gcThread.enableForceGC();
- } else {
- gcThread.suspendMajorGC();
+ if (ledgerDirsManager.getAllLedgerDirs().contains(disk)
+ || indexDirsManager.getAllLedgerDirs().contains(disk))
{
Review Comment:
We'd better not take indexDirs into consideration. If the index dir shares
the same disk with the ledger dir, the LedgerDirsManager can cover the event.
If the index dir uses different disks with ledger dir, it doesn't make sense to
suspend ledger disk garbage collection.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]