From 4e080fcbbbb40a1fb29a70758fe762455388e277 Mon Sep 17 00:00:00 2001 From: Michael Stack Date: Fri, 14 May 2010 05:30:02 +0000 Subject: [PATCH] HBASE-2546 Specify default filesystem in both the new and old way (needed if we are to run on 0.20 and 0.21 hadoop) git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@944115 13f79535-47bb-0310-9956-ffa450edef68 --- CHANGES.txt | 2 ++ core/src/main/java/org/apache/hadoop/hbase/master/HMaster.java | 3 +++ 2 files changed, 5 insertions(+) diff --git a/CHANGES.txt b/CHANGES.txt index 05f422def50..df085e7b5d7 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -309,6 +309,8 @@ Release 0.21.0 - Unreleased getting permanently offlined HBASE-2515 ChangeTableState considers split&&offline regions as being served HBASE-2544 Forward port branch 0.20 WAL to TRUNK + HBASE-2546 Specify default filesystem in both the new and old way (needed + if we are to run on 0.20 and 0.21 hadoop) IMPROVEMENTS HBASE-1760 Cleanup TODOs in HTable diff --git a/core/src/main/java/org/apache/hadoop/hbase/master/HMaster.java b/core/src/main/java/org/apache/hadoop/hbase/master/HMaster.java index d0d83cc098f..c15374d6b7c 100644 --- a/core/src/main/java/org/apache/hadoop/hbase/master/HMaster.java +++ b/core/src/main/java/org/apache/hadoop/hbase/master/HMaster.java @@ -165,6 +165,9 @@ public class HMaster extends Thread implements HConstants, HMasterInterface, // default localfs. Presumption is that rootdir is fully-qualified before // we get to here with appropriate fs scheme. this.rootdir = FSUtils.getRootDir(this.conf); + // Cover both bases, the old way of setting default fs and the new. + // We're supposed to run on 0.20 and 0.21 anyways. + this.conf.set("fs.default.name", this.rootdir.toString()); this.conf.set("fs.defaultFS", this.rootdir.toString()); this.fs = FileSystem.get(this.conf); checkRootDir(this.rootdir, this.conf, this.fs);