flink-user-zh mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "1035262083" <1035262...@qq.com>
Subject 回复:Flink 1.10读取kafka数据,打包jar,提交任务到集群运行测试,遇到java.lang.NoClassDefFoundError: org/apache/flink/streaming/connectors/kafka/FlinkKafkaConsumerBase问题,求救大神帮忙解答,谢谢!
Date Mon, 13 Apr 2020 06:33:52 GMT
你应该还缺少flink-connector-elasticsearch-base_2.11-1.10.0.jar



------------------&nbsp;原始邮件&nbsp;------------------
发件人: "wangweiguang@stevegame.cn"<wangweiguang@stevegame.cn&gt;; 
发送时间: 2020年4月13日(星期一) 下午2:31
收件人: "user-zh"<user-zh@flink.apache.org&gt;; 
主题: Flink 1.10读取kafka数据,打包jar,提交任务到集群运行测试,遇到java.lang.NoClassDefFoundError:
org/apache/flink/streaming/connectors/kafka/FlinkKafkaConsumerBase问题,求救大神帮忙解答,谢谢!





你好:


&nbsp; &nbsp; 我在用Flink 1.10读取kafka数据,本地IDEA环境执行没有问题,将代码编译打包(不是fat
jar)到集群上运行测试,执行提示:java.lang.NoClassDefFoundError: org/apache/flink/streaming/connectors/kafka/FlinkKafkaConsumerBase问题。
&nbsp; &nbsp; 我在Flink 1.10集群的每个节点下的 /lib下都添加了kafka依赖包:flink-connector-kafka_2.11-1.10.0.jar
&nbsp; &nbsp; 我启动的命令:
&nbsp; &nbsp; 我先启动了一个Yarn session:
&nbsp; &nbsp; yarn-session.sh -yd -jm 2048m -tm 2048m -s 10
&nbsp; &nbsp; 然后在session提交任务测试
&nbsp; &nbsp; flink run -d -p 2 -m yarn-cluster -c com.sdf.flink.streaming.BroadcastOrderJoinGoodsName
-yid application_1585277813790_0006 ./flink-project_1.10.0-1.0.jar
&nbsp; &nbsp; 启动就报如下错误:
&nbsp; &nbsp;


/lib下的依赖包:



代码片段:

 

就是简单的读取数据,输出测试!



 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 













史蒂夫软件(深圳)有限公司
技术部 &nbsp; 王卫光
wangweiguang@stevegame.cn&nbsp;
地址/Add:深圳南山科区科技园高新南十二道康佳研发大厦A座
手机/Mob:13128970998
http://www.stevengame.com/
Mime
  • Unnamed multipart/alternative (inline, 8-Bit, 0 bytes)
View raw message