当前位置:网站首页>Flink学习6:编程模型
Flink学习6:编程模型
2022-07-04 03:47:00 【hzp666】

1.接口分层
Flink提供了不同级别的接口,最底层的是状态数据流处理,最高层是SQL

1.1 状态数据流处理
通过过程函数,被继承到DataStream API中

有状态数据流处理接口,
1.2 DataStream 和 DataSet API
核心API
DataStream 用来处理有界 和 无界数据流。
DataSet API 用来处理有界 数据流。
该接口提供了大量的通用组件

另外,
DataStream 集成更底层的函数
DataSet API 对有界数据提供了额外的支持

1.3 Table API
1.以表为中心,类似关系型数据库的二维表

2.提供可比较的操作,select, group by等

3.Table API 可以自定义函数进行扩展,但在表达能力上,比不上核心API。(不过Table API代码更简洁)
4.Table API是指定程序应该执行哪些操作,而不是精确的指定程序的执行步骤
5.Table API 在执行前会进行优化,另外Table API 和 DataStream , DataSet 之间可以无缝切换。所以在程序中可以混合只用。
1.4 SQL
Flink最高级封装接口就是 flink SQL
语法和表达能力上和Table API 类似,唯一的区别就是通过使用SQL查询语言实现程序。
SQL查询和Table API 交互密切,SQL可以直接在Table API中创建的表上查询

边栏推荐
猜你喜欢

How about the ratings of 2022 Spring Festival Gala in all provinces? Map analysis helps you show clearly!

1289_ Implementation analysis of vtask suspend() interface in FreeRTOS

Tcpclientdemo for TCP protocol interaction

三菱M70宏变量读取三菱M80公共变量采集三菱CNC变量读取采集三菱CNC远程刀补三菱机床在线刀补三菱数控在线测量

Audio and video technology development weekly | 232

拼夕夕二面:说说布隆过滤器与布谷鸟过滤器?应用场景?我懵了。。

渗透实战-guest账户-mimikatz-向日葵-sql提权-离线解密

Getting started with the go language is simple: go implements the Caesar password

MySQL maxscale realizes read-write separation

Management and thesis of job management system based on SSM
随机推荐
I Build a simple microservice project
My opinion on how to effectively telecommute | community essay solicitation
Wechat official account web page authorization
Smart subway | cloud computing injects wisdom into urban subway transportation
Idea configuration 360zip open by default -- external tools
LNK2038 检测到“RuntimeLibrary”的不匹配项: 值“MD_DynamicRelease”不匹配值“MDd_DynamicDebug”(main.obj 中)
JVM family -- monitoring tools
图解网络:什么是热备份路由器协议HSRP?
还原窗口位置的微妙之处
Detailed explanation of PPTC self recovery fuse
Database SQL statement summary, continuous update
Katalon框架测试web(二十六)自动发邮件
[paddleseg source code reading] paddleseg custom data class
Objective-C description method and type method
[PaddleSeg 源码阅读] PaddleSeg 自定义数据类
Recursive structure
Why is the probability of pod increasing after IPtable
深度优先搜索简要讲解(附带基础题)
Third party login initial version
Getting started with the go language is simple: go implements the Caesar password