[jira] [Updated] (HBASE-22810) Initialize an separate ThreadPoolExecutor for taking/restoring snapshot
[ https://issues.apache.org/jira/browse/HBASE-22810?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Zheng Hu updated HBASE-22810: - Fix Version/s: (was: 2.0.7) > Initialize an separate ThreadPoolExecutor for taking/restoring snapshot > > > Key: HBASE-22810 > URL: https://issues.apache.org/jira/browse/HBASE-22810 > Project: HBase > Issue Type: Improvement >Reporter: Zheng Hu >Assignee: Zheng Hu >Priority: Major > Fix For: 3.0.0, 1.5.0, 2.3.0, 2.2.1, 2.1.6, 1.3.6, 1.4.11 > > > In EventType class, we have the following definition, means taking snapshot > & restoring snapshot are use the MASTER_TABLE_OPERATIONS Executor now. > {code} > /** >* Messages originating from Client to Master. >* C_M_SNAPSHOT_TABLE >* Client asking Master to snapshot an offline table. >*/ > C_M_SNAPSHOT_TABLE(48, ExecutorType.MASTER_TABLE_OPERATIONS), > /** >* Messages originating from Client to Master. >* C_M_RESTORE_SNAPSHOT >* Client asking Master to restore a snapshot. >*/ > C_M_RESTORE_SNAPSHOT (49, ExecutorType.MASTER_TABLE_OPERATIONS), > {code} > But when I checked the MASTER_TABLE_OPERATIONS thread pool initialization, I > see : > {code} > private void startServiceThreads() throws IOException{ >// ... some other code initializing >// We depend on there being only one instance of this executor running >// at a time. To do concurrency, would need fencing of enable/disable of >// tables. >// Any time changing this maxThreads to > 1, pls see the comment at >// AccessController#postCompletedCreateTableAction > > this.executorService.startExecutorService(ExecutorType.MASTER_TABLE_OPERATIONS, > 1); >startProcedureExecutor(); > {code} > That's to say, for CPs enable or disable table sequencely, we will create > a ThreadPoolExecutor with threadPoolSize=1. Then we actually cann't > accomplish the snapshoting concurrence even if they are total difference > tables, says if there are two table snapshoting request, and the Table A cost > 5min for snapshoting, then the Table B need to wait 5min and once Table A > finish its snapshot , then Table B will start the snapshot. > While we've setting the snapshot timeout, so it will be easy to timeout for > table B snapshoting . Actually, we can create a separate thead pool for > snapshot operations only. -- This message was sent by Atlassian Jira (v8.3.2#803003)
[jira] [Updated] (HBASE-22810) Initialize an separate ThreadPoolExecutor for taking/restoring snapshot
[ https://issues.apache.org/jira/browse/HBASE-22810?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] stack updated HBASE-22810: -- Fix Version/s: (was: 2.0.6) 2.0.7 > Initialize an separate ThreadPoolExecutor for taking/restoring snapshot > > > Key: HBASE-22810 > URL: https://issues.apache.org/jira/browse/HBASE-22810 > Project: HBase > Issue Type: Improvement >Reporter: Zheng Hu >Assignee: Zheng Hu >Priority: Major > Fix For: 3.0.0, 1.5.0, 2.3.0, 2.2.1, 2.1.6, 1.3.6, 1.4.11, 2.0.7 > > > In EventType class, we have the following definition, means taking snapshot > & restoring snapshot are use the MASTER_TABLE_OPERATIONS Executor now. > {code} > /** >* Messages originating from Client to Master. >* C_M_SNAPSHOT_TABLE >* Client asking Master to snapshot an offline table. >*/ > C_M_SNAPSHOT_TABLE(48, ExecutorType.MASTER_TABLE_OPERATIONS), > /** >* Messages originating from Client to Master. >* C_M_RESTORE_SNAPSHOT >* Client asking Master to restore a snapshot. >*/ > C_M_RESTORE_SNAPSHOT (49, ExecutorType.MASTER_TABLE_OPERATIONS), > {code} > But when I checked the MASTER_TABLE_OPERATIONS thread pool initialization, I > see : > {code} > private void startServiceThreads() throws IOException{ >// ... some other code initializing >// We depend on there being only one instance of this executor running >// at a time. To do concurrency, would need fencing of enable/disable of >// tables. >// Any time changing this maxThreads to > 1, pls see the comment at >// AccessController#postCompletedCreateTableAction > > this.executorService.startExecutorService(ExecutorType.MASTER_TABLE_OPERATIONS, > 1); >startProcedureExecutor(); > {code} > That's to say, for CPs enable or disable table sequencely, we will create > a ThreadPoolExecutor with threadPoolSize=1. Then we actually cann't > accomplish the snapshoting concurrence even if they are total difference > tables, says if there are two table snapshoting request, and the Table A cost > 5min for snapshoting, then the Table B need to wait 5min and once Table A > finish its snapshot , then Table B will start the snapshot. > While we've setting the snapshot timeout, so it will be easy to timeout for > table B snapshoting . Actually, we can create a separate thead pool for > snapshot operations only. -- This message was sent by Atlassian Jira (v8.3.2#803003)
[jira] [Updated] (HBASE-22810) Initialize an separate ThreadPoolExecutor for taking/restoring snapshot
[ https://issues.apache.org/jira/browse/HBASE-22810?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Zheng Hu updated HBASE-22810: - Hadoop Flags: Reviewed Fix Version/s: 1.4.11 1.3.6 2.1.6 2.2.1 2.0.6 2.3.0 1.5.0 3.0.0 Release Note: Introduced a new config key for the snapshot taking/restoring operations at master side: hbase.master.executor.snapshot.threads, its default value is 3. means we can have 3 snapshot operations running at the same time. Pushed to all branch-2.x & master & branch-1.3/branch-1.4/branch-1. Thanks [~Apache9] & [~zghaobac] for reviewing. > Initialize an separate ThreadPoolExecutor for taking/restoring snapshot > > > Key: HBASE-22810 > URL: https://issues.apache.org/jira/browse/HBASE-22810 > Project: HBase > Issue Type: Improvement >Reporter: Zheng Hu >Assignee: Zheng Hu >Priority: Major > Fix For: 3.0.0, 1.5.0, 2.3.0, 2.0.6, 2.2.1, 2.1.6, 1.3.6, 1.4.11 > > > In EventType class, we have the following definition, means taking snapshot > & restoring snapshot are use the MASTER_TABLE_OPERATIONS Executor now. > {code} > /** >* Messages originating from Client to Master. >* C_M_SNAPSHOT_TABLE >* Client asking Master to snapshot an offline table. >*/ > C_M_SNAPSHOT_TABLE(48, ExecutorType.MASTER_TABLE_OPERATIONS), > /** >* Messages originating from Client to Master. >* C_M_RESTORE_SNAPSHOT >* Client asking Master to restore a snapshot. >*/ > C_M_RESTORE_SNAPSHOT (49, ExecutorType.MASTER_TABLE_OPERATIONS), > {code} > But when I checked the MASTER_TABLE_OPERATIONS thread pool initialization, I > see : > {code} > private void startServiceThreads() throws IOException{ >// ... some other code initializing >// We depend on there being only one instance of this executor running >// at a time. To do concurrency, would need fencing of enable/disable of >// tables. >// Any time changing this maxThreads to > 1, pls see the comment at >// AccessController#postCompletedCreateTableAction > > this.executorService.startExecutorService(ExecutorType.MASTER_TABLE_OPERATIONS, > 1); >startProcedureExecutor(); > {code} > That's to say, for CPs enable or disable table sequencely, we will create > a ThreadPoolExecutor with threadPoolSize=1. Then we actually cann't > accomplish the snapshoting concurrence even if they are total difference > tables, says if there are two table snapshoting request, and the Table A cost > 5min for snapshoting, then the Table B need to wait 5min and once Table A > finish its snapshot , then Table B will start the snapshot. > While we've setting the snapshot timeout, so it will be easy to timeout for > table B snapshoting . Actually, we can create a separate thead pool for > snapshot operations only. -- This message was sent by Atlassian JIRA (v7.6.14#76016)