feat: implement Connection::get_info() (#9) - #69
Open
ylw510 wants to merge 5 commits into
Open
Conversation
Expose driver/vendor metadata (including server version via SELECT version()) so ADBC clients can discover ClickHouse capabilities. Co-authored-by: Cursor <cursoragent@cursor.com>
Avoid hardcoding the Arrow crate version; emit it from build.rs using cargo metadata. Co-authored-by: Cursor <cursoragent@cursor.com>
ClickHouse Arrow output no longer includes PARQUET:logical_type on UUID columns, which broke binary_strings_round_trip under assert_eq!.
abonander
requested changes
Aug 31, 2026
Comment on lines
+10
to
+13
| let metadata = MetadataCommand::new() | ||
| .manifest_path("Cargo.toml") | ||
| .exec() | ||
| .expect("failed to run cargo metadata"); |
Collaborator
There was a problem hiding this comment.
I'm not a huge fan of this:
- Hard dependency on Cargo. In my experience there are users out there employing non-Cargo build systems; they're generally happy enough to take on the dependency management but invoking Cargo directly tends to complicate things.
- The build script itself is an extra compilation target, adding overhead to clean builds.
- This would be trivial for Arrow to add themselves as, e.g.
const VERSION_STRING: &str = env!("CARGO_PACKAGE_VERSION")and it would be useful for everyone implementing Rust ADBC drivers.
Author
There was a problem hiding this comment.
Totally aggree.
I create a pr in: apache/arrow-rs#10957.
Collaborator
There was a problem hiding this comment.
It's really neat of them to merge that so quickly but we can't really use it until the next release anyway. We'd also have to upgrade arrow-* to 59.4.0, so that would have to wait until we start on 0.2.0 (using a version range is unfortunately a non-starter: #68 (comment)).
That kind of leaves us only a couple options:
- Merge as-is with a FIXME comment, or:
- Leave this field unpopulated for now (also with a FIXME comment).
If this field is really needed I suppose we could merge it as-is, but I don't think any field is strictly required in the interface contract here, so I think I'd rather just omit it.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Connection::get_info()for ADBC driver/vendor metadata (closes ImplementConnection::get_info()#9).VendorVersionviaSELECT version(), plus driver name/version/Arrow/ADBC info; omit unsupported Substrait / vendor Arrow version codes.DriverArrowVersionat build time withcargo_metadata(from the resolvedarrow-arraypackage) instead of a hardcoded string.