hbase-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Eric Charles <e...@apache.org>
Subject MiniDFSCluster configuration via spring
Date Sat, 08 Oct 2011 12:26:41 GMT

We use HBaseTestingUtility to create a MiniHBaseCluster to test Apache 
James mailbox project. One of the deployment option is Spring, in that 
case, the wiring/injection is done via xml file.

We began instanciating the MiniHBaseCluster in the test class before 
loading the spring context for configuration with
<bean id="hbase-conf" class="org.apache.hadoop.hbase.HBaseConfiguration" 
factory-method="create" />

This gave us org.apache.hadoop.hbase.ZooKeeperConnectionException: HBase 
is able to connect to ZooKeeper but the connection closes immediately. 
This could be a sign that the server has too many connections (30 is the 

I defined in a hbase-site.xml on the classpath a few zookeeper 
properties (host, port, number of connections...) without more success.

The fallback solution is to let spring create everything (see [1] for 
the wiring). This works but is not what we want.

My questions are:

1. What is needed to launch a MiniDFSCluster in a process, and let 
another process build/create a configuration 'compatible' with that 
MiniHBaseCluster? Do I have to define any property in hbase-site.xml?

2. Is the given exception relevant/correct? If I read it, I conclude 
zookeeper is up, reachable, but has too many connections...




View raw message