HBASE-2089 HBaseConfiguration() ctor. deprecated
git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@895916 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
e2f7f90e00
commit
5e65d6ee2f
@ -285,6 +285,7 @@ Release 0.21.0 - Unreleased
|
|||||||
HBASE-1996 Configure scanner buffer in bytes instead of number of rows
|
HBASE-1996 Configure scanner buffer in bytes instead of number of rows
|
||||||
(Erik Rozendaal and Dave Latham via Stack)
|
(Erik Rozendaal and Dave Latham via Stack)
|
||||||
HBASE-2090 findbugs issues (Kay Kay via Stack)
|
HBASE-2090 findbugs issues (Kay Kay via Stack)
|
||||||
|
HBASE-2089 HBaseConfiguration() ctor. deprecated (Kay Kay via Stack)
|
||||||
|
|
||||||
NEW FEATURES
|
NEW FEATURES
|
||||||
HBASE-1901 "General" partitioner for "hbase-48" bulk (behind the api, write
|
HBASE-1901 "General" partitioner for "hbase-48" bulk (behind the api, write
|
||||||
|
@ -63,7 +63,7 @@ public class HBaseTestingUtility {
|
|||||||
|
|
||||||
private final Log LOG = LogFactory.getLog(getClass());
|
private final Log LOG = LogFactory.getLog(getClass());
|
||||||
|
|
||||||
private final HBaseConfiguration conf = new HBaseConfiguration();
|
private final Configuration conf = HBaseConfiguration.create();
|
||||||
private MiniZooKeeperCluster zkCluster = null;
|
private MiniZooKeeperCluster zkCluster = null;
|
||||||
private MiniDFSCluster dfsCluster = null;
|
private MiniDFSCluster dfsCluster = null;
|
||||||
private MiniHBaseCluster hbaseCluster = null;
|
private MiniHBaseCluster hbaseCluster = null;
|
||||||
@ -76,9 +76,9 @@ public class HBaseTestingUtility {
|
|||||||
public static final String TEST_DIRECTORY_KEY = "test.build.data";
|
public static final String TEST_DIRECTORY_KEY = "test.build.data";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return Instance of HBaseConfiguration.
|
* @return Instance of Configuration.
|
||||||
*/
|
*/
|
||||||
public HBaseConfiguration getConfiguration() {
|
public Configuration getConfiguration() {
|
||||||
return this.conf;
|
return this.conf;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -351,7 +351,7 @@ public class HBaseTestingUtility {
|
|||||||
Bytes.toBytes("xxx"), Bytes.toBytes("yyy")
|
Bytes.toBytes("xxx"), Bytes.toBytes("yyy")
|
||||||
};
|
};
|
||||||
|
|
||||||
HBaseConfiguration c = getConfiguration();
|
Configuration c = getConfiguration();
|
||||||
HTable meta = new HTable(c, HConstants.META_TABLE_NAME);
|
HTable meta = new HTable(c, HConstants.META_TABLE_NAME);
|
||||||
HTableDescriptor htd = table.getTableDescriptor();
|
HTableDescriptor htd = table.getTableDescriptor();
|
||||||
if(!htd.hasFamily(columnFamily)) {
|
if(!htd.hasFamily(columnFamily)) {
|
||||||
|
@ -26,6 +26,7 @@ import java.util.List;
|
|||||||
import org.apache.commons.logging.Log;
|
import org.apache.commons.logging.Log;
|
||||||
import org.apache.commons.logging.LogFactory;
|
import org.apache.commons.logging.LogFactory;
|
||||||
|
|
||||||
|
import org.apache.hadoop.conf.Configuration;
|
||||||
import org.apache.hadoop.hbase.client.HConnectionManager;
|
import org.apache.hadoop.hbase.client.HConnectionManager;
|
||||||
import org.apache.hadoop.hbase.master.HMaster;
|
import org.apache.hadoop.hbase.master.HMaster;
|
||||||
import org.apache.hadoop.hbase.regionserver.HRegionServer;
|
import org.apache.hadoop.hbase.regionserver.HRegionServer;
|
||||||
@ -40,7 +41,7 @@ import org.apache.hadoop.hbase.regionserver.HRegion;
|
|||||||
*/
|
*/
|
||||||
public class MiniHBaseCluster implements HConstants {
|
public class MiniHBaseCluster implements HConstants {
|
||||||
static final Log LOG = LogFactory.getLog(MiniHBaseCluster.class.getName());
|
static final Log LOG = LogFactory.getLog(MiniHBaseCluster.class.getName());
|
||||||
private HBaseConfiguration conf;
|
private Configuration conf;
|
||||||
public LocalHBaseCluster hbaseCluster;
|
public LocalHBaseCluster hbaseCluster;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -49,7 +50,7 @@ public class MiniHBaseCluster implements HConstants {
|
|||||||
* @param numRegionServers initial number of region servers to start.
|
* @param numRegionServers initial number of region servers to start.
|
||||||
* @throws IOException
|
* @throws IOException
|
||||||
*/
|
*/
|
||||||
public MiniHBaseCluster(HBaseConfiguration conf, int numRegionServers)
|
public MiniHBaseCluster(Configuration conf, int numRegionServers)
|
||||||
throws IOException {
|
throws IOException {
|
||||||
this.conf = conf;
|
this.conf = conf;
|
||||||
init(numRegionServers);
|
init(numRegionServers);
|
||||||
|
@ -22,6 +22,7 @@ package org.apache.hadoop.hbase;
|
|||||||
|
|
||||||
import org.apache.commons.logging.Log;
|
import org.apache.commons.logging.Log;
|
||||||
import org.apache.commons.logging.LogFactory;
|
import org.apache.commons.logging.LogFactory;
|
||||||
|
import org.apache.hadoop.conf.Configuration;
|
||||||
import org.apache.hadoop.hbase.client.HTable;
|
import org.apache.hadoop.hbase.client.HTable;
|
||||||
import org.apache.hadoop.hbase.client.Result;
|
import org.apache.hadoop.hbase.client.Result;
|
||||||
import org.apache.hadoop.hbase.client.ResultScanner;
|
import org.apache.hadoop.hbase.client.ResultScanner;
|
||||||
@ -38,7 +39,7 @@ public class TestFullLogReconstruction {
|
|||||||
private final static byte[] TABLE_NAME = Bytes.toBytes("tabletest");
|
private final static byte[] TABLE_NAME = Bytes.toBytes("tabletest");
|
||||||
private final static byte[] FAMILY = Bytes.toBytes("family");
|
private final static byte[] FAMILY = Bytes.toBytes("family");
|
||||||
|
|
||||||
private HBaseConfiguration conf;
|
private Configuration conf;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @throws java.lang.Exception
|
* @throws java.lang.Exception
|
||||||
|
@ -19,6 +19,7 @@
|
|||||||
*/
|
*/
|
||||||
package org.apache.hadoop.hbase;
|
package org.apache.hadoop.hbase;
|
||||||
|
|
||||||
|
import org.apache.hadoop.conf.Configuration;
|
||||||
import org.apache.hadoop.hbase.client.*;
|
import org.apache.hadoop.hbase.client.*;
|
||||||
import org.apache.hadoop.hbase.util.Bytes;
|
import org.apache.hadoop.hbase.util.Bytes;
|
||||||
import org.apache.hadoop.hbase.zookeeper.ZooKeeperWrapper;
|
import org.apache.hadoop.hbase.zookeeper.ZooKeeperWrapper;
|
||||||
@ -34,7 +35,7 @@ public class TestZooKeeper {
|
|||||||
private final static HBaseTestingUtility
|
private final static HBaseTestingUtility
|
||||||
TEST_UTIL = new HBaseTestingUtility();
|
TEST_UTIL = new HBaseTestingUtility();
|
||||||
|
|
||||||
private HBaseConfiguration conf;
|
private Configuration conf;
|
||||||
private MiniHBaseCluster cluster;
|
private MiniHBaseCluster cluster;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -33,6 +33,7 @@ import java.util.UUID;
|
|||||||
|
|
||||||
import org.apache.commons.logging.Log;
|
import org.apache.commons.logging.Log;
|
||||||
import org.apache.commons.logging.LogFactory;
|
import org.apache.commons.logging.LogFactory;
|
||||||
|
import org.apache.hadoop.conf.Configuration;
|
||||||
import org.apache.hadoop.hbase.HBaseConfiguration;
|
import org.apache.hadoop.hbase.HBaseConfiguration;
|
||||||
import org.apache.hadoop.hbase.HBaseTestingUtility;
|
import org.apache.hadoop.hbase.HBaseTestingUtility;
|
||||||
import org.apache.hadoop.hbase.HColumnDescriptor;
|
import org.apache.hadoop.hbase.HColumnDescriptor;
|
||||||
@ -403,7 +404,7 @@ public class TestFromClientSide {
|
|||||||
@Test
|
@Test
|
||||||
public void testMaxKeyValueSize() throws Exception {
|
public void testMaxKeyValueSize() throws Exception {
|
||||||
byte [] TABLE = Bytes.toBytes("testMaxKeyValueSize");
|
byte [] TABLE = Bytes.toBytes("testMaxKeyValueSize");
|
||||||
HBaseConfiguration conf = TEST_UTIL.getConfiguration();
|
Configuration conf = TEST_UTIL.getConfiguration();
|
||||||
String oldMaxSize = conf.get("hbase.client.keyvalue.maxsize");
|
String oldMaxSize = conf.get("hbase.client.keyvalue.maxsize");
|
||||||
HTable ht = TEST_UTIL.createTable(TABLE, FAMILY);
|
HTable ht = TEST_UTIL.createTable(TABLE, FAMILY);
|
||||||
byte[] value = new byte[4 * 1024 * 1024];
|
byte[] value = new byte[4 * 1024 * 1024];
|
||||||
|
@ -19,6 +19,7 @@
|
|||||||
*/
|
*/
|
||||||
package org.apache.hadoop.hbase.regionserver;
|
package org.apache.hadoop.hbase.regionserver;
|
||||||
|
|
||||||
|
import org.apache.hadoop.conf.Configuration;
|
||||||
import org.apache.hadoop.fs.Path;
|
import org.apache.hadoop.fs.Path;
|
||||||
import org.apache.hadoop.hbase.*;
|
import org.apache.hadoop.hbase.*;
|
||||||
import org.apache.hadoop.hbase.client.Get;
|
import org.apache.hadoop.hbase.client.Get;
|
||||||
@ -42,7 +43,7 @@ public class TestStoreReconstruction {
|
|||||||
private MiniDFSCluster cluster;
|
private MiniDFSCluster cluster;
|
||||||
private static final String TABLE = "testtable";
|
private static final String TABLE = "testtable";
|
||||||
private static final int TOTAL_EDITS = 10000;
|
private static final int TOTAL_EDITS = 10000;
|
||||||
private HBaseConfiguration conf;
|
private Configuration conf;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @throws java.lang.Exception
|
* @throws java.lang.Exception
|
||||||
|
Loading…
x
Reference in New Issue
Block a user