Here is the exception stack

Exception in thread "main" java.lang.NoSuchMethodError:
com.google.common.util.concurrent.Service.addListener(Lcom/google/common/util/concurrent/Service$Listener;Ljava/util/concurrent/Executor;)V
    at
org.apache.twill.internal.AbstractExecutionServiceController.start(AbstractExecutionServiceController.java:65)
    at
org.apache.twill.yarn.YarnTwillPreparer.start(YarnTwillPreparer.java:314)
    at org.apache.twill.example.yarn.HelloWorld.main(HelloWorld.java:65)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:606)
    at org.apache.hadoop.util.RunJar.main(RunJar.java:212)


I ran the example app with the command line below
 yarn jar  twill-examples-yarn-0.3.0-incubating-SNAPSHOT.jar
org.apache.twill.example.yarn.HelloWorld zk1:2181,zk2:2181,zk3:2181


The yarn has its own classpath, that include a guava with version 11.0.2.
Twill example build a fat jar with guava 13.0.1 inside. But seems the
classloader chose the older one. There is a collision.

How do you guys solve this kind of problem? Did you have came across that
when you running the yarn example?


Thanks,
Min



-- 
My research interests are distributed systems, parallel computing and
bytecode based virtual machine.

My profile:
http://www.linkedin.com/in/coderplay
My blog:
http://coderplay.javaeye.com

Reply via email to