Skip to content

Add Apache Arrow provider#52330

Open
dabla wants to merge 235 commits into
apache:mainfrom
dabla:feature/apache-arrow-provider
Open

Add Apache Arrow provider#52330
dabla wants to merge 235 commits into
apache:mainfrom
dabla:feature/apache-arrow-provider

Conversation

@dabla

@dabla dabla commented Jun 27, 2025

Copy link
Copy Markdown
Contributor

Apache Arrow provider (apache-airflow-providers-apache-arrow)

Adds a new Airflow provider backed by Apache Arrow and the
Arrow Database Connectivity (ADBC) standard.

What's included

AdbcHook

A general-purpose DbApiHook subclass that connects to any ADBC-compatible database via the
adbc-driver-manager. It exposes the full Airflow SQL hook surface (get_records, run,
insert_rows, …) while internally operating on Arrow RecordBatch objects for zero-copy,
columnar data transfer.

Key capabilities:

  • Arrow-native insertsinsert_rows converts rows to Arrow RecordBatch objects and
    uses the cursor's native bind API when available, falling back to executemany otherwise.
  • Chunked bulk loading — rows are committed in configurable chunks (commit_every) to
    bound transaction size and lock duration.
  • Dynamic driver discovery — the driver shared library is located automatically from the
    installed wheel; the entrypoint can also be overridden via connection extras.
  • Dialect-aware — SQL placeholder style is normalised per-dialect before execution.
  • Connection extrasdriver, entrypoint, db_kwargs, conn_kwargs, and dialect
    are all configurable from the Airflow connection UI without code changes.

Supported databases (via optional extras)

Extra Driver package
sqlite adbc-driver-sqlite
postgresql adbc-driver-postgresql
snowflake adbc-driver-snowflake
bigquery adbc-driver-bigquery
flightsql adbc-driver-flightsql

Installation

# Core provider only
pip install apache-airflow-providers-apache-arrow

# With a specific driver
pip install "apache-airflow-providers-apache-arrow[postgresql]"

# With all bundled drivers
pip install "apache-airflow-providers-apache-arrow[all]"

Requirements

  • apache-airflow >= 2.11.0
  • apache-airflow-providers-common-sql >= 1.28.2
  • adbc-driver-manager >= 1.7.0
  • pyarrow >= 16.1.0 (Python < 3.13) / >= 18.0.0 (Python ≥ 3.13)
  • more-itertools >= 9.0.0

Link to the discussion thread on the devlist: https://lists.apache.org/thread/v1nxnr5gocvzs12pknjxkw64mrtpg2o0


^ Add meaningful description above
Read the Pull Request Guidelines for more information.
In case of fundamental code changes, an Airflow Improvement Proposal (AIP) is needed.
In case of a new dependency, check compliance with the ASF 3rd Party License Policy.
In case of backwards incompatible changes please leave a note in a newsfragment file, named {pr_number}.significant.rst or {issue_number}.significant.rst, in airflow-core/newsfragments.

@potiuk potiuk marked this pull request as draft June 27, 2025 11:12
@potiuk

potiuk commented Jun 27, 2025

Copy link
Copy Markdown
Member

Just for anyone looking here - this is a draft for discussion between me, @dabla and @zeroshade - we will still need to start a DISCUSSION thread for the new provider - and we think Arrow and ADBC is a good addition. But we have to first discuss the approach :)

Comment thread providers/apache/arrow/docs/connections/adbc.rst Outdated
Comment thread providers/apache/arrow/README.rst
Comment thread providers/apache/arrow/README.rst
Comment thread providers/apache/arrow/pyproject.toml Outdated
Comment thread providers/apache/arrow/pyproject.toml Outdated
Comment thread providers/apache/arrow/src/airflow/providers/apache/arrow/hooks/adbc.py Outdated
Comment thread providers/apache/arrow/src/airflow/providers/apache/arrow/hooks/adbc.py Outdated
Comment thread providers/apache/arrow/src/airflow/providers/apache/arrow/hooks/adbc.py Outdated
Comment thread providers/apache/arrow/tests/unit/apache/arrow/hooks/test_adbc.py
@vikramkoka

Copy link
Copy Markdown
Contributor

As @potiuk mentioned, I believe this needs a devlist conversation first.
Looking forward to it

@potiuk

potiuk commented Jun 28, 2025

Copy link
Copy Markdown
Member

As @potiuk mentioned, I believe this needs a devlist conversation first. Looking forward to it

Yep. This one is mostly to gather learnigs, get feedback from @zeroshade and see how we can turn it into a "convincing" devlist proposal - by showing some use cases and small POC of implementation and what it allows :).

We'll experiment a bit with it and gather our thoughts and see what can come out of it.

@dabla dabla force-pushed the feature/apache-arrow-provider branch from fcaa384 to 0a14b5a Compare July 7, 2026 21:16
dabla and others added 20 commits July 7, 2026 23:17
# Conflicts:
#	dev/breeze/doc/images/output_build-docs.svg
#	dev/breeze/doc/images/output_build-docs.txt
#	dev/breeze/doc/images/output_release-management_add-back-references.svg
#	dev/breeze/doc/images/output_release-management_add-back-references.txt
#	dev/breeze/doc/images/output_release-management_classify-provider-changes.svg
#	dev/breeze/doc/images/output_release-management_classify-provider-changes.txt
#	dev/breeze/doc/images/output_release-management_generate-issue-content-providers.svg
#	dev/breeze/doc/images/output_release-management_generate-issue-content-providers.txt
#	dev/breeze/doc/images/output_release-management_generate-providers-metadata.svg
#	dev/breeze/doc/images/output_release-management_generate-providers-metadata.txt
#	dev/breeze/doc/images/output_release-management_prepare-provider-distributions.svg
#	dev/breeze/doc/images/output_release-management_prepare-provider-distributions.txt
#	dev/breeze/doc/images/output_release-management_prepare-provider-documentation.svg
#	dev/breeze/doc/images/output_release-management_prepare-provider-documentation.txt
#	dev/breeze/doc/images/output_release-management_publish-docs.svg
#	dev/breeze/doc/images/output_release-management_publish-docs.txt
#	dev/breeze/doc/images/output_sbom_generate-providers-requirements.svg
#	dev/breeze/doc/images/output_sbom_generate-providers-requirements.txt
#	dev/breeze/doc/images/output_workflow-run_publish-docs.svg
#	dev/breeze/doc/images/output_workflow-run_publish-docs.txt
#	uv.lock
@dabla dabla requested a review from potiuk July 15, 2026 05:45
@dabla

dabla commented Jul 15, 2026

Copy link
Copy Markdown
Contributor Author

Just for anyone looking here - this is a draft for discussion between me, @dabla and @zeroshade - we will still need to start a DISCUSSION thread for the new provider - and we think Arrow and ADBC is a good addition. But we have to first discuss the approach :)

A discussion was already started on the devlist in beginning of march this year.

@dabla dabla force-pushed the feature/apache-arrow-provider branch from 4675498 to 2c63de3 Compare July 15, 2026 09:19
@dabla dabla force-pushed the feature/apache-arrow-provider branch from c80496f to 4508f06 Compare July 16, 2026 14:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants