Spark结构化流-数据写入不一致

时间:2018-12-03 15:52:45

标签: apache-spark spark-structured-streaming

以下数据帧必须以Json格式编写。但是有时它会跳过写一些记录。

newDF
 .select(to_json( struct( "*" ) )  as "messages")
 .writeStream.format("json")
 .option("path", "/home/abc/Work/files/stream/messageJSON/")
 .option("checkpointLocation","/home/abc/Work/files/stream/checkPoint/")
 .trigger(Trigger.ProcessingTime(30000))
 .start().awaitTermination()

为什么不习惯?代码或检查点是否存在任何问题? Spark版本-2.2.2

0 个答案:

没有答案
相关问题