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.43.tar.gz
(17.3 kB
view details)
Built Distribution
File details
Details for the file airflow-commons-0.0.43.tar.gz
.
File metadata
- Download URL: airflow-commons-0.0.43.tar.gz
- Upload date:
- Size: 17.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.7.1 importlib_metadata/4.8.2 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 820cf209f0e0d26840956da95bebd2bcd83a8f59442266f327c164b010ec8776 |
|
MD5 | 930ba878b1d237a388f1af6397b9bdca |
|
BLAKE2b-256 | 6323919ec17612f0e9b0e17621bed10450b8e593615ed879fc24705f9579a9ea |
File details
Details for the file airflow_commons-0.0.43-py3-none-any.whl
.
File metadata
- Download URL: airflow_commons-0.0.43-py3-none-any.whl
- Upload date:
- Size: 25.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.7.1 importlib_metadata/4.8.2 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6687937ee6f256a823fb219460867163e0a759d55d62c1360ae43ebac73c8878 |
|
MD5 | 88184f433ddcda6f29cbe5eef5a7ab74 |
|
BLAKE2b-256 | 5779ba23e4a0e63cd7c145977091a1925f28e3c1126786df63533d817d64021d |