Common functions for airflow
Project description
airflow-commons
A python package that contains common functionalities for airflow
Installation
Use the package manager pip to install airflow-commons.
pip install airflow-commons
Modules
- bigquery_operator: With this module you can manage your Google BigQuery operations.
- mysql_operator: Using this module, you can connect to your MySQL data source and manage your data operations.
- s3_operator: This operator connects to your s3 bucket and lets you manage your bucket.
- glossary: This module consists of constants used across project
- sql_resources: Template BigQuery and MySQL queries such as merge, delete, select etc. are located here.
- utils: Generic methods like connection, querying etc. are implemented in this module.
Usage
- Sample deduplication code works like:
from airflow_commons import bigquery_operator
bigquery_operator.deduplicate(
service_account_file="path_to_file",
start_date="01-01-2020 14:00:00",
end_date="01-01-2020 15:00:00",
project_id="bigquery_project_id",
source_dataset="source_dataset",
source_table="source_table",
target_dataset="target_dataset",
target_table="target_table",
oldest_allowable_target_partition="01-01-2015 00:00:00",
primary_keys=["primary_keys"],
time_columns=["time_columns"],
allow_partition_pruning=True,
)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
airflow-commons-0.0.18.tar.gz
(15.3 kB
view details)
Built Distribution
File details
Details for the file airflow-commons-0.0.18.tar.gz
.
File metadata
- Download URL: airflow-commons-0.0.18.tar.gz
- Upload date:
- Size: 15.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.0 CPython/3.9.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | f76dd30260e51c32b1f3b681b3b1bdf5d7bf8117d2643c6c687c8397b19c0a96 |
|
MD5 | 6437edb934d9040f4752fa2835b3668a |
|
BLAKE2b-256 | be66370ff1ea9c1b2b60a55e28f49f6c6df426a0ff9a318f38303b6729d7109f |
File details
Details for the file airflow_commons-0.0.18-py3-none-any.whl
.
File metadata
- Download URL: airflow_commons-0.0.18-py3-none-any.whl
- Upload date:
- Size: 22.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.0 CPython/3.9.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | a42a634207d3dee8ff04d2ad14d37f391c1a8f102a48a7b8a283a095d75b7aee |
|
MD5 | 9ec059ec7e50f021ff3a4d359ebb933e |
|
BLAKE2b-256 | ade65ff4df4af57c1334b76305ef08f7afc02fe45496f1b086e61fd444b610b2 |