You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@bookkeeper.apache.org by eo...@apache.org on 2023/03/16 10:56:41 UTC
[bookkeeper] branch master updated: Change order of doGcLedgers and extractMetaFromEntryLogs (#3869)
This is an automated email from the ASF dual-hosted git repository.
eolivelli pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/bookkeeper.git
The following commit(s) were added to refs/heads/master by this push:
new a633ec4bd8 Change order of doGcLedgers and extractMetaFromEntryLogs (#3869)
a633ec4bd8 is described below
commit a633ec4bd8d69dc991148099ce4dbb6fc802ca88
Author: Andrey Yegorov <86...@users.noreply.github.com>
AuthorDate: Thu Mar 16 03:56:34 2023 -0700
Change order of doGcLedgers and extractMetaFromEntryLogs (#3869)
---
.../org/apache/bookkeeper/bookie/GarbageCollectorThread.java | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/bookkeeper-server/src/main/java/org/apache/bookkeeper/bookie/GarbageCollectorThread.java b/bookkeeper-server/src/main/java/org/apache/bookkeeper/bookie/GarbageCollectorThread.java
index 1420c5ca6f..bdffd689a5 100644
--- a/bookkeeper-server/src/main/java/org/apache/bookkeeper/bookie/GarbageCollectorThread.java
+++ b/bookkeeper-server/src/main/java/org/apache/bookkeeper/bookie/GarbageCollectorThread.java
@@ -410,13 +410,14 @@ public class GarbageCollectorThread implements Runnable {
compactor.cleanUpAndRecover();
try {
- // Extract all of the ledger ID's that comprise all of the entry logs
- // (except for the current new one which is still being written to).
- extractMetaFromEntryLogs();
-
// gc inactive/deleted ledgers
+ // this is used in extractMetaFromEntryLogs to calculate the usage of entry log
doGcLedgers();
+ // Extract all of the ledger ID's that comprise all of the entry logs
+ // (except for the current new one which is still being written to).
+ extractMetaFromEntryLogs();
+
// gc entry logs
doGcEntryLogs();