import argparse
import logging
import sys
from pyflink.common import WatermarkStrategy, Encoder, Types
from pyflink.datastream import StreamExecutionEnvironment, RuntimeExecutionMode
from pyflink.datastream.connectors.file_system import FileSource, StreamFormat, FileSink, OutputFileConfig, RollingPolicy
env = StreamExecutionEnvironment.get_execution_environment()
env.set_runtime_mode(RuntimeExecutionMode.BATCH)
# write all the data to one file
env.set_parallelism(1)
ds = env.from_source(
source=FileSource.for_record_stream_format(StreamFormat.text_line_format(),
'./test.csv')
.process_static_file_set().build(),
watermark_strategy=WatermarkStrategy.for_monotonous_timestamps(),
source_name="aaaa"
)
ds.print()
env.execute()
pyflink 读取excel
scan7242024-05-01 13:07
相关推荐
LOVE️YOU28 分钟前
Python 中 Tuple 为什么有时可 Hash,有时不可 Hash?小oo呆41 分钟前
【学习心得】迭代器和可迭代对象AC赳赳老秦1 小时前
采集行为合规自检:OpenClaw 自动校验 robots 协议与采集频率,规避违规采集风险迅猛龙办公室1 小时前
Python输出当前计算机的系统日期和时间XiaoMaqqqq3 小时前
知名的IP驱动产业新场景新工具言乐63 小时前
Python实现语音审核模型程序员清风4 小时前
Python 数据分析环境搭建:从 Jupyter 到 pandas月光船幽幽4 小时前
加性偏移外推提升参数识别可靠性BD_Marathon4 小时前
消息对象中字段的说明Java后端的Ai之路5 小时前
Python进阶探索23 - Python中的Time与Datetime模块