[
https://issues.apache.org/jira/browse/HBASE-20881?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Duo Zhang updated HBASE-20881:
------------------------------
Release Note:
Introduced a new TransitRegionStateProcedure to replace the old
AssignProcedure/UnassignProcedure/MoveRegionProcedure. In the old code, MRP
will not be attached to RegionStateNode, so it can not be interrupted by
ServerCrashProcedure, which introduces lots of tricky code to deal with races,
and also causes lots of other difficulties on how to prevent scheduling
redundant or even conflict procedures for a region.
And now TRSP is the only one procedure which can bring region online or
offline. When you want to schedule one, you need to check whether there is
already one attached to the RegionStateNode, under the lock of the
RegionStateNode. If not just go ahead, and if there is one, then you should do
something, for example, give up and fail directly, or tell the TRSP to give
up(This is what SCP does). Since the check and attach are both under the lock
of RSN, it will greatly reduce the possible races, and make the code much
simpler.
> Introduce a region transition procedure to handle all the state transition
> for a region
> ---------------------------------------------------------------------------------------
>
> Key: HBASE-20881
> URL: https://issues.apache.org/jira/browse/HBASE-20881
> Project: HBase
> Issue Type: Sub-task
> Components: amv2, proc-v2
> Reporter: Duo Zhang
> Assignee: Duo Zhang
> Priority: Major
> Fix For: 3.0.0, 2.2.0
>
> Attachments: HBASE-20881-v1.patch, HBASE-20881-v10.patch,
> HBASE-20881-v11.patch, HBASE-20881-v12.patch, HBASE-20881-v13.patch,
> HBASE-20881-v13.patch, HBASE-20881-v14.patch, HBASE-20881-v14.patch,
> HBASE-20881-v2.patch, HBASE-20881-v3.patch, HBASE-20881-v4.patch,
> HBASE-20881-v4.patch, HBASE-20881-v5.patch, HBASE-20881-v6.patch,
> HBASE-20881-v7.patch, HBASE-20881-v7.patch, HBASE-20881-v8.patch,
> HBASE-20881-v9.patch, HBASE-20881.patch
>
>
> Now have an AssignProcedure, an UnssignProcedure, and also a
> MoveRegionProcedure which schedules an AssignProcedure and an
> UnssignProcedure to move a region. This makes the logic a bit complicated, as
> MRP is not a RIT, so when SCP can not interrupt it directly...
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)