我用doucmentation创建了这个示例程序https://ci.apache.org/projects/flink/flink-docs-release-0.8/programming_guide.html#introduction
在ide中运行时出现以下错误
log4j:WARN No appenders could be found for logger (org.apache.flink.api.scala.ClosureCleaner$).
log4j:WARN Please initialize the log4j system properly.
log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info.
Exception in thread "main" java.lang.RuntimeException: An error occurred while loading the local executor (org.apache.flink.client.LocalExecutor).
at org.apache.flink.api.common.PlanExecutor.createLocalExecutor(PlanExecutor.java:161)
at org.apache.flink.api.java.LocalEnvironment.startNewSession(LocalEnvironment.java:122)
at org.apache.flink.api.java.LocalEnvironment.execute(LocalEnvironment.java:81)
at org.apache.flink.api.java.ExecutionEnvironment.execute(ExecutionEnvironment.java:855)
at org.apache.flink.api.java.DataSet.collect(DataSet.java:410)
at org.apache.flink.api.java.DataSet.print(DataSet.java:1605)
at org.apache.flink.api.scala.DataSet.print(DataSet.scala:1615)
at com.sc.edl.flink.ingestion$.main(ingestion.scala:27)
at com.sc.edl.flink.ingestion.main(ingestion.scala)
Caused by: java.lang.NoSuchMethodException: org.apache.flink.client.LocalExecutor.<init>(org.apache.flink.configuration.Configuration)
at java.lang.Class.getConstructor0(Class.java:3082)
at java.lang.Class.getConstructor(Class.java:1825)
at org.apache.flink.api.common.PlanExecutor.createLocalExecutor(PlanExecutor.java:158)
有人能告诉我怎么了吗。
提前谢谢
1条答案
按热度按时间4xrmg8kj1#
该文档页适用于版本0.8。使用更新版本(1.1.2是最新版本)重试。
无论如何,这个问题可能与您在eclipse中使用的类路径有关。您需要从eclipse中修改它并使用
assembly
我相信。在最新版本中,右模块被称为mainRunner
.