[jira] [Commented] (HBASE-4899) Region would be assigned twice easily with continually killing server and moving region in testing environment

2012-01-05 Thread ramkrishna.s.vasudevan (Commented) (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-4899?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13180392#comment-13180392
 ] 

ramkrishna.s.vasudevan commented on HBASE-4899:
---

@Stack and @Chunhui

This defect is not present in 0.90 branch? But the fixed version says it is in 
0.90?
Do we need to add in 0.90.6? 


 Region would be assigned twice easily with continually  killing server and 
 moving region in testing environment
 ---

 Key: HBASE-4899
 URL: https://issues.apache.org/jira/browse/HBASE-4899
 Project: HBase
  Issue Type: Bug
Affects Versions: 0.92.1
Reporter: chunhui shen
Assignee: chunhui shen
Priority: Critical
 Fix For: 0.90.0

 Attachments: hbase-4899.patch, hbase-4899v2.patch, hbase-4899v3.patch


 Before assigning region in ServerShutdownHandler#process, it will check 
 whether region is in RIT,
 however, this checking doesn't work as the excepted in the following case:
 1.move region A from server B to server C
 2.kill server B
 3.start server B immediately
 Let's see what happen in the code for the above case
 {code}
 for step1:
 1.1 server B close the region A,
 1.2 master setOffline for region 
 A,(AssignmentManager#setOffline:this.regions.remove(regionInfo))
 1.3 server C start to open region A.(Not completed)
 for step3:
 master ServerShutdownHandler#process() for server B
 {
 ..
 splitlog()
 ...
 ListRegionState regionsInTransition =
 this.services.getAssignmentManager()
 .processServerShutdown(this.serverName);
 ...
 Skip regions that were in transition unless CLOSING or PENDING_CLOSE
 ...
 assign region
 }
 {code}
 In fact, when running 
 ServerShutdownHandler#process()#this.services.getAssignmentManager().processServerShutdown(this.serverName),
  region A is in RIT (step1.3 not completed), but the return ListRegionState 
 regionsInTransition doesn't contain it, because region A has removed from 
 AssignmentManager.regions by AssignmentManager#setOffline in step 1.2
 Therefore, region A will be assigned twice.
 Actually, one server killed and started twice will also easily cause region 
 assigned twice.
 Exclude the above reason, another probability : 
 when execute ServerShutdownHandler#process()#MetaReader.getServerUserRegions 
 ,region is included which is in RIT now.
 But after completing MetaReader.getServerUserRegions, the region has been 
 opened in other server and is not in RIT now.
 In our testing environment where balancing,moving and killing are executed 
 periodly, assigning region twice often happens, and it is hateful because it 
 will affect other test cases.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HBASE-4899) Region would be assigned twice easily with continually killing server and moving region in testing environment

2012-01-05 Thread ramkrishna.s.vasudevan (Commented) (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-4899?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13181152#comment-13181152
 ] 

ramkrishna.s.vasudevan commented on HBASE-4899:
---

Updated as committed only to Trunk and 0.92 and not in 0.90

 Region would be assigned twice easily with continually  killing server and 
 moving region in testing environment
 ---

 Key: HBASE-4899
 URL: https://issues.apache.org/jira/browse/HBASE-4899
 Project: HBase
  Issue Type: Bug
Affects Versions: 0.92.0
Reporter: chunhui shen
Assignee: chunhui shen
Priority: Critical
 Fix For: 0.92.0

 Attachments: hbase-4899.patch, hbase-4899v2.patch, hbase-4899v3.patch


 Before assigning region in ServerShutdownHandler#process, it will check 
 whether region is in RIT,
 however, this checking doesn't work as the excepted in the following case:
 1.move region A from server B to server C
 2.kill server B
 3.start server B immediately
 Let's see what happen in the code for the above case
 {code}
 for step1:
 1.1 server B close the region A,
 1.2 master setOffline for region 
 A,(AssignmentManager#setOffline:this.regions.remove(regionInfo))
 1.3 server C start to open region A.(Not completed)
 for step3:
 master ServerShutdownHandler#process() for server B
 {
 ..
 splitlog()
 ...
 ListRegionState regionsInTransition =
 this.services.getAssignmentManager()
 .processServerShutdown(this.serverName);
 ...
 Skip regions that were in transition unless CLOSING or PENDING_CLOSE
 ...
 assign region
 }
 {code}
 In fact, when running 
 ServerShutdownHandler#process()#this.services.getAssignmentManager().processServerShutdown(this.serverName),
  region A is in RIT (step1.3 not completed), but the return ListRegionState 
 regionsInTransition doesn't contain it, because region A has removed from 
 AssignmentManager.regions by AssignmentManager#setOffline in step 1.2
 Therefore, region A will be assigned twice.
 Actually, one server killed and started twice will also easily cause region 
 assigned twice.
 Exclude the above reason, another probability : 
 when execute ServerShutdownHandler#process()#MetaReader.getServerUserRegions 
 ,region is included which is in RIT now.
 But after completing MetaReader.getServerUserRegions, the region has been 
 opened in other server and is not in RIT now.
 In our testing environment where balancing,moving and killing are executed 
 periodly, assigning region twice often happens, and it is hateful because it 
 will affect other test cases.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HBASE-4899) Region would be assigned twice easily with continually killing server and moving region in testing environment

2011-12-03 Thread Hudson (Commented) (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-4899?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13162081#comment-13162081
 ] 

Hudson commented on HBASE-4899:
---

Integrated in HBase-TRUNK-security #19 (See 
[https://builds.apache.org/job/HBase-TRUNK-security/19/])
HBASE-4899 Region would be assigned twice easily with continually killing 
server and moving region in testing environment

stack : 
Files : 
* 
/hbase/trunk/src/main/java/org/apache/hadoop/hbase/master/handler/ServerShutdownHandler.java


 Region would be assigned twice easily with continually  killing server and 
 moving region in testing environment
 ---

 Key: HBASE-4899
 URL: https://issues.apache.org/jira/browse/HBASE-4899
 Project: HBase
  Issue Type: Bug
Affects Versions: 0.92.1
Reporter: chunhui shen
Assignee: chunhui shen
Priority: Critical
 Fix For: 0.92.1

 Attachments: hbase-4899.patch, hbase-4899v2.patch, hbase-4899v3.patch


 Before assigning region in ServerShutdownHandler#process, it will check 
 whether region is in RIT,
 however, this checking doesn't work as the excepted in the following case:
 1.move region A from server B to server C
 2.kill server B
 3.start server B immediately
 Let's see what happen in the code for the above case
 {code}
 for step1:
 1.1 server B close the region A,
 1.2 master setOffline for region 
 A,(AssignmentManager#setOffline:this.regions.remove(regionInfo))
 1.3 server C start to open region A.(Not completed)
 for step3:
 master ServerShutdownHandler#process() for server B
 {
 ..
 splitlog()
 ...
 ListRegionState regionsInTransition =
 this.services.getAssignmentManager()
 .processServerShutdown(this.serverName);
 ...
 Skip regions that were in transition unless CLOSING or PENDING_CLOSE
 ...
 assign region
 }
 {code}
 In fact, when running 
 ServerShutdownHandler#process()#this.services.getAssignmentManager().processServerShutdown(this.serverName),
  region A is in RIT (step1.3 not completed), but the return ListRegionState 
 regionsInTransition doesn't contain it, because region A has removed from 
 AssignmentManager.regions by AssignmentManager#setOffline in step 1.2
 Therefore, region A will be assigned twice.
 Actually, one server killed and started twice will also easily cause region 
 assigned twice.
 Exclude the above reason, another probability : 
 when execute ServerShutdownHandler#process()#MetaReader.getServerUserRegions 
 ,region is included which is in RIT now.
 But after completing MetaReader.getServerUserRegions, the region has been 
 opened in other server and is not in RIT now.
 In our testing environment where balancing,moving and killing are executed 
 periodly, assigning region twice often happens, and it is hateful because it 
 will affect other test cases.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HBASE-4899) Region would be assigned twice easily with continually killing server and moving region in testing environment

2011-12-02 Thread Hudson (Commented) (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-4899?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13161473#comment-13161473
 ] 

Hudson commented on HBASE-4899:
---

Integrated in HBase-0.92 #168 (See 
[https://builds.apache.org/job/HBase-0.92/168/])
HBASE-4899 Region would be assigned twice easily with continually killing 
server and moving region in testing environment

stack : 
Files : 
* /hbase/branches/0.92/CHANGES.txt
* 
/hbase/branches/0.92/src/main/java/org/apache/hadoop/hbase/master/handler/ServerShutdownHandler.java


 Region would be assigned twice easily with continually  killing server and 
 moving region in testing environment
 ---

 Key: HBASE-4899
 URL: https://issues.apache.org/jira/browse/HBASE-4899
 Project: HBase
  Issue Type: Bug
Affects Versions: 0.92.1
Reporter: chunhui shen
Assignee: chunhui shen
Priority: Critical
 Fix For: 0.92.1

 Attachments: hbase-4899.patch, hbase-4899v2.patch, hbase-4899v3.patch


 Before assigning region in ServerShutdownHandler#process, it will check 
 whether region is in RIT,
 however, this checking doesn't work as the excepted in the following case:
 1.move region A from server B to server C
 2.kill server B
 3.start server B immediately
 Let's see what happen in the code for the above case
 {code}
 for step1:
 1.1 server B close the region A,
 1.2 master setOffline for region 
 A,(AssignmentManager#setOffline:this.regions.remove(regionInfo))
 1.3 server C start to open region A.(Not completed)
 for step3:
 master ServerShutdownHandler#process() for server B
 {
 ..
 splitlog()
 ...
 ListRegionState regionsInTransition =
 this.services.getAssignmentManager()
 .processServerShutdown(this.serverName);
 ...
 Skip regions that were in transition unless CLOSING or PENDING_CLOSE
 ...
 assign region
 }
 {code}
 In fact, when running 
 ServerShutdownHandler#process()#this.services.getAssignmentManager().processServerShutdown(this.serverName),
  region A is in RIT (step1.3 not completed), but the return ListRegionState 
 regionsInTransition doesn't contain it, because region A has removed from 
 AssignmentManager.regions by AssignmentManager#setOffline in step 1.2
 Therefore, region A will be assigned twice.
 Actually, one server killed and started twice will also easily cause region 
 assigned twice.
 Exclude the above reason, another probability : 
 when execute ServerShutdownHandler#process()#MetaReader.getServerUserRegions 
 ,region is included which is in RIT now.
 But after completing MetaReader.getServerUserRegions, the region has been 
 opened in other server and is not in RIT now.
 In our testing environment where balancing,moving and killing are executed 
 periodly, assigning region twice often happens, and it is hateful because it 
 will affect other test cases.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HBASE-4899) Region would be assigned twice easily with continually killing server and moving region in testing environment

2011-12-02 Thread Hudson (Commented) (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-4899?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13161514#comment-13161514
 ] 

Hudson commented on HBASE-4899:
---

Integrated in HBase-TRUNK #2508 (See 
[https://builds.apache.org/job/HBase-TRUNK/2508/])
HBASE-4899 Region would be assigned twice easily with continually killing 
server and moving region in testing environment

stack : 
Files : 
* 
/hbase/trunk/src/main/java/org/apache/hadoop/hbase/master/handler/ServerShutdownHandler.java


 Region would be assigned twice easily with continually  killing server and 
 moving region in testing environment
 ---

 Key: HBASE-4899
 URL: https://issues.apache.org/jira/browse/HBASE-4899
 Project: HBase
  Issue Type: Bug
Affects Versions: 0.92.1
Reporter: chunhui shen
Assignee: chunhui shen
Priority: Critical
 Fix For: 0.92.1

 Attachments: hbase-4899.patch, hbase-4899v2.patch, hbase-4899v3.patch


 Before assigning region in ServerShutdownHandler#process, it will check 
 whether region is in RIT,
 however, this checking doesn't work as the excepted in the following case:
 1.move region A from server B to server C
 2.kill server B
 3.start server B immediately
 Let's see what happen in the code for the above case
 {code}
 for step1:
 1.1 server B close the region A,
 1.2 master setOffline for region 
 A,(AssignmentManager#setOffline:this.regions.remove(regionInfo))
 1.3 server C start to open region A.(Not completed)
 for step3:
 master ServerShutdownHandler#process() for server B
 {
 ..
 splitlog()
 ...
 ListRegionState regionsInTransition =
 this.services.getAssignmentManager()
 .processServerShutdown(this.serverName);
 ...
 Skip regions that were in transition unless CLOSING or PENDING_CLOSE
 ...
 assign region
 }
 {code}
 In fact, when running 
 ServerShutdownHandler#process()#this.services.getAssignmentManager().processServerShutdown(this.serverName),
  region A is in RIT (step1.3 not completed), but the return ListRegionState 
 regionsInTransition doesn't contain it, because region A has removed from 
 AssignmentManager.regions by AssignmentManager#setOffline in step 1.2
 Therefore, region A will be assigned twice.
 Actually, one server killed and started twice will also easily cause region 
 assigned twice.
 Exclude the above reason, another probability : 
 when execute ServerShutdownHandler#process()#MetaReader.getServerUserRegions 
 ,region is included which is in RIT now.
 But after completing MetaReader.getServerUserRegions, the region has been 
 opened in other server and is not in RIT now.
 In our testing environment where balancing,moving and killing are executed 
 periodly, assigning region twice often happens, and it is hateful because it 
 will affect other test cases.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HBASE-4899) Region would be assigned twice easily with continually killing server and moving region in testing environment

2011-12-02 Thread Hudson (Commented) (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-4899?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13162059#comment-13162059
 ] 

Hudson commented on HBASE-4899:
---

Integrated in HBase-0.92-security #29 (See 
[https://builds.apache.org/job/HBase-0.92-security/29/])
HBASE-4899 Region would be assigned twice easily with continually killing 
server and moving region in testing environment

stack : 
Files : 
* /hbase/branches/0.92/CHANGES.txt
* 
/hbase/branches/0.92/src/main/java/org/apache/hadoop/hbase/master/handler/ServerShutdownHandler.java


 Region would be assigned twice easily with continually  killing server and 
 moving region in testing environment
 ---

 Key: HBASE-4899
 URL: https://issues.apache.org/jira/browse/HBASE-4899
 Project: HBase
  Issue Type: Bug
Affects Versions: 0.92.1
Reporter: chunhui shen
Assignee: chunhui shen
Priority: Critical
 Fix For: 0.92.1

 Attachments: hbase-4899.patch, hbase-4899v2.patch, hbase-4899v3.patch


 Before assigning region in ServerShutdownHandler#process, it will check 
 whether region is in RIT,
 however, this checking doesn't work as the excepted in the following case:
 1.move region A from server B to server C
 2.kill server B
 3.start server B immediately
 Let's see what happen in the code for the above case
 {code}
 for step1:
 1.1 server B close the region A,
 1.2 master setOffline for region 
 A,(AssignmentManager#setOffline:this.regions.remove(regionInfo))
 1.3 server C start to open region A.(Not completed)
 for step3:
 master ServerShutdownHandler#process() for server B
 {
 ..
 splitlog()
 ...
 ListRegionState regionsInTransition =
 this.services.getAssignmentManager()
 .processServerShutdown(this.serverName);
 ...
 Skip regions that were in transition unless CLOSING or PENDING_CLOSE
 ...
 assign region
 }
 {code}
 In fact, when running 
 ServerShutdownHandler#process()#this.services.getAssignmentManager().processServerShutdown(this.serverName),
  region A is in RIT (step1.3 not completed), but the return ListRegionState 
 regionsInTransition doesn't contain it, because region A has removed from 
 AssignmentManager.regions by AssignmentManager#setOffline in step 1.2
 Therefore, region A will be assigned twice.
 Actually, one server killed and started twice will also easily cause region 
 assigned twice.
 Exclude the above reason, another probability : 
 when execute ServerShutdownHandler#process()#MetaReader.getServerUserRegions 
 ,region is included which is in RIT now.
 But after completing MetaReader.getServerUserRegions, the region has been 
 opened in other server and is not in RIT now.
 In our testing environment where balancing,moving and killing are executed 
 periodly, assigning region twice often happens, and it is hateful because it 
 will affect other test cases.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HBASE-4899) Region would be assigned twice easily with continually killing server and moving region in testing environment

2011-11-30 Thread chunhui shen (Commented) (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-4899?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13159921#comment-13159921
 ] 

chunhui shen commented on HBASE-4899:
-

@Ted
{code}
+  +  because it has been opened in 
+  + addressFromAM.getServerName());
{code}
To the above log, the region must has been opend, because the return of 
AssignmentManager#getRegionServerOfRegion(region) is other server.

Test is running now.

 Region would be assigned twice easily with continually  killing server and 
 moving region in testing environment
 ---

 Key: HBASE-4899
 URL: https://issues.apache.org/jira/browse/HBASE-4899
 Project: HBase
  Issue Type: Bug
Affects Versions: 0.92.0
Reporter: chunhui shen
Assignee: chunhui shen
 Attachments: hbase-4899.patch


 Before assigning region in ServerShutdownHandler#process, it will check 
 whether region is in RIT,
 however, this checking doesn't work as the excepted in the following case:
 1.move region A from server B to server C
 2.kill server B
 3.start server B immediately
 Let's see what happen in the code for the above case
 {code}
 for step1:
 1.1 server B close the region A,
 1.2 master setOffline for region 
 A,(AssignmentManager#setOffline:this.regions.remove(regionInfo))
 1.3 server C start to open region A.(Not completed)
 for step3:
 master ServerShutdownHandler#process() for server B
 {
 ..
 splitlog()
 ...
 ListRegionState regionsInTransition =
 this.services.getAssignmentManager()
 .processServerShutdown(this.serverName);
 ...
 Skip regions that were in transition unless CLOSING or PENDING_CLOSE
 ...
 assign region
 }
 {code}
 In fact, when running 
 ServerShutdownHandler#process()#this.services.getAssignmentManager().processServerShutdown(this.serverName),
  region A is in RIT (step1.3 not completed), but the return ListRegionState 
 regionsInTransition doesn't contain it, because region A has removed from 
 AssignmentManager.regions by AssignmentManager#setOffline in step 1.2
 Therefore, region A will be assigned twice.
 Actually, one server killed and started twice will also easily cause region 
 assigned twice.
 Exclude the above reason, another probability : 
 when execute ServerShutdownHandler#process()#MetaReader.getServerUserRegions 
 ,region is included which is in RIT now.
 But after completing MetaReader.getServerUserRegions, the region has been 
 opened in other server and is not in RIT now.
 In our testing environment where balancing,moving and killing are executed 
 periodly, assigning region twice often happens, and it is hateful because it 
 will affect other test cases.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HBASE-4899) Region would be assigned twice easily with continually killing server and moving region in testing environment

2011-11-30 Thread chunhui shen (Commented) (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-4899?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13160018#comment-13160018
 ] 

chunhui shen commented on HBASE-4899:
-

{code}
Results :

Tests run: 1176, Failures: 0, Errors: 0, Skipped: 9

[INFO] 
[INFO] --- maven-surefire-plugin:2.11-TRUNK-HBASE-2:test 
(secondPartTestsExecution) @ hbase ---
[INFO] Tests are skipped.
[INFO] 
[INFO] BUILD SUCCESS
[INFO] 
[INFO] Total time: 1:43:30.281s
[INFO] Finished at: Wed Nov 30 20:20:20 CST 2011
[INFO] Final Memory: 35M/361M
[INFO] 
{code}

 Region would be assigned twice easily with continually  killing server and 
 moving region in testing environment
 ---

 Key: HBASE-4899
 URL: https://issues.apache.org/jira/browse/HBASE-4899
 Project: HBase
  Issue Type: Bug
Affects Versions: 0.92.0
Reporter: chunhui shen
Assignee: chunhui shen
 Attachments: hbase-4899.patch


 Before assigning region in ServerShutdownHandler#process, it will check 
 whether region is in RIT,
 however, this checking doesn't work as the excepted in the following case:
 1.move region A from server B to server C
 2.kill server B
 3.start server B immediately
 Let's see what happen in the code for the above case
 {code}
 for step1:
 1.1 server B close the region A,
 1.2 master setOffline for region 
 A,(AssignmentManager#setOffline:this.regions.remove(regionInfo))
 1.3 server C start to open region A.(Not completed)
 for step3:
 master ServerShutdownHandler#process() for server B
 {
 ..
 splitlog()
 ...
 ListRegionState regionsInTransition =
 this.services.getAssignmentManager()
 .processServerShutdown(this.serverName);
 ...
 Skip regions that were in transition unless CLOSING or PENDING_CLOSE
 ...
 assign region
 }
 {code}
 In fact, when running 
 ServerShutdownHandler#process()#this.services.getAssignmentManager().processServerShutdown(this.serverName),
  region A is in RIT (step1.3 not completed), but the return ListRegionState 
 regionsInTransition doesn't contain it, because region A has removed from 
 AssignmentManager.regions by AssignmentManager#setOffline in step 1.2
 Therefore, region A will be assigned twice.
 Actually, one server killed and started twice will also easily cause region 
 assigned twice.
 Exclude the above reason, another probability : 
 when execute ServerShutdownHandler#process()#MetaReader.getServerUserRegions 
 ,region is included which is in RIT now.
 But after completing MetaReader.getServerUserRegions, the region has been 
 opened in other server and is not in RIT now.
 In our testing environment where balancing,moving and killing are executed 
 periodly, assigning region twice often happens, and it is hateful because it 
 will affect other test cases.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HBASE-4899) Region would be assigned twice easily with continually killing server and moving region in testing environment

2011-11-30 Thread chunhui shen (Commented) (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-4899?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13160025#comment-13160025
 ] 

chunhui shen commented on HBASE-4899:
-

In patchv1,{code}continue;{code} is forgot to add.
The above is test results with patchV2.

 Region would be assigned twice easily with continually  killing server and 
 moving region in testing environment
 ---

 Key: HBASE-4899
 URL: https://issues.apache.org/jira/browse/HBASE-4899
 Project: HBase
  Issue Type: Bug
Affects Versions: 0.92.0
Reporter: chunhui shen
Assignee: chunhui shen
 Attachments: hbase-4899.patch, hbase-4899v2.patch


 Before assigning region in ServerShutdownHandler#process, it will check 
 whether region is in RIT,
 however, this checking doesn't work as the excepted in the following case:
 1.move region A from server B to server C
 2.kill server B
 3.start server B immediately
 Let's see what happen in the code for the above case
 {code}
 for step1:
 1.1 server B close the region A,
 1.2 master setOffline for region 
 A,(AssignmentManager#setOffline:this.regions.remove(regionInfo))
 1.3 server C start to open region A.(Not completed)
 for step3:
 master ServerShutdownHandler#process() for server B
 {
 ..
 splitlog()
 ...
 ListRegionState regionsInTransition =
 this.services.getAssignmentManager()
 .processServerShutdown(this.serverName);
 ...
 Skip regions that were in transition unless CLOSING or PENDING_CLOSE
 ...
 assign region
 }
 {code}
 In fact, when running 
 ServerShutdownHandler#process()#this.services.getAssignmentManager().processServerShutdown(this.serverName),
  region A is in RIT (step1.3 not completed), but the return ListRegionState 
 regionsInTransition doesn't contain it, because region A has removed from 
 AssignmentManager.regions by AssignmentManager#setOffline in step 1.2
 Therefore, region A will be assigned twice.
 Actually, one server killed and started twice will also easily cause region 
 assigned twice.
 Exclude the above reason, another probability : 
 when execute ServerShutdownHandler#process()#MetaReader.getServerUserRegions 
 ,region is included which is in RIT now.
 But after completing MetaReader.getServerUserRegions, the region has been 
 opened in other server and is not in RIT now.
 In our testing environment where balancing,moving and killing are executed 
 periodly, assigning region twice often happens, and it is hateful because it 
 will affect other test cases.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HBASE-4899) Region would be assigned twice easily with continually killing server and moving region in testing environment

2011-11-30 Thread Hadoop QA (Commented) (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-4899?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13160057#comment-13160057
 ] 

Hadoop QA commented on HBASE-4899:
--

-1 overall.  Here are the results of testing the latest attachment 
  http://issues.apache.org/jira/secure/attachment/12505620/hbase-4899v2.patch
  against trunk revision .

+1 @author.  The patch does not contain any @author tags.

-1 tests included.  The patch doesn't appear to include any new or modified 
tests.
Please justify why no new tests are needed for this 
patch.
Also please list what manual steps were performed to 
verify this patch.

-1 javadoc.  The javadoc tool appears to have generated -162 warning 
messages.

+1 javac.  The applied patch does not increase the total number of javac 
compiler warnings.

-1 findbugs.  The patch appears to introduce 67 new Findbugs (version 
1.3.9) warnings.

+1 release audit.  The applied patch does not increase the total number of 
release audit warnings.

 -1 core tests.  The patch failed these unit tests:
   org.apache.hadoop.hbase.mapreduce.TestTimeRangeMapRed
  
org.apache.hadoop.hbase.mapreduce.TestLoadIncrementalHFilesSplitRecovery
  org.apache.hadoop.hbase.TestFullLogReconstruction
  org.apache.hadoop.hbase.mapreduce.TestImportTsv
  org.apache.hadoop.hbase.mapreduce.TestTableMapReduce

Test results: 
https://builds.apache.org/job/PreCommit-HBASE-Build/407//testReport/
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/407//artifact/trunk/patchprocess/newPatchFindbugsWarnings.html
Console output: https://builds.apache.org/job/PreCommit-HBASE-Build/407//console

This message is automatically generated.

 Region would be assigned twice easily with continually  killing server and 
 moving region in testing environment
 ---

 Key: HBASE-4899
 URL: https://issues.apache.org/jira/browse/HBASE-4899
 Project: HBase
  Issue Type: Bug
Affects Versions: 0.92.0
Reporter: chunhui shen
Assignee: chunhui shen
 Attachments: hbase-4899.patch, hbase-4899v2.patch


 Before assigning region in ServerShutdownHandler#process, it will check 
 whether region is in RIT,
 however, this checking doesn't work as the excepted in the following case:
 1.move region A from server B to server C
 2.kill server B
 3.start server B immediately
 Let's see what happen in the code for the above case
 {code}
 for step1:
 1.1 server B close the region A,
 1.2 master setOffline for region 
 A,(AssignmentManager#setOffline:this.regions.remove(regionInfo))
 1.3 server C start to open region A.(Not completed)
 for step3:
 master ServerShutdownHandler#process() for server B
 {
 ..
 splitlog()
 ...
 ListRegionState regionsInTransition =
 this.services.getAssignmentManager()
 .processServerShutdown(this.serverName);
 ...
 Skip regions that were in transition unless CLOSING or PENDING_CLOSE
 ...
 assign region
 }
 {code}
 In fact, when running 
 ServerShutdownHandler#process()#this.services.getAssignmentManager().processServerShutdown(this.serverName),
  region A is in RIT (step1.3 not completed), but the return ListRegionState 
 regionsInTransition doesn't contain it, because region A has removed from 
 AssignmentManager.regions by AssignmentManager#setOffline in step 1.2
 Therefore, region A will be assigned twice.
 Actually, one server killed and started twice will also easily cause region 
 assigned twice.
 Exclude the above reason, another probability : 
 when execute ServerShutdownHandler#process()#MetaReader.getServerUserRegions 
 ,region is included which is in RIT now.
 But after completing MetaReader.getServerUserRegions, the region has been 
 opened in other server and is not in RIT now.
 In our testing environment where balancing,moving and killing are executed 
 periodly, assigning region twice often happens, and it is hateful because it 
 will affect other test cases.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HBASE-4899) Region would be assigned twice easily with continually killing server and moving region in testing environment

2011-11-30 Thread stack (Commented) (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-4899?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13160437#comment-13160437
 ] 

stack commented on HBASE-4899:
--

Good find.  Here are some comments on the patch.

{code}
+if(rit!=null!rit.isClosing()  !rit.isPendingClose()){
{code}

Our style is to put spaces between operators as in 'if (rit != null ...' etc.


+  LOG.debug(Skip assgining region 

The above should be assigning.


+  + rit.getRegion().getRegionNameAsString()
+  +  because in RIT region state:  + rit.getState());

I think just to rit.toString()?



+  continue;

This is confusing.  Is this code inside a loop and this continue takes us to 
the head of the loop again?  Its buried pretty deeply here so I'd not be 
surprised if readers missed it.  Shouldn't you rather write the code as if/else?


+if (addressFromAM != null  
!addressFromAM.equals(this.serverName)) {
+  LOG.debug(Skip assgining region 

Again, a misspelling.

I can fix the above small things on commit or maybe you want to have a go at it?

This is a pretty nice find.  Thanks for the patch.

 Region would be assigned twice easily with continually  killing server and 
 moving region in testing environment
 ---

 Key: HBASE-4899
 URL: https://issues.apache.org/jira/browse/HBASE-4899
 Project: HBase
  Issue Type: Bug
Affects Versions: 0.92.1
Reporter: chunhui shen
Assignee: chunhui shen
 Attachments: hbase-4899.patch, hbase-4899v2.patch


 Before assigning region in ServerShutdownHandler#process, it will check 
 whether region is in RIT,
 however, this checking doesn't work as the excepted in the following case:
 1.move region A from server B to server C
 2.kill server B
 3.start server B immediately
 Let's see what happen in the code for the above case
 {code}
 for step1:
 1.1 server B close the region A,
 1.2 master setOffline for region 
 A,(AssignmentManager#setOffline:this.regions.remove(regionInfo))
 1.3 server C start to open region A.(Not completed)
 for step3:
 master ServerShutdownHandler#process() for server B
 {
 ..
 splitlog()
 ...
 ListRegionState regionsInTransition =
 this.services.getAssignmentManager()
 .processServerShutdown(this.serverName);
 ...
 Skip regions that were in transition unless CLOSING or PENDING_CLOSE
 ...
 assign region
 }
 {code}
 In fact, when running 
 ServerShutdownHandler#process()#this.services.getAssignmentManager().processServerShutdown(this.serverName),
  region A is in RIT (step1.3 not completed), but the return ListRegionState 
 regionsInTransition doesn't contain it, because region A has removed from 
 AssignmentManager.regions by AssignmentManager#setOffline in step 1.2
 Therefore, region A will be assigned twice.
 Actually, one server killed and started twice will also easily cause region 
 assigned twice.
 Exclude the above reason, another probability : 
 when execute ServerShutdownHandler#process()#MetaReader.getServerUserRegions 
 ,region is included which is in RIT now.
 But after completing MetaReader.getServerUserRegions, the region has been 
 opened in other server and is not in RIT now.
 In our testing environment where balancing,moving and killing are executed 
 periodly, assigning region twice often happens, and it is hateful because it 
 will affect other test cases.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HBASE-4899) Region would be assigned twice easily with continually killing server and moving region in testing environment

2011-11-30 Thread chunhui shen (Commented) (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-4899?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13160574#comment-13160574
 ] 

chunhui shen commented on HBASE-4899:
-

@stack
I has amend it in patchV3.
Thanks.

 Region would be assigned twice easily with continually  killing server and 
 moving region in testing environment
 ---

 Key: HBASE-4899
 URL: https://issues.apache.org/jira/browse/HBASE-4899
 Project: HBase
  Issue Type: Bug
Affects Versions: 0.92.1
Reporter: chunhui shen
Assignee: chunhui shen
Priority: Critical
 Attachments: hbase-4899.patch, hbase-4899v2.patch, hbase-4899v3.patch


 Before assigning region in ServerShutdownHandler#process, it will check 
 whether region is in RIT,
 however, this checking doesn't work as the excepted in the following case:
 1.move region A from server B to server C
 2.kill server B
 3.start server B immediately
 Let's see what happen in the code for the above case
 {code}
 for step1:
 1.1 server B close the region A,
 1.2 master setOffline for region 
 A,(AssignmentManager#setOffline:this.regions.remove(regionInfo))
 1.3 server C start to open region A.(Not completed)
 for step3:
 master ServerShutdownHandler#process() for server B
 {
 ..
 splitlog()
 ...
 ListRegionState regionsInTransition =
 this.services.getAssignmentManager()
 .processServerShutdown(this.serverName);
 ...
 Skip regions that were in transition unless CLOSING or PENDING_CLOSE
 ...
 assign region
 }
 {code}
 In fact, when running 
 ServerShutdownHandler#process()#this.services.getAssignmentManager().processServerShutdown(this.serverName),
  region A is in RIT (step1.3 not completed), but the return ListRegionState 
 regionsInTransition doesn't contain it, because region A has removed from 
 AssignmentManager.regions by AssignmentManager#setOffline in step 1.2
 Therefore, region A will be assigned twice.
 Actually, one server killed and started twice will also easily cause region 
 assigned twice.
 Exclude the above reason, another probability : 
 when execute ServerShutdownHandler#process()#MetaReader.getServerUserRegions 
 ,region is included which is in RIT now.
 But after completing MetaReader.getServerUserRegions, the region has been 
 opened in other server and is not in RIT now.
 In our testing environment where balancing,moving and killing are executed 
 periodly, assigning region twice often happens, and it is hateful because it 
 will affect other test cases.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HBASE-4899) Region would be assigned twice easily with continually killing server and moving region in testing environment

2011-11-30 Thread Hadoop QA (Commented) (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-4899?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13160611#comment-13160611
 ] 

Hadoop QA commented on HBASE-4899:
--

-1 overall.  Here are the results of testing the latest attachment 
  http://issues.apache.org/jira/secure/attachment/12505704/hbase-4899v3.patch
  against trunk revision .

+1 @author.  The patch does not contain any @author tags.

-1 tests included.  The patch doesn't appear to include any new or modified 
tests.
Please justify why no new tests are needed for this 
patch.
Also please list what manual steps were performed to 
verify this patch.

-1 javadoc.  The javadoc tool appears to have generated -160 warning 
messages.

+1 javac.  The applied patch does not increase the total number of javac 
compiler warnings.

-1 findbugs.  The patch appears to introduce 71 new Findbugs (version 
1.3.9) warnings.

+1 release audit.  The applied patch does not increase the total number of 
release audit warnings.

 -1 core tests.  The patch failed these unit tests:
   org.apache.hadoop.hbase.master.TestRollingRestart
  org.apache.hadoop.hbase.master.TestRestartCluster
  org.apache.hadoop.hbase.thrift2.TestThriftHBaseServiceHandler
  org.apache.hadoop.hbase.master.TestDistributedLogSplitting
  org.apache.hadoop.hbase.master.TestHMasterRPCException
  org.apache.hadoop.hbase.mapreduce.TestTimeRangeMapRed
  org.apache.hadoop.hbase.master.TestMaster
  
org.apache.hadoop.hbase.mapreduce.TestLoadIncrementalHFilesSplitRecovery
  
org.apache.hadoop.hbase.master.TestMasterRestartAfterDisablingTable
  org.apache.hadoop.hbase.TestDrainingServer
  org.apache.hadoop.hbase.mapreduce.TestTableInputFormatScan
  org.apache.hadoop.hbase.master.TestZKBasedOpenCloseRegion
  org.apache.hadoop.hbase.TestFullLogReconstruction
  org.apache.hadoop.hbase.avro.TestAvroServer
  org.apache.hadoop.hbase.mapreduce.TestLoadIncrementalHFiles
  org.apache.hadoop.hbase.master.TestMasterFailover
  org.apache.hadoop.hbase.mapreduce.TestImportTsv
  org.apache.hadoop.hbase.master.TestMasterTransitions
  org.apache.hadoop.hbase.mapreduce.TestHFileOutputFormat
  org.apache.hadoop.hbase.master.TestSplitLogManager
  org.apache.hadoop.hbase.master.TestOpenedRegionHandler

Test results: 
https://builds.apache.org/job/PreCommit-HBASE-Build/413//testReport/
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/413//artifact/trunk/patchprocess/newPatchFindbugsWarnings.html
Console output: https://builds.apache.org/job/PreCommit-HBASE-Build/413//console

This message is automatically generated.

 Region would be assigned twice easily with continually  killing server and 
 moving region in testing environment
 ---

 Key: HBASE-4899
 URL: https://issues.apache.org/jira/browse/HBASE-4899
 Project: HBase
  Issue Type: Bug
Affects Versions: 0.92.1
Reporter: chunhui shen
Assignee: chunhui shen
Priority: Critical
 Attachments: hbase-4899.patch, hbase-4899v2.patch, hbase-4899v3.patch


 Before assigning region in ServerShutdownHandler#process, it will check 
 whether region is in RIT,
 however, this checking doesn't work as the excepted in the following case:
 1.move region A from server B to server C
 2.kill server B
 3.start server B immediately
 Let's see what happen in the code for the above case
 {code}
 for step1:
 1.1 server B close the region A,
 1.2 master setOffline for region 
 A,(AssignmentManager#setOffline:this.regions.remove(regionInfo))
 1.3 server C start to open region A.(Not completed)
 for step3:
 master ServerShutdownHandler#process() for server B
 {
 ..
 splitlog()
 ...
 ListRegionState regionsInTransition =
 this.services.getAssignmentManager()
 .processServerShutdown(this.serverName);
 ...
 Skip regions that were in transition unless CLOSING or PENDING_CLOSE
 ...
 assign region
 }
 {code}
 In fact, when running 
 ServerShutdownHandler#process()#this.services.getAssignmentManager().processServerShutdown(this.serverName),
  region A is in RIT (step1.3 not completed), but the return ListRegionState 
 regionsInTransition doesn't contain it, because region A has removed from 
 AssignmentManager.regions by AssignmentManager#setOffline in step 1.2
 Therefore, region A will be assigned twice.
 Actually, one server killed and started twice will also easily 

[jira] [Commented] (HBASE-4899) Region would be assigned twice easily with continually killing server and moving region in testing environment

2011-11-30 Thread stack (Commented) (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-4899?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13160630#comment-13160630
 ] 

stack commented on HBASE-4899:
--

+1 on patch.

Running tests locally before commit.  The above failures shouldn't be because 
of this patch.

 Region would be assigned twice easily with continually  killing server and 
 moving region in testing environment
 ---

 Key: HBASE-4899
 URL: https://issues.apache.org/jira/browse/HBASE-4899
 Project: HBase
  Issue Type: Bug
Affects Versions: 0.92.1
Reporter: chunhui shen
Assignee: chunhui shen
Priority: Critical
 Attachments: hbase-4899.patch, hbase-4899v2.patch, hbase-4899v3.patch


 Before assigning region in ServerShutdownHandler#process, it will check 
 whether region is in RIT,
 however, this checking doesn't work as the excepted in the following case:
 1.move region A from server B to server C
 2.kill server B
 3.start server B immediately
 Let's see what happen in the code for the above case
 {code}
 for step1:
 1.1 server B close the region A,
 1.2 master setOffline for region 
 A,(AssignmentManager#setOffline:this.regions.remove(regionInfo))
 1.3 server C start to open region A.(Not completed)
 for step3:
 master ServerShutdownHandler#process() for server B
 {
 ..
 splitlog()
 ...
 ListRegionState regionsInTransition =
 this.services.getAssignmentManager()
 .processServerShutdown(this.serverName);
 ...
 Skip regions that were in transition unless CLOSING or PENDING_CLOSE
 ...
 assign region
 }
 {code}
 In fact, when running 
 ServerShutdownHandler#process()#this.services.getAssignmentManager().processServerShutdown(this.serverName),
  region A is in RIT (step1.3 not completed), but the return ListRegionState 
 regionsInTransition doesn't contain it, because region A has removed from 
 AssignmentManager.regions by AssignmentManager#setOffline in step 1.2
 Therefore, region A will be assigned twice.
 Actually, one server killed and started twice will also easily cause region 
 assigned twice.
 Exclude the above reason, another probability : 
 when execute ServerShutdownHandler#process()#MetaReader.getServerUserRegions 
 ,region is included which is in RIT now.
 But after completing MetaReader.getServerUserRegions, the region has been 
 opened in other server and is not in RIT now.
 In our testing environment where balancing,moving and killing are executed 
 periodly, assigning region twice often happens, and it is hateful because it 
 will affect other test cases.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HBASE-4899) Region would be assigned twice easily with continually killing server and moving region in testing environment

2011-11-30 Thread chunhui shen (Commented) (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-4899?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13160677#comment-13160677
 ] 

chunhui shen commented on HBASE-4899:
-

Testing result on my QA environment
{code}
Results :

Tests run: 1175, Failures: 0, Errors: 0, Skipped: 9

[INFO] 
[INFO] --- maven-surefire-plugin:2.11-TRUNK-HBASE-2:test 
(secondPartTestsExecution) @ hbase ---
[INFO] Tests are skipped.
[INFO] 
[INFO] BUILD SUCCESS
[INFO] 
[INFO] Total time: 1:44:10.984s
[INFO] Finished at: Thu Dec 01 14:10:34 CST 2011
[INFO] Final Memory: 35M/380M
[INFO] 
{code}

please check!

 Region would be assigned twice easily with continually  killing server and 
 moving region in testing environment
 ---

 Key: HBASE-4899
 URL: https://issues.apache.org/jira/browse/HBASE-4899
 Project: HBase
  Issue Type: Bug
Affects Versions: 0.92.1
Reporter: chunhui shen
Assignee: chunhui shen
Priority: Critical
 Attachments: hbase-4899.patch, hbase-4899v2.patch, hbase-4899v3.patch


 Before assigning region in ServerShutdownHandler#process, it will check 
 whether region is in RIT,
 however, this checking doesn't work as the excepted in the following case:
 1.move region A from server B to server C
 2.kill server B
 3.start server B immediately
 Let's see what happen in the code for the above case
 {code}
 for step1:
 1.1 server B close the region A,
 1.2 master setOffline for region 
 A,(AssignmentManager#setOffline:this.regions.remove(regionInfo))
 1.3 server C start to open region A.(Not completed)
 for step3:
 master ServerShutdownHandler#process() for server B
 {
 ..
 splitlog()
 ...
 ListRegionState regionsInTransition =
 this.services.getAssignmentManager()
 .processServerShutdown(this.serverName);
 ...
 Skip regions that were in transition unless CLOSING or PENDING_CLOSE
 ...
 assign region
 }
 {code}
 In fact, when running 
 ServerShutdownHandler#process()#this.services.getAssignmentManager().processServerShutdown(this.serverName),
  region A is in RIT (step1.3 not completed), but the return ListRegionState 
 regionsInTransition doesn't contain it, because region A has removed from 
 AssignmentManager.regions by AssignmentManager#setOffline in step 1.2
 Therefore, region A will be assigned twice.
 Actually, one server killed and started twice will also easily cause region 
 assigned twice.
 Exclude the above reason, another probability : 
 when execute ServerShutdownHandler#process()#MetaReader.getServerUserRegions 
 ,region is included which is in RIT now.
 But after completing MetaReader.getServerUserRegions, the region has been 
 opened in other server and is not in RIT now.
 In our testing environment where balancing,moving and killing are executed 
 periodly, assigning region twice often happens, and it is hateful because it 
 will affect other test cases.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HBASE-4899) Region would be assigned twice easily with continually killing server and moving region in testing environment

2011-11-29 Thread Ted Yu (Commented) (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-4899?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13159858#comment-13159858
 ] 

Ted Yu commented on HBASE-4899:
---

{code}
+  +  because it has been opened in 
+  + addressFromAM.getServerName());
{code}
We should use the value of rit (RegionState) in the above log instead of hard 
coding 'opened'.

 Region would be assigned twice easily with continually  killing server and 
 moving region in testing environment
 ---

 Key: HBASE-4899
 URL: https://issues.apache.org/jira/browse/HBASE-4899
 Project: HBase
  Issue Type: Bug
Affects Versions: 0.92.0
Reporter: chunhui shen
 Attachments: hbase-4899.patch


 Before assigning region in ServerShutdownHandler#process, it will check 
 whether region is in RIT,
 however, this checking doesn't work as the excepted in the following case:
 1.move region A from server B to server C
 2.kill server B
 3.start server B immediately
 Let's see what happen in the code for the above case
 {code}
 for step1:
 1.1 server B close the region A,
 1.2 master setOffline for region 
 A,(AssignmentManager#setOffline:this.regions.remove(regionInfo))
 1.3 server C start to open region A.(Not completed)
 for step3:
 master ServerShutdownHandler#process() for server B
 {
 ..
 splitlog()
 ...
 ListRegionState regionsInTransition =
 this.services.getAssignmentManager()
 .processServerShutdown(this.serverName);
 ...
 Skip regions that were in transition unless CLOSING or PENDING_CLOSE
 ...
 assign region
 }
 {code}
 In fact, when running 
 ServerShutdownHandler#process()#this.services.getAssignmentManager().processServerShutdown(this.serverName),
  region A is in RIT (step1.3 not completed), but the return ListRegionState 
 regionsInTransition doesn't contain it, because region A has removed from 
 AssignmentManager.regions by AssignmentManager#setOffline in step 1.2
 Therefore, region A will be assigned twice.
 Actually, one server killed and started twice will also easily cause region 
 assigned twice.
 Exclude the above reason, another probability : 
 when execute ServerShutdownHandler#process()#MetaReader.getServerUserRegions 
 ,region is included which is in RIT now.
 But after completing MetaReader.getServerUserRegions, the region has been 
 opened in other server and is not in RIT now.
 In our testing environment where balancing,moving and killing are executed 
 periodly, assigning region twice often happens, and it is hateful because it 
 will affect other test cases.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HBASE-4899) Region would be assigned twice easily with continually killing server and moving region in testing environment

2011-11-29 Thread Ted Yu (Commented) (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-4899?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13159859#comment-13159859
 ] 

Ted Yu commented on HBASE-4899:
---

@Chunhui:
Please let us know testing result on your QA environment.

 Region would be assigned twice easily with continually  killing server and 
 moving region in testing environment
 ---

 Key: HBASE-4899
 URL: https://issues.apache.org/jira/browse/HBASE-4899
 Project: HBase
  Issue Type: Bug
Affects Versions: 0.92.0
Reporter: chunhui shen
Assignee: chunhui shen
 Attachments: hbase-4899.patch


 Before assigning region in ServerShutdownHandler#process, it will check 
 whether region is in RIT,
 however, this checking doesn't work as the excepted in the following case:
 1.move region A from server B to server C
 2.kill server B
 3.start server B immediately
 Let's see what happen in the code for the above case
 {code}
 for step1:
 1.1 server B close the region A,
 1.2 master setOffline for region 
 A,(AssignmentManager#setOffline:this.regions.remove(regionInfo))
 1.3 server C start to open region A.(Not completed)
 for step3:
 master ServerShutdownHandler#process() for server B
 {
 ..
 splitlog()
 ...
 ListRegionState regionsInTransition =
 this.services.getAssignmentManager()
 .processServerShutdown(this.serverName);
 ...
 Skip regions that were in transition unless CLOSING or PENDING_CLOSE
 ...
 assign region
 }
 {code}
 In fact, when running 
 ServerShutdownHandler#process()#this.services.getAssignmentManager().processServerShutdown(this.serverName),
  region A is in RIT (step1.3 not completed), but the return ListRegionState 
 regionsInTransition doesn't contain it, because region A has removed from 
 AssignmentManager.regions by AssignmentManager#setOffline in step 1.2
 Therefore, region A will be assigned twice.
 Actually, one server killed and started twice will also easily cause region 
 assigned twice.
 Exclude the above reason, another probability : 
 when execute ServerShutdownHandler#process()#MetaReader.getServerUserRegions 
 ,region is included which is in RIT now.
 But after completing MetaReader.getServerUserRegions, the region has been 
 opened in other server and is not in RIT now.
 In our testing environment where balancing,moving and killing are executed 
 periodly, assigning region twice often happens, and it is hateful because it 
 will affect other test cases.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HBASE-4899) Region would be assigned twice easily with continually killing server and moving region in testing environment

2011-11-29 Thread Hadoop QA (Commented) (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-4899?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13159881#comment-13159881
 ] 

Hadoop QA commented on HBASE-4899:
--

-1 overall.  Here are the results of testing the latest attachment 
  http://issues.apache.org/jira/secure/attachment/12505580/hbase-4899.patch
  against trunk revision .

+1 @author.  The patch does not contain any @author tags.

-1 tests included.  The patch doesn't appear to include any new or modified 
tests.
Please justify why no new tests are needed for this 
patch.
Also please list what manual steps were performed to 
verify this patch.

-1 javadoc.  The javadoc tool appears to have generated -162 warning 
messages.

+1 javac.  The applied patch does not increase the total number of javac 
compiler warnings.

-1 findbugs.  The patch appears to introduce 67 new Findbugs (version 
1.3.9) warnings.

+1 release audit.  The applied patch does not increase the total number of 
release audit warnings.

 -1 core tests.  The patch failed these unit tests:
   org.apache.hadoop.hbase.TestFullLogReconstruction
  org.apache.hadoop.hbase.mapreduce.TestImportTsv

Test results: 
https://builds.apache.org/job/PreCommit-HBASE-Build/406//testReport/
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/406//artifact/trunk/patchprocess/newPatchFindbugsWarnings.html
Console output: https://builds.apache.org/job/PreCommit-HBASE-Build/406//console

This message is automatically generated.

 Region would be assigned twice easily with continually  killing server and 
 moving region in testing environment
 ---

 Key: HBASE-4899
 URL: https://issues.apache.org/jira/browse/HBASE-4899
 Project: HBase
  Issue Type: Bug
Affects Versions: 0.92.0
Reporter: chunhui shen
Assignee: chunhui shen
 Attachments: hbase-4899.patch


 Before assigning region in ServerShutdownHandler#process, it will check 
 whether region is in RIT,
 however, this checking doesn't work as the excepted in the following case:
 1.move region A from server B to server C
 2.kill server B
 3.start server B immediately
 Let's see what happen in the code for the above case
 {code}
 for step1:
 1.1 server B close the region A,
 1.2 master setOffline for region 
 A,(AssignmentManager#setOffline:this.regions.remove(regionInfo))
 1.3 server C start to open region A.(Not completed)
 for step3:
 master ServerShutdownHandler#process() for server B
 {
 ..
 splitlog()
 ...
 ListRegionState regionsInTransition =
 this.services.getAssignmentManager()
 .processServerShutdown(this.serverName);
 ...
 Skip regions that were in transition unless CLOSING or PENDING_CLOSE
 ...
 assign region
 }
 {code}
 In fact, when running 
 ServerShutdownHandler#process()#this.services.getAssignmentManager().processServerShutdown(this.serverName),
  region A is in RIT (step1.3 not completed), but the return ListRegionState 
 regionsInTransition doesn't contain it, because region A has removed from 
 AssignmentManager.regions by AssignmentManager#setOffline in step 1.2
 Therefore, region A will be assigned twice.
 Actually, one server killed and started twice will also easily cause region 
 assigned twice.
 Exclude the above reason, another probability : 
 when execute ServerShutdownHandler#process()#MetaReader.getServerUserRegions 
 ,region is included which is in RIT now.
 But after completing MetaReader.getServerUserRegions, the region has been 
 opened in other server and is not in RIT now.
 In our testing environment where balancing,moving and killing are executed 
 periodly, assigning region twice often happens, and it is hateful because it 
 will affect other test cases.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira