Support Questions

Find answers, ask questions, and share your expertise

java.lang.NoSuchMethodError: twitter4j.FilterQuery.setIncludeEntities(Z)Ltwitter4j/FilterQuery - flume

avatar
Contributor

Dear, I have the following configuration flume already have used it before and it worked: (also Add the flume-sources-1.0-SNAPSHOT jar in the directory of jars flume)

config-flume.png

The only thing that changed was update to version 1.5.2.2.4 flume and is giving me the following error.

ERROR [lifecycleSupervisor-1-2] (org.apache.flume.lifecycle.LifecycleSupervisor$MonitorRunnable.run:253) - Unable to start EventDrivenSourceRunner: { source:com.cloudera.flume.source.TwitterSource{name:Twitter,state:IDLE} } - Exception follows. java.lang.NoSuchMethodError: twitter4j.FilterQuery.setIncludeEntities(Z)Ltwitter4j/FilterQuery; at com.cloudera.flume.source.TwitterSource.start(TwitterSource.java:139) at org.apache.flume.source.EventDrivenSourceRunner.start(EventDrivenSourceRunner.java:44) at org.apache.flume.lifecycle.LifecycleSupervisor$MonitorRunnable.run(LifecycleSupervisor.java:251) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308) at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180) at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745)

Please your help if someone has the same error. Thank you

1 ACCEPTED SOLUTION

avatar
Super Guru

This seems to be an issue due to more than one jar version available for a same class, one of that jar class doesn't have mentioned method in it therefore causing this issue.

Please make sure you have correct version of jar available in flume lib.

View solution in original post

7 REPLIES 7

avatar
Super Guru

This seems to be an issue due to more than one jar version available for a same class, one of that jar class doesn't have mentioned method in it therefore causing this issue.

Please make sure you have correct version of jar available in flume lib.

avatar
Rising Star

Your suggestion helped me to over come a fortnight problem .Thanks a ton !!!

avatar
Super Guru

Thanks @karthik sai, Please accept the answer to close this thread.

avatar
New Contributor

Could you please tell me what changes have you made. I am also getting same problem.

avatar
Super Collaborator

twitter4j jars included to Flume libs by default. However, twitter source from cloudera is built with another version of twitter4j framework.

I'd recommend to remove all *twitter4j* jars from flume_home/libs folder and add proper version (mentioned in cloudera's source pom) to aux_lib instead (along with custom source)

avatar
New Contributor

Hi i am getting same error but not getting solution can you please help me to get rid from there

avatar
Community Manager

@PriyalPotnis as this is an older post, you would have a better chance of receiving a resolution by starting a new thread. This will also be an opportunity to provide details specific to your environment that could aid others in assisting you with a more accurate answer to your question. You can link this thread as a reference in your new post.



Regards,

Vidya Sargur,
Community Manager


Was your question answered? Make sure to mark the answer as the accepted solution.
If you find a reply useful, say thanks by clicking on the thumbs up button.
Learn more about the Cloudera Community: