----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/4481/#review6511 -----------------------------------------------------------
bookkeeper-server/src/main/java/org/apache/bookkeeper/meta/FlatLedgerManager.java <https://reviews.apache.org/r/4481/#comment14165> Casting indicates that something is wrong in your abstraction. Perhaps activeLedgers.snapshot() should return a SortedMap, and doGC() should take a Map. It doesn't do anything that requires the ConcurrentMap interface. bookkeeper-server/src/main/java/org/apache/bookkeeper/meta/HierarchicalLedgerManager.java <https://reviews.apache.org/r/4481/#comment14166> why not just have the implementation of SnapshotMap use a ConcurrentSkipListMap? - Ivan On 2012-03-29 05:27:14, Sijie Guo wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/4481/ > ----------------------------------------------------------- > > (Updated 2012-03-29 05:27:14) > > > Review request for bookkeeper. > > > Summary > ------- > > create a snapshot of bookie active ledgers, and then fetch the list of > zookeeper metadata, then it is safe to do garbage collection. > > > This addresses bug BOOKKEEPER-193. > https://issues.apache.org/jira/browse/BOOKKEEPER-193 > > > Diffs > ----- > > bookkeeper-server/src/main/java/org/apache/bookkeeper/meta/SnapshotMap.java > PRE-CREATION > > bookkeeper-server/src/main/java/org/apache/bookkeeper/meta/FlatLedgerManager.java > 100cdad > > bookkeeper-server/src/main/java/org/apache/bookkeeper/meta/HierarchicalLedgerManager.java > 169c906 > > bookkeeper-server/src/test/java/org/apache/bookkeeper/meta/GcLedgersTest.java > PRE-CREATION > > bookkeeper-server/src/test/java/org/apache/bookkeeper/meta/LedgerManagerTestCase.java > PRE-CREATION > > Diff: https://reviews.apache.org/r/4481/diff > > > Testing > ------- > > > Thanks, > > Sijie > >
