[ https://issues.apache.org/jira/browse/HBASE-16164?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15360594#comment-15360594 ]
Anoop Sam John commented on HBASE-16164: ---------------------------------------- You mean finally block with a boolean indicating whether the compaction completed and swap happend and based on that do close of result? Its fine with cur way of if else IMHO. We don't expect any exception in this path right? I think Ram pinged over in HBASE-14921 or the parent issue days back. We are in process of testing our off heap write path PoC code with this new memstore. We believe that this may help with off heaping.. Till now we are not able to test that with PE because new memstore not able to stand high write load. PE tool we are trying to run with a cluster of 1 RS with 50 regions. 32 GB heap space. PE having 50 threads writing rows. FYI Sorry that the fixes made u to refresh the patch. Once that is posted in HBASE-14921, we will help you with reviews and get that in soon. Thanks for you work. > Missing close of new compacted segments in few occasions which might leak > MSLAB chunks from pool > ------------------------------------------------------------------------------------------------ > > Key: HBASE-16164 > URL: https://issues.apache.org/jira/browse/HBASE-16164 > Project: HBase > Issue Type: Sub-task > Affects Versions: 2.0.0 > Reporter: Anoop Sam John > Assignee: Anoop Sam John > Priority: Critical > Fix For: 2.0.0 > > Attachments: HBASE-16164.patch > > > An in memory compaction of N segments in progress. Inn between snapshot() > call comes. We will stop the in progress compaction then. This just sets an > AtomicBoolean. We check this boolean state in the compaction loop (while > loop reading the cells from the segments) and before swapping the segments. > But if this scenario comes, we are just ignoring the new newly compacted > Segment. This is a problem maker when we work with MSLAB pool. The new > segment would have acquired some chunks but when will they get released? As > we dont close the segment this will leak them. > Also in swap we have > {code} > public boolean swap(VersionedSegmentsList versionedList, ImmutableSegment > segment) { > if(versionedList.getVersion() != version) { > return false; > } > LinkedList<ImmutableSegment> suffix; > synchronized (pipeline){ > if(versionedList.getVersion() != version) { > return false; > } > {code} > I dont see any possibility for this code flow to happen. Still for > correctness, we should close the segment here too. -- This message was sent by Atlassian JIRA (v6.3.4#6332)