Skip to main content

Apache Airflow provider for Datris — trigger and monitor Datris taps from DAGs.

Project description

airflow-provider-datris

An Apache Airflow provider for Datris. Airflow orchestrates; Datris executes. This package ships an operator that triggers a Datris tap, waits for the resulting pipeline to reach a terminal state, streams Datris logs into the Airflow task log, and pushes run tokens and metrics back as XComs.

No execution moves into Airflow — it only triggers and observes.

Requirements

  • Apache Airflow 3.x
  • A reachable Datris server (minimum version: the current Datris release at the time this provider was published)

Install

pip install airflow-provider-datris

Configure a connection

Add a connection of type Datris:

Field Value
Host Datris base URL, e.g. https://datris.example.com
Password API key (x-api-key) — only if the install requires one
Extra {"verify": true, "timeout": 30} (optional)

The API key is optional: leave it blank for a local single-tenant install with useApiKeys=false. For a hosted/multi-tenant install, use a key that holds the tap:run capability for the taps you trigger. A key scoped tap:run:owner=self can only run taps it created.

Usage

from datris_provider.operators import DatrisRunTapOperator

ingest = DatrisRunTapOperator(
    task_id="ingest_customers",
    tap_name="customers_pg_to_snowflake",
    datris_conn_id="datris_default",
    wait_for_completion=True,
    poll_interval=15,
    tap_params={"since": "{{ ds }}"},  # optional per-run params (env vars in the tap)
)

Behavior

  • Triggers the tap via POST /tap/run (mode=run).
  • Polls GET /pipeline/status?publishertoken=…&withrollup=true to a terminal rollup, streaming Datris log events into the task log.
  • Pushes publisher_token, pipeline_tokens, row_count, and duration_ms as XComs (the operator's return value).
  • A debounced trigger (status=skipped, persistedReason=debounced) is treated as success-with-warning.
  • On Airflow task kill/timeout, calls POST /job/kill for the in-flight jobs.

Tip: avoid double-firing

If a tap is driven by Airflow, mark it externally scheduled in Datris so the built-in scheduler doesn't also fire it.

Development

pip install -e ".[dev]"
pytest

License

Apache-2.0. The Datris engine itself is licensed separately (AGPL-3.0).

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

airflow_provider_datris-0.1.2.tar.gz (12.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

airflow_provider_datris-0.1.2-py3-none-any.whl (12.4 kB view details)

Uploaded Python 3

File details

Details for the file airflow_provider_datris-0.1.2.tar.gz.

File metadata

  • Download URL: airflow_provider_datris-0.1.2.tar.gz
  • Upload date:
  • Size: 12.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for airflow_provider_datris-0.1.2.tar.gz
Algorithm Hash digest
SHA256 3973b875ea7659ad0f87ec248e9ec49602a9bae6532c210092c5496c46f9123b
MD5 17279ba3dd0ce6c28411dee62bc923a3
BLAKE2b-256 fcccb4cf1c73bced33237dc26f3affe3d4830c194a4c17608bc84cd2e0666ffa

See more details on using hashes here.

Provenance

The following attestation bundles were made for airflow_provider_datris-0.1.2.tar.gz:

Publisher: release.yml on datris/airflow-provider-datris

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file airflow_provider_datris-0.1.2-py3-none-any.whl.

File metadata

File hashes

Hashes for airflow_provider_datris-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 c70ab9951f3c864042a2f91c011d6ac50ccaae0c16e5dc7fb29a4bd86fb7b978
MD5 65c71e0088bdf2f5b9b7e6ef0bae233a
BLAKE2b-256 6e22cd7c075e4fa4c45ce0f94222484a2f68bdfd6202ae9e2ff58770bb849cd7

See more details on using hashes here.

Provenance

The following attestation bundles were made for airflow_provider_datris-0.1.2-py3-none-any.whl:

Publisher: release.yml on datris/airflow-provider-datris

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page