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

Jingyun Tian edited comment on HBASE-18619 at 12/7/17 8:52 AM:
---------------------------------------------------------------

[~apurtell] OK, since the frame of master branch is different, I will check out 
how to deal with it.
2.0 won't have the problem because it split region at Master and open the 
daughter regions through the assignment path.
But 1.4 still has the problem, should I provide a patch for it?


was (Author: tianjingyun):
[~apurtell] OK, since the frame of master branch is different, I will check out 
how to deal with it.

> Should we add a postOpenDeployTasks after open splited or merged region?
> ------------------------------------------------------------------------
>
>                 Key: HBASE-18619
>                 URL: https://issues.apache.org/jira/browse/HBASE-18619
>             Project: HBase
>          Issue Type: Bug
>          Components: Region Assignment
>    Affects Versions: 0.98.6, 1.4.0, 1.2.6, 1.1.11
>            Reporter: Jingyun Tian
>            Assignee: Jingyun Tian
>         Attachments: HBASE-18619.patch
>
>
> I have a question that why we skip postOpenDeployTasks() when we not using zk 
> for assignment?
> {code:java}
>       if (services != null) {
>         try {
>           if (useZKForAssignment) {
>             // add 2nd daughter first (see HBASE-4335)
>             services.postOpenDeployTasks(b);
>           } else if 
> (!services.reportRegionStateTransition(TransitionCode.SPLIT,
>               parent.getRegionInfo(), hri_a, hri_b)) {
>             throw new IOException("Failed to report split region to master: "
>               + parent.getRegionInfo().getShortNameToLog());
>           }
>           // Should add it to OnlineRegions
>           services.addToOnlineRegions(b);
>           if (useZKForAssignment) {
>             services.postOpenDeployTasks(a);
>           }
>           services.addToOnlineRegions(a);
>         } catch (KeeperException ke) {
>           throw new IOException(ke);
>         }
>       }
> {code}
> It causes a new splitted region or new merged region will not compact their 
> reference files. Then if the normalizer thread want to split this region, it 
> will get stuck. 
> {code:java}
> public boolean canSplit() {
>     this.lock.readLock().lock();
>     try {
>       // Not split-able if we find a reference store file present in the 
> store.
>       boolean result = !hasReferences();
>       if (!result && LOG.isDebugEnabled()) {
>         LOG.debug("Cannot split region due to reference files being there");
>       }
>       return result;
>     } finally {
>       this.lock.readLock().unlock();
>     }
>   }
> {code}
> According to the code, should we add a  services.postOpenDeployTasks after 
> successfully _*reportRegionStateTransition(TransitionCode.SPLIT, 
> parent.getRegionInfo(), hri_a, hri_b)*_ ?



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to