You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hbase.apache.org by ra...@apache.org on 2012/01/12 18:40:00 UTC
svn commit: r1230660 - in /hbase/branches/0.90: CHANGES.txt
src/main/java/org/apache/hadoop/hbase/regionserver/PriorityCompactionQueue.java
Author: ramkrishna
Date: Thu Jan 12 17:39:59 2012
New Revision: 1230660
URL: http://svn.apache.org/viewvc?rev=1230660&view=rev
Log:
HBASE-5178 Backport HBASE-4101 - Regionserver Deadlock (Ram)
Modified:
hbase/branches/0.90/CHANGES.txt
hbase/branches/0.90/src/main/java/org/apache/hadoop/hbase/regionserver/PriorityCompactionQueue.java
Modified: hbase/branches/0.90/CHANGES.txt
URL: http://svn.apache.org/viewvc/hbase/branches/0.90/CHANGES.txt?rev=1230660&r1=1230659&r2=1230660&view=diff
==============================================================================
--- hbase/branches/0.90/CHANGES.txt (original)
+++ hbase/branches/0.90/CHANGES.txt Thu Jan 12 17:39:59 2012
@@ -159,6 +159,7 @@ Release 0.90.5 - Dec 22, 2011
completes, may cause data loss (Ram)
HBASE-5158 Backport HBASE-4878 - Master crash when splitting hlog may cause data loss (Ram)
HBASE-5168 Backport HBASE-5100 - Rollback of split could cause closed region to be opened again(Ram)
+ HBASE-5178 Backport HBASE-4101 - Regionserver Deadlock (Ram)
NEW FEATURE
HBASE-4377 [hbck] Offline rebuild .META. from fs data only
@@ -238,7 +239,6 @@ Release 0.90.4 - August 10, 2011
HBASE-4112 Creating table may throw NullPointerException (Jinchao via Ted Yu)
HBASE-4093 When verifyAndAssignRoot throws exception, the deadServers state cannot
be changed (fulin wang via Ted Yu)
- HBASE-4101 Regionserver Deadlock (ramkrishna.s.vasudevan)
HBASE-3872 Hole in split transaction rollback; edits to .META. need to be rolled
back even if it seems like they didn't make it
HBASE-4115 HBase shell assign and unassign unusable if region name includes
Modified: hbase/branches/0.90/src/main/java/org/apache/hadoop/hbase/regionserver/PriorityCompactionQueue.java
URL: http://svn.apache.org/viewvc/hbase/branches/0.90/src/main/java/org/apache/hadoop/hbase/regionserver/PriorityCompactionQueue.java?rev=1230660&r1=1230659&r2=1230660&view=diff
==============================================================================
--- hbase/branches/0.90/src/main/java/org/apache/hadoop/hbase/regionserver/PriorityCompactionQueue.java (original)
+++ hbase/branches/0.90/src/main/java/org/apache/hadoop/hbase/regionserver/PriorityCompactionQueue.java Thu Jan 12 17:39:59 2012
@@ -47,24 +47,24 @@ public class PriorityCompactionQueue imp
private class CompactionRequest implements Comparable<CompactionRequest> {
private final HRegion r;
private final int p;
- private final Date date;
+ private final Long timeInNanos;
public CompactionRequest(HRegion r, int p) {
this(r, p, null);
}
- public CompactionRequest(HRegion r, int p, Date d) {
+ public CompactionRequest(HRegion r, int p, Long time) {
if (r == null) {
throw new NullPointerException("HRegion cannot be null");
}
- if (d == null) {
- d = new Date();
+ if (time == null) {
+ time = System.nanoTime();
}
this.r = r;
this.p = p;
- this.date = d;
+ this.timeInNanos = time;
}
/**
@@ -90,8 +90,8 @@ public class PriorityCompactionQueue imp
if (compareVal != 0) {
return compareVal;
}
-
- compareVal = date.compareTo(request.date);
+
+ compareVal = timeInNanos.compareTo(request.timeInNanos);
if (compareVal != 0) {
return compareVal;
}
@@ -112,7 +112,7 @@ public class PriorityCompactionQueue imp
public String toString() {
return "regionName=" + r.getRegionNameAsString() +
- ", priority=" + p + ", date=" + date;
+ ", priority=" + p + ", time=" + timeInNanos;
}
}