![](https://img-blog.csdnimg.cn/20201014180756925.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
airflow
文章平均质量分 59
@zhangxingle
这个作者很懒,什么都没留下…
展开
-
airflow 2.2.1:HdfsSensor使用实操
概述 HdfsSensor主要用于检查hdfs文件或目录是否存在 实操 案例描述: 目前需要在airflow中增加一个任务,用于检测hdfs中的目标文件是否存在。文件绝对路径:/user/hdfs/for_test_2022-05-12.parquet 代码如下 from airflow import DAG from datetime import datetime, timedelta from airflow.providers.apache.hdfs.sensors.hdfs import Hd原创 2022-05-12 20:16:59 · 704 阅读 · 0 评论 -
airflow 2.2.1:HivePartitionSensor、自定义宏变量
airflow 2.21:HivePartitionSensor HivePartitionSensor功能 用于检查hive表的分区是否存在,在某些场景下可以使用该sensor来替代ExternalTaskSensor,且使用起来更加便捷。 场景描述 在数仓中这么两种表: 表1 :daily_table,该表是按天分区的表,一天跑一次。 表2 :hour_table,该表是按照小时分区,每个小时跑一次。 其中daily_table 依赖于 hour_table的执行,对于这种执行周期不同的任务,如果通过a原创 2021-12-31 19:48:59 · 2028 阅读 · 1 评论