0

YCSB を実行しているときに、次のエラーが発生します。YCSB git ハブ リンクで指定されたすべての手順に従いましたが、それでもこのエラーが発生します

Exception in thread "Thread-3" java.lang.NoSuchMethodError: org.slf4j.impl.StaticLoggerBinder.getSingleton()Lorg/slf4j/impl/StaticLoggerBinder;
    at org.slf4j.LoggerFactory.bind(LoggerFactory.java:128)
    at org.slf4j.LoggerFactory.performInitialization(LoggerFactory.java:108)
    at org.slf4j.LoggerFactory.getILoggerFactory(LoggerFactory.java:279)
    at org.slf4j.LoggerFactory.getLogger(LoggerFactory.java:252)
    at org.slf4j.LoggerFactory.getLogger(LoggerFactory.java:265)
    at org.apache.zookeeper.ZooKeeper.<clinit>(ZooKeeper.java:93)
    at org.apache.hadoop.hbase.zookeeper.RecoverableZooKeeper.<init>(RecoverableZooKeeper.java:92)
    at org.apache.hadoop.hbase.zookeeper.ZKUtil.connect(ZKUtil.java:107)
    at org.apache.hadoop.hbase.zookeeper.ZooKeeperWatcher.<init>(ZooKeeperWatcher.java:157)
    at org.apache.hadoop.hbase.zookeeper.ZooKeeperWatcher.<init>(ZooKeeperWatcher.java:131)
    at org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.getZooKeeperWatcher(HConnectionManager.java:1341)
    at org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.ensureZookeeperTrackers(HConnectionManager.java:584)
    at org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.locateRegion(HConnectionManager.java:846)
    at org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.locateRegion(HConnectionManager.java:821)
    at org.apache.hadoop.hbase.client.HTable.finishSetup(HTable.java:234)
    at org.apache.hadoop.hbase.client.HTable.<init>(HTable.java:174)
    at org.apache.hadoop.hbase.client.HTable.<init>(HTable.java:133)
    at com.yahoo.ycsb.db.HBaseClient.getHTable(HBaseClient.java:118)
    at com.yahoo.ycsb.db.HBaseClient.update(HBaseClient.java:302)
    at com.yahoo.ycsb.db.HBaseClient.insert(HBaseClient.java:357)
    at com.yahoo.ycsb.DBWrapper.insert(DBWrapper.java:148)
    at com.yahoo.ycsb.workloads.CoreWorkload.doInsert(CoreWorkload.java:461)
    at com.yahoo.ycsb.ClientThread.run(Client.java:269)
Exception in thread "Thread-1" java.lang.NoClassDefFoundError: Could not initialize class org.apache.zookeeper.ZooKeeper
    at org.apache.hadoop.hbase.zookeeper.RecoverableZooKeeper.<init>(RecoverableZooKeeper.java:92)
    at org.apache.hadoop.hbase.zookeeper.ZKUtil.connect(ZKUtil.java:107)
    at org.apache.hadoop.hbase.zookeeper.ZooKeeperWatcher.<init>(ZooKeeperWatcher.java:157)
    at org.apache.hadoop.hbase.zookeeper.ZooKeeperWatcher.<init>(ZooKeeperWatcher.java:131)
    at org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.getZooKeeperWatcher(HConnectionManager.java:1341)
    at org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.ensureZookeeperTrackers(HConnectionManager.java:584)
    at org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.locateRegion(HConnectionManager.java:846)
    at org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.locateRegion(HConnectionManager.java:821)
    at org.apache.hadoop.hbase.client.HTable.finishSetup(HTable.java:234)
    at org.apache.hadoop.hbase.client.HTable.<init>(HTable.java:174)
    at org.apache.hadoop.hbase.client.HTable.<init>(HTable.java:133)
    at com.yahoo.ycsb.db.HBaseClient.getHTable(HBaseClient.java:118)
    at com.yahoo.ycsb.db.HBaseClient.update(HBaseClient.java:302)
    at com.yahoo.ycsb.db.HBaseClient.insert(HBaseClient.java:357)
    at com.yahoo.ycsb.DBWrapper.insert(DBWrapper.java:148)
    at com.yahoo.ycsb.workloads.CoreWorkload.doInsert(CoreWorkload.java:461)
    at com.yahoo.ycsb.ClientThread.run(Client.java:269)

私の動物園の飼育係は問題なく動いています... なぜそうなっているのでしょうか? 誰でもこれについて私を助けることができます

4

1 に答える 1

0

依存関係の問題です。例外は、このメソッドが見つからないことを示しています。

org.slf4j.impl.StaticLoggerBinder.getSingleton()Lorg/slf4j/impl/StaticLoggerBinder;
//specifically 
getSingleton()

メソッドを含むクラスは静的にインポートされるためNoClassDefFoundError、最上位レベルで a をスローする代わりに (後でスタック トレースでスローされることがわかります)、NoSuchMethodError例外がスローされます。

slf4jjar をクラスパスに追加する必要があります。

于 2013-05-22T08:06:47.800 に答える