2019年11月13日

airflow_failover启动scheduler

摘要: 参考: https://github.com/teamclairvoyant/airflow-scheduler-failover-controller 1.stop failover2.stop scheduler3.clear failover meta4.start failover #启动m 阅读全文

posted @ 2019-11-13 16:49 锋锋2019 阅读(642) 评论(0) 推荐(0) 编辑

实例一 airflow_failover

摘要: 源码: https://github.com/teamclairvoyant/airflow-scheduler-failover-controller #怎么判断scheduler是running的, is_scheduler_running https://github.com/teamclai 阅读全文

posted @ 2019-11-13 16:10 锋锋2019 阅读(314) 评论(0) 推荐(0) 编辑

装饰器

摘要: 装饰器:又叫包装函数 作用: 1. 添加说明,提醒等. 2. 添加登,验证陆装饰器 原理是在执行student时会把student作为deco的参数传到deco中执行,student函数在deco的子函数wrapper中做为参数被执行.(即在装饰器的装饰下执行函数) def deco(func): 阅读全文

posted @ 2019-11-13 15:56 锋锋2019 阅读(76) 评论(0) 推荐(0) 编辑

面向对象

摘要: 面向过程:根据业务逻辑从上到下垒代码,所有的事都需要自己去处理. 引入函数,避免可重复使用代码.面向函数: 将某功能代码封装到函数中,以后直接调用,不需要再次编写 面向对象:先要写一个类, 对函数进行分类和封装,类里可以有很多函数,让开发“更快更好更强...” 像Java和C++等编程语言仅支持面向 阅读全文

posted @ 2019-11-13 15:24 锋锋2019 阅读(104) 评论(0) 推荐(0) 编辑

for循环

摘要: for var in .... statement statement else: statement 例子:注意range(5)是5次循环,range(0,5)是5次循环,range(1,5)是4次循环, for i in range(5): print (i) else: print ("the 阅读全文

posted @ 2019-11-13 15:17 锋锋2019 阅读(117) 评论(0) 推荐(0) 编辑

if---else

摘要: if x= =A: do something for A elif x = = B: do something for B else: do something for else python没有分支结构case, 用多个elif来实现分支。 例子: AGE = 56 guess_age = int 阅读全文

posted @ 2019-11-13 15:13 锋锋2019 阅读(993) 评论(0) 推荐(0) 编辑

airflow的web任务管理

摘要: ariflow里绿的代表都跑完了:红的表示有问题:点红的图标进去: 点tree view 红色表示那一天失败: 点进去看可以看log: 点clear则是重跑任务: 阅读全文

posted @ 2019-11-13 11:16 锋锋2019 阅读(597) 评论(0) 推荐(0) 编辑

airflow原理

摘要: 官网: http://airflow.apache.org/installation.html 原理: https://www.cnblogs.com/cord/p/9450910.html 原理介绍: DAG:有向无环图,有方向但没有循环 airflow 的守护进程airflow 系统在运行时有许 阅读全文

posted @ 2019-11-13 10:52 锋锋2019 阅读(1513) 评论(0) 推荐(0) 编辑

导航