You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@bookkeeper.apache.org by GitBox <gi...@apache.org> on 2022/06/17 07:07:36 UTC

[GitHub] [bookkeeper] StevenLuMT commented on a diff in pull request #3342: Bookie cache optimization

StevenLuMT commented on code in PR #3342:
URL: https://github.com/apache/bookkeeper/pull/3342#discussion_r899826615


##########
bookkeeper-server/src/main/java/org/apache/bookkeeper/bookie/storage/ldb/SingleDirectoryDbLedgerStorage.java:
##########
@@ -161,7 +164,7 @@ public SingleDirectoryDbLedgerStorage(ServerConfiguration conf, LedgerManager le
         this.writeCacheMaxSize = writeCacheSize;
         this.writeCache = new WriteCache(allocator, writeCacheMaxSize / 2);
         this.writeCacheBeingFlushed = new WriteCache(allocator, writeCacheMaxSize / 2);
-
+        this.writeCacheLastFlushed = new WriteCache(allocator, writeCacheMaxSize / 2);

Review Comment:
   @merlimat 
   writeCacheBeingFlushe and writeCacheLastFlushed almost  only one of the two exists at the same time
   so I think this just 100% memory for the write cache.
   <img width="1420" alt="image" src="https://user-images.githubusercontent.com/42990025/174243987-33261c58-0289-47f3-af5d-c7b0768228b3.png">
   



-- 
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: issues-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org