我在我的应用程序中使用 Hbase-Hadoop 组合以及作为 ORM 的 Data Nucleus。
当我试图一次通过多个线程访问 hbase 时。它抛出异常为:
Exception in thread "Thread-26" javax.jdo.JDODataStoreException
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 default). Consider inspecting your ZK server logs for that error and then make sure you are reusing HBaseConfiguration as often as you can. See HTable's javadoc for more information.
Caused by: org.apache.zookeeper.KeeperException$ConnectionLossException: KeeperErrorCode = ConnectionLoss for /hbase
如果需要,我可以提供完整的堆栈跟踪。(因为完整的堆栈跟踪会使这里的事情变得一团糟)。
请帮助我提供一些有关如何处理这种情况的线索。我需要做任何配置来增加连接池吗?