SQLAlchemy dialect for IOMETE via Arrow Flight SQL
Project description
iomete-sqlalchemy
A SQLAlchemy dialect for IOMETE using Arrow Flight SQL (adbc-driver-flightsql).
All reflection methods are implemented and relational stubs (PK, FK, indexes) return graceful empty results instead of raising NotImplementedError, making it compatible with schema inspection tools and data catalog integrations.
Requirements
Python 3.9+sqlalchemy >= 2.0.30adbc-driver-flightsql >= 1.1.0pyarrow >= 16.0
Installation
pip install iomete-sqlalchemy
Connection URL
iomete://<user>:<password>@<host>:<port>/<catalog>/<schema>
?cluster=<cluster>
&data_plane=<data_plane>
[&tls=true]
[&max_msg_size=134217728]
| Parameter | Description | Default |
|---|---|---|
host |
IOMETE host | — |
port |
gRPC port | 443 |
catalog |
Top-level catalog (e.g. spark_catalog) |
— |
schema |
Schema / database inside the catalog | — |
cluster |
IOMETE compute cluster name | — |
data_plane |
IOMETE data plane name | — |
tls |
Use grpc+tls transport |
true |
max_msg_size |
Max gRPC message size in bytes | 134217728 (128 MB) |
Example
from sqlalchemy import create_engine, inspect, text
HOST = "dev.iomete.cloud"
PORT = 443
USERNAME = "your-username"
PASSWORD = "your-password"
CATALOG = "spark_catalog"
SCHEMA = "default"
CLUSTER = "your-cluster"
DATA_PLANE = "your-data-plane"
engine = create_engine(
f"iomete://{USERNAME}:{PASSWORD}@{HOST}:{PORT}"
f"/{CATALOG}/{SCHEMA}"
f"?cluster={CLUSTER}&data_plane={DATA_PLANE}"
)
# Check connection
with engine.connect() as conn:
print(conn.execute(text("SELECT 1")).scalar()) # → 1
# Reflect schema
inspector = inspect(engine)
print(inspector.get_schema_names())
print(inspector.get_table_names(schema=f"{CATALOG}.{SCHEMA}"))
Supported Type Mappings
| Spark / Iceberg type | SQLAlchemy type |
|---|---|
boolean |
Boolean |
tinyint, smallint |
SmallInteger |
int, integer |
Integer |
bigint |
BigInteger |
float, real |
Float(24) |
double |
Float(53) |
decimal(p, s) |
Numeric(p, s) |
char(n) |
CHAR(n) |
varchar(n) |
VARCHAR(n) |
string, text |
Text |
binary |
LargeBinary |
date |
Date |
timestamp, timestamp_ntz |
DateTime |
array<…>, map<…>, struct<…> |
JSON |
Contributing
See CONTRIBUTING.md for architecture overview, codebase layout, and how to run tests.
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file iomete_sqlalchemy-1.0.21.tar.gz.
File metadata
- Download URL: iomete_sqlalchemy-1.0.21.tar.gz
- Upload date:
- Size: 14.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5acec7c2f7032237901d2b0e07e4612c5b8f7c29be181c3a636484ea8ec7bc45
|
|
| MD5 |
d8bb1e9c8e84ab805f23f17a60d3ce1d
|
|
| BLAKE2b-256 |
a85cbfa7bc58b9b443c9577881cd2875c3e1480d3d845e69f09f1986ce69f983
|
Provenance
The following attestation bundles were made for iomete_sqlalchemy-1.0.21.tar.gz:
Publisher:
publish.yml on iomete/iomete-sqlalchemy
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
iomete_sqlalchemy-1.0.21.tar.gz -
Subject digest:
5acec7c2f7032237901d2b0e07e4612c5b8f7c29be181c3a636484ea8ec7bc45 - Sigstore transparency entry: 1227697549
- Sigstore integration time:
-
Permalink:
iomete/iomete-sqlalchemy@804c748c19485d77e557ce4e623fc5085002be3d -
Branch / Tag:
refs/tags/v1.0.21 - Owner: https://github.com/iomete
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@804c748c19485d77e557ce4e623fc5085002be3d -
Trigger Event:
push
-
Statement type:
File details
Details for the file iomete_sqlalchemy-1.0.21-py3-none-any.whl.
File metadata
- Download URL: iomete_sqlalchemy-1.0.21-py3-none-any.whl
- Upload date:
- Size: 14.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c1a48b2e3a565c6b37ba4df0017e7385ed85ea0e0ce21903a83e683d78c5ff07
|
|
| MD5 |
a872fdde4bd16fd064fc5b8600575b66
|
|
| BLAKE2b-256 |
b9cecc89d686924cb8eea365f4888bb701c1521556039ed63913002f825a136c
|
Provenance
The following attestation bundles were made for iomete_sqlalchemy-1.0.21-py3-none-any.whl:
Publisher:
publish.yml on iomete/iomete-sqlalchemy
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
iomete_sqlalchemy-1.0.21-py3-none-any.whl -
Subject digest:
c1a48b2e3a565c6b37ba4df0017e7385ed85ea0e0ce21903a83e683d78c5ff07 - Sigstore transparency entry: 1227697555
- Sigstore integration time:
-
Permalink:
iomete/iomete-sqlalchemy@804c748c19485d77e557ce4e623fc5085002be3d -
Branch / Tag:
refs/tags/v1.0.21 - Owner: https://github.com/iomete
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@804c748c19485d77e557ce4e623fc5085002be3d -
Trigger Event:
push
-
Statement type: