Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: flightsql initial support #2219

Merged
merged 21 commits into from
Dec 12, 2023
Merged

feat: flightsql initial support #2219

merged 21 commits into from
Dec 12, 2023

Conversation

universalmind303
Copy link
Contributor

@universalmind303 universalmind303 commented Dec 7, 2023

example usage

pip install adbc_driver_flightsql
pip install polars
# example.py
import adbc_driver_flightsql.dbapi
import polars as pl

with adbc_driver_flightsql.dbapi.connect("grpc://0.0.0.0:6789") as conn:
    cursor = conn.cursor()
    cursor.execute(
        "SELECT * from './testdata/csv/userdata1.csv'"
    )
    res = cursor.fetch_arrow_table()
    print(pl.from_arrow(res))
    cursor.close()

See the official adbc flightsql docs for more info

@universalmind303 universalmind303 marked this pull request as ready for review December 7, 2023 17:22
crates/rpcsrv/src/flight_handler.rs Outdated Show resolved Hide resolved
crates/rpcsrv/src/flight_handler.rs Show resolved Hide resolved
Copy link
Collaborator

@tychoish tychoish left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nothing seems out of place.

@vrongmeal (et al) should take a look to make sure that the consumption metrics stuff is properly wired up (but that need not happen during this pr.

crates/rpcsrv/src/flight_handler.rs Outdated Show resolved Hide resolved
crates/glaredb/src/server.rs Outdated Show resolved Hide resolved
crates/rpcsrv/src/flight_handler.rs Outdated Show resolved Hide resolved
crates/rpcsrv/src/flight_handler.rs Outdated Show resolved Hide resolved
crates/rpcsrv/src/flight_handler.rs Outdated Show resolved Hide resolved
crates/sqlexec/src/session.rs Outdated Show resolved Hide resolved
crates/rpcsrv/src/flight_handler.rs Outdated Show resolved Hide resolved
crates/rpcsrv/src/flight_handler.rs Outdated Show resolved Hide resolved
crates/rpcsrv/src/handler.rs Outdated Show resolved Hide resolved
@universalmind303 universalmind303 changed the title feat: partial flightsql support feat: flightsql initial support Dec 8, 2023
@universalmind303 universalmind303 linked an issue Dec 8, 2023 that may be closed by this pull request
@vrongmeal
Copy link
Contributor

@vrongmeal (et al) should take a look to make sure that the consumption metrics stuff is properly wired up (but that need not happen during this pr.

Metrics are not being collected here. Looking more into the PR on how this might be easier to plug-in.

Copy link
Contributor

@vrongmeal vrongmeal left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Apart from metrics collection, this looks good to me! 🚀

@universalmind303
Copy link
Contributor Author

@vrongmeal, I added a followup issue for setting up metrics

@universalmind303 universalmind303 enabled auto-merge (squash) December 12, 2023 17:04
@universalmind303 universalmind303 merged commit 229acb2 into main Dec 12, 2023
9 of 10 checks passed
@universalmind303 universalmind303 deleted the flightsql branch December 12, 2023 17:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

flightsql: initial support
4 participants