[ 
https://issues.apache.org/jira/browse/HBASE-16570?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15635352#comment-15635352
 ] 

Yu Li commented on HBASE-16570:
-------------------------------

>From our online usage we found at master startup the thread number might blow 
>up simply because we're not limiting the maximum thread number of the executor 
>used in {{RegionLocationFinder}}:
{code}
  RegionLocationFinder() {
    this.cache = createCache();
    executor = MoreExecutors.listeningDecorator(
        Executors.newScheduledThreadPool(
            5,
            new ThreadFactoryBuilder().
                setDaemon(true)
                .setNameFormat("region-location-%d")
                .build()));
  }
{code}
And since in patch here we will submit as many as region number tasks to get 
block locations, we should add some limit on thread number in parallel as well 
as preventing all threads starting at the same time (like use executor.schedule 
instead of executor.submit).

[~aoxiang] please upload fix of this issue as another addendum, thanks.

> Compute region locality in parallel at startup
> ----------------------------------------------
>
>                 Key: HBASE-16570
>                 URL: https://issues.apache.org/jira/browse/HBASE-16570
>             Project: HBase
>          Issue Type: Sub-task
>            Reporter: binlijin
>            Assignee: binlijin
>             Fix For: 2.0.0, 1.4.0, 1.3.1
>
>         Attachments: HBASE-16570-master_V1.patch, 
> HBASE-16570-master_V2.patch, HBASE-16570-master_V3.patch, 
> HBASE-16570-master_V4.patch, HBASE-16570.branch-1.3-addendum.patch, 
> HBASE-16570_addnum.patch, HBASE-16570_addnum_v2.patch, 
> HBASE-16570_addnum_v3.patch, HBASE-16570_addnum_v4.patch
>
>




--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to