hbase-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From st...@apache.org
Subject svn commit: r921097 - /hadoop/hbase/branches/0.20/src/java/org/apache/hadoop/hbase/regionserver/HRegion.java
Date Tue, 09 Mar 2010 20:20:14 GMT
Author: stack
Date: Tue Mar  9 20:20:13 2010
New Revision: 921097

URL: http://svn.apache.org/viewvc?rev=921097&view=rev
Log:
HBASE-2295 Row locks may deadlock with themselves

Modified:
    hadoop/hbase/branches/0.20/src/java/org/apache/hadoop/hbase/regionserver/HRegion.java

Modified: hadoop/hbase/branches/0.20/src/java/org/apache/hadoop/hbase/regionserver/HRegion.java
URL: http://svn.apache.org/viewvc/hadoop/hbase/branches/0.20/src/java/org/apache/hadoop/hbase/regionserver/HRegion.java?rev=921097&r1=921096&r2=921097&view=diff
==============================================================================
--- hadoop/hbase/branches/0.20/src/java/org/apache/hadoop/hbase/regionserver/HRegion.java
(original)
+++ hadoop/hbase/branches/0.20/src/java/org/apache/hadoop/hbase/regionserver/HRegion.java
Tue Mar  9 20:20:13 2010
@@ -1724,8 +1724,10 @@ public class HRegion implements HConstan
   
   private void waitOnRowLocks() {
     synchronized (lockedRows) {
-      while (this.lockedRows.size() > 0) {
-        LOG.debug("waiting for " + this.lockedRows.size() + " row locks");
+      while (!this.lockedRows.isEmpty()) {
+        if (LOG.isDebugEnabled()) {
+          LOG.debug("Waiting on " + this.lockedRows.size() + " row locks");
+        } 
         try {
           this.lockedRows.wait();
         } catch (InterruptedException e) {



Mime
View raw message