[
https://issues.apache.org/jira/browse/HBASE-23968?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17101336#comment-17101336
]
Anoop Sam John commented on HBASE-23968:
----------------------------------------
Noticed this issue and PRs now only. So we have added time based check (at 10
secs interval by default) along with existing size based check (10 MB by
default). The CloseChecker will get called from the compaction threads right?
In compaction by default there is Pressure Aware Throughput Controller. This
can cause the compaction thread to go into sleep state. (I did not go in detail
to see the math there. How long we might sleep). But the point is this sleep
can cause the check to get delayed (?). When the RS stop is been requested
stopping these threads as early is important. Should we think other
possibilities for that also? Like making these threads Daemon? (Not really
suggesting but should we think about more options)
[~stack]
> Periodically check whether a system stop is requested in compaction by time.
> ----------------------------------------------------------------------------
>
> Key: HBASE-23968
> URL: https://issues.apache.org/jira/browse/HBASE-23968
> Project: HBase
> Issue Type: Improvement
> Components: Compaction
> Reporter: Minwoo Kang
> Assignee: Minwoo Kang
> Priority: Minor
> Fix For: 3.0.0-alpha-1
>
>
> The compaction check that the system is stopped when it reaches
> hbase.hstore.close.check.interval size.
> If the size is not reached, the compaction does not stop even though the
> system is stopped.
> If compaction is not terminated, the region is not closed.
> As a result, region remains pending-close.
>
> Thread A (regionserver/longCompactions):
> State: RUNNABLE
> Stack:
> org.apache.hadoop.hbase.regionserver.compactions.Compactor.performCompaction(Compactor.java:319)
> org.apache.hadoop.hbase.regionserver.compactions.DefaultCompactor.compact(DefaultCompactor.java:111)
> org.apache.hadoop.hbase.regionserver.DefaultStoreEngine$DefaultCompactionContext.compact(DefaultStoreEngine.java:119)
> org.apache.hadoop.hbase.regionserver.HStore.compact(HStore.java:1232)
> org.apache.hadoop.hbase.regionserver.HRegion.compact(HRegion.java:1896)
> org.apache.hadoop.hbase.regionserver.CompactSplitThread$CompactionRunner.doCompaction(CompactSplitThread.java:525)
> org.apache.hadoop.hbase.regionserver.CompactSplitThread$CompactionRunner.run(CompactSplitThread.java:562)
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
> java.lang.Thread.run(Thread.java:748)
> Thread B (RS_CLOSE_REGION):
> State: WAITING
> Waiting on org.apache.hadoop.hbase.regionserver.HRegion$WriteState
> Stack:
> java.lang.Object.wait(Native Method)
> java.lang.Object.wait(Object.java:502)
> org.apache.hadoop.hbase.regionserver.HRegion.waitForFlushesAndCompactions(HRegion.java:1567)
> org.apache.hadoop.hbase.regionserver.HRegion.doClose(HRegion.java:1417)
> org.apache.hadoop.hbase.regionserver.HRegion.close(HRegion.java:1380)
> org.apache.hadoop.hbase.regionserver.handler.CloseRegionHandler.process(CloseRegionHandler.java:138)
> org.apache.hadoop.hbase.executor.EventHandler.run(EventHandler.java:129)
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
> java.lang.Thread.run(Thread.java:748)
>
--
This message was sent by Atlassian Jira
(v8.3.4#803005)