java.lang.NoSuchMethodError: com.google.common.collect.Maps.newConcurrentMap()?
share_i 提问于:2017-05-19
0 0

google-collections-1.0.jar 包是存在的
错误:

严重: com.google.common.collect.Maps.newConcurrentMap()Ljava/util/concurrent/ConcurrentMap;
java.lang.NoSuchMethodError: com.google.common.collect.Maps.newConcurrentMap()Ljava/util/concurrent/ConcurrentMap;
    at org.apache.curator.framework.listen.ListenerContainer.<init>(ListenerContainer.java:35)
    at org.apache.curator.framework.imps.CuratorFrameworkImpl.<init>(CuratorFrameworkImpl.java:110)
    at org.apache.curator.framework.CuratorFrameworkFactory$Builder.build(CuratorFrameworkFactory.java:124)
  • 所有回答
kill_bug 回答于:2017-06-04
2 0

可是是jar包冲突了

查看下你的lib中是不是同时存在:

guava-xx.jar
google-collections-xx.jar

删除google-collections-xx.jar试下!

我来回答    java.lang.NoSuchMethodError: com.google.common.collect.Maps.newConcurrentMap()?