• Stars
    star
    132
  • Rank 268,327 (Top 6 %)
  • Language
    Python
  • License
    Apache License 2.0
  • Created almost 7 years ago
  • Updated 9 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Airflow declarative DAGs via YAML

airflow-declarative

Airflow declarative DAGs via YAML.

Compatibility:

  • Python 2.7 / 3.5+
  • Airflow 1.10.4+

Key Features

  • Declarative DAGs in plain text YAML helps a lot to understand how DAG will looks like. Made for humans, not programmers.
  • It makes extremely hard to turn your DAGs into code mess. Even if you make complicated YAMLs generator the result would be readable for humans.
  • No more guilty about coupling business logic with task management system (Airflow). They now could coexists separated.
  • Static analysis becomes a trivial task.
  • It's a good abstraction to create your own scheduler/worker compatible with original Airflow one.

Examples

Check tests/dags directory for example of DAGs which will works and which won't. Use src/airflow_declarative/schema.py module for the reference about YAML file schema. It should be self descriptive.

Don't be shy to experiment: trafaret-config will help you to understand what had gone wrong and why and where.

Usage

We provide support for two installation options:

  1. As a complementary side package for the upstream Airflow.
  2. As a built-in Airflow functionality using patches for Airflow.

Upstream Airflow

The idea is to put a Python script to the dags_folder which would load the declarative dags via airflow_declarative. More details: Installation using Upstream Airflow.

import os

import airflow_declarative

# Assuming that the yaml dags are located in the same directory
# as this Python module:
root = os.path.dirname(__file__)

dags_list = [
    airflow_declarative.from_path(os.path.join(root, item))
    for item in os.listdir(root)
    if item.endswith((".yml", ".yaml"))
]

globals().update({dag.dag_id: dag for dags in dags_list for dag in dags})

Patched Airflow

We provide ready to use patches in the patches directory. To use them you will need to apply a patch to a corresponding Airflow version and then build it yourself. More details: Installation using Patched Airflow.

More Repositories

1

rambler-it-ios

open source VIPER application
Objective-C
334
star
2

swipe-layout-android

Android UI widget
Java
320
star
3

rambler-ui

😈 UI library for creating interfaces in Rambler guidelines with React power
JavaScript
191
star
4

ViperMcFlurry

As tasty as McFlurry is
Objective-C
171
star
5

criteo-1tb-benchmark

Benchmark of different ML algorithms on Criteo 1TB dataset
Jupyter Notebook
144
star
6

actix-web-validator

Rust library for providing validation mechanism to actix-web with Validator crate.
Rust
93
star
7

hydrogen

More faster and convenient Doctrine ORM abstraction layer
PHP
85
star
8

rambler-webpack-boilerplate

Webpack (dev-server) Testem Mocha Chai
JavaScript
60
star
9

scaraplate

Scaraplate is a wrapper around cookiecutter which allows to repeatedly rollup project templates onto concrete projects.
Python
58
star
10

rusby

Ruby to Rust method transpiler
Ruby
34
star
11

RamblerTyphoonUtils

one love
Objective-C
28
star
12

rship

Rocket Ship – node.js tool for developing and building isomorphic web applications
JavaScript
26
star
13

aioriak

Python asyncio client for Riak
Erlang
26
star
14

RamblerSegues

Embed segue and Cross Storyboard segues library.
Shell
24
star
15

fastlane-flows

deliver it smoothly
Ruby
20
star
16

webpack-pipeline

Ruby
20
star
17

frontend

Информация о внутренних встречах frontend разработчиков
13
star
18

dashramba

the ultimate dashboard
JavaScript
12
star
19

raconfig

C++ header-only library for comfortable program configuration handling
C++
10
star
20

RambagramPageControl

UIPageControl replacement
Objective-C
10
star
21

actix-cache

Actix cache is a proxy actor and infrastructure for asynchronous and clear cache interaction for Actix actor and Actix-web frameworks.
Rust
9
star
22

video-ad-sdk

VAST/VPAID SDK that allows video ads to be played on top of any player
TypeScript
8
star
23

fish0

Rambler Site Fish patterns
Ruby
8
star
24

rspec-visual

Gem for "visual" testing with rspec via screenshot comparison.
Ruby
8
star
25

dotfiles

Rambler&Co Dotfiles for your javascripts
JavaScript
7
star
26

rambler-it-android

Android client for it.rambler-co.ru
7
star
27

magic-transport

Transport for communication between iframe and parent window
TypeScript
6
star
28

viralligator

Elixir
6
star
29

tracing-syslog

Support for tracing events natively to syslog, preserving structured information
Rust
5
star
30

render-react

Renders React.js components into your Ruby views
JavaScript
5
star
31

reflexio

Business flow manager
TypeScript
5
star
32

widgetly

Library that helps you to create widgets, including widgets that work via an iframe
TypeScript
5
star
33

cbr_currencies

Ruby gem for retrieving currencies data from CentroBank
Ruby
4
star
34

Rambler-Rate-Android

Java
4
star
35

foosball-api

Backend for the foosball champ app
3
star
36

thrustmq

Plain Golang message queue designed for speed, durability & simplicity
Go
3
star
37

lopataJs

Various tools for jqueryless development
JavaScript
3
star
38

danger-spec_postfix

Ruby
2
star
39

JRF

JSON-RPC Framework
PHP
2
star
40

unity-utils

Ruby
1
star
41

release_dove

Ruby gem that helps visualizing changelog.md
Ruby
1
star
42

backend

Информация о внутренних мероприятиях для backend разработчиков
1
star
43

java-webhdfs

Hadoop WebHDFS API client java library
Java
1
star
44

licenselint

A linter for NPM package licenses to avoid dependencies that not compatible with license of your software
TypeScript
1
star
45

rds-content-banners

Rambler digital solutions скрипт для расстановки рекламы внутри тела топика.
HTML
1
star