You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hbase.apache.org by st...@apache.org on 2009/03/25 12:30:06 UTC
svn commit: r758227 - in /hadoop/hbase/trunk: CHANGES.txt
src/java/org/apache/hadoop/hbase/master/TableDelete.java
Author: stack
Date: Wed Mar 25 11:30:01 2009
New Revision: 758227
URL: http://svn.apache.org/viewvc?rev=758227&view=rev
Log:
HBASE-1284 drop table drops all disabled tables
Modified:
hadoop/hbase/trunk/CHANGES.txt
hadoop/hbase/trunk/src/java/org/apache/hadoop/hbase/master/TableDelete.java
Modified: hadoop/hbase/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/hbase/trunk/CHANGES.txt?rev=758227&r1=758226&r2=758227&view=diff
==============================================================================
--- hadoop/hbase/trunk/CHANGES.txt (original)
+++ hadoop/hbase/trunk/CHANGES.txt Wed Mar 25 11:30:01 2009
@@ -58,6 +58,7 @@
HBASE-1274 TestMergeTable is broken in Hudson (Nitay Joffe via Stack)
HBASE-1283 thrift's package descrpition needs to update for start/stop
procedure (Rong-en Fan via Stack)
+ HBASE-1284 drop table drops all disabled tables
IMPROVEMENTS
HBASE-1089 Add count of regions on filesystem to master UI; add percentage
Modified: hadoop/hbase/trunk/src/java/org/apache/hadoop/hbase/master/TableDelete.java
URL: http://svn.apache.org/viewvc/hadoop/hbase/trunk/src/java/org/apache/hadoop/hbase/master/TableDelete.java?rev=758227&r1=758226&r2=758227&view=diff
==============================================================================
--- hadoop/hbase/trunk/src/java/org/apache/hadoop/hbase/master/TableDelete.java (original)
+++ hadoop/hbase/trunk/src/java/org/apache/hadoop/hbase/master/TableDelete.java Wed Mar 25 11:30:01 2009
@@ -44,7 +44,6 @@
@Override
protected void processScanItem(String serverName,
final HRegionInfo info) throws IOException {
-
if (isEnabled(info)) {
throw new TableNotDisabledException(tableName);
}
@@ -54,6 +53,10 @@
protected void postProcessMeta(MetaRegion m, HRegionInterface server)
throws IOException {
for (HRegionInfo i: unservedRegions) {
+ if (!Bytes.equals(this.tableName, i.getTableDesc().getName())) {
+ // Don't delete regions that are not from our table.
+ continue;
+ }
// Delete the region
try {
HRegion.removeRegionFromMETA(server, m.getRegionName(), i.getRegionName());