当前位置:网站首页>自适应批作业调度器:为 Flink 批作业自动推导并行度
自适应批作业调度器:为 Flink 批作业自动推导并行度
2022-07-13 17:27:00 【罗伯特之技术屋】
01引言
对大部分用户来说,为 Flink 算子配置合适的并行度并不是一件容易的事。对于批作业,小的并行度会导致作业运行时间长,故障恢复慢,而不必要的大并行度会导致资源浪费,任务部署和数据 shuffle 开销也会变大。
为了控制批作业的执行时长,算子的并行度应该和其需要处理的数据量成正比。用户需要通过预估算子需要处理的数据量来配置并行度。但准确预估算子需要处理的数据量是一件很困难的事情:需要处理的数据量可能每天都在变化,作业中可能会存在大量的 UDF 和复杂算子导致难以判断其产出的数据量。
为了解决这个问题,我们在 Flink 1.15 中引入了一种新的调度器:自适应批作业调度器(Adaptive Batch Scheduler)。自适应批作业调度器会在作业运行时根据每个算子需要处理的实际数据量来自动推导并行度。它会带来以下好处:
大大降低批处理作业并发度调优的繁琐程度;
可以根据处理的数据量为不同的算子配置不同的并行度,这对于之前只能配置全局并行度的 SQL 作业尤其有益;
可以更好的适应每日变化的数据量。
02用法
使 Flink 自动推导算子的并行度,需要进行以下配置:
启用自适应批作业调度器;
配置算子的并行度为 -1。
2.1 启用自适应批作业调度器
启用自适应批作业调度器&#x
边栏推荐
猜你喜欢

1252. 奇数值单元格的数目 : 简单计数模拟题

ABAP Bapi copy the standard project template to achieve project initiation

测试如何发挥更大价值?聊聊测试左移和测试右移

水墨云怎么样?

Quickly teach you how to build a data-driven automated testing framework?

LeNet5、AlexNet、VGGNet、ResNet

目标检测

【探究为什么String类是不可变类型:String类仿写】

Fiddler and Charles intercept and modify requests and return values

Brother bird talks about cloud native security best practices | book at the end of the article
随机推荐
fenxi
分布式单体的六大病症
Brother bird talks about cloud native security best practices | book at the end of the article
C3D的使用
激活函数
opencv的实战学习之信用卡识别(四)
QT project summary record
如何编写有效的接口测试?
目标检测
See how Google uses pre training weights in target detection tasks | CVPR 2022
驾照科目一常考知识点
[regression prediction LSTM] LSTM implementation based on attention mechanism regression prediction of time series with matlab code
mysql中all用法和any的用法和内连接和外连接,全外连接,联合查询,自连接
C language comprehensive training - address book (using dynamic memory)
如何編寫有效的接口測試?
Mysql-MVCC
动态规划-LeetCode509.斐波那契数
At 19:00 p.m. on Thursday, the third live broadcast of knowledge empowerment - control panel function realization of openharmony smart home project
[explore why string class is an immutable type: String class imitation]
yandex bot user agent