-
Notifications
You must be signed in to change notification settings - Fork 173
feat(csharp/src/Drivers/Databricks): Handle legacy SPARK catalog #2884
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
Merged
CurtHagenlocher
merged 9 commits into
apache:main
from
eric-wang-1990:add_catalog_parameter_support
May 27, 2025
Merged
feat(csharp/src/Drivers/Databricks): Handle legacy SPARK catalog #2884
CurtHagenlocher
merged 9 commits into
apache:main
from
eric-wang-1990:add_catalog_parameter_support
May 27, 2025
Conversation
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
…g support Adds a new connection parameter 'adbc.databricks.enable_multiple_catalog_support' to control whether the driver should use multiple catalogs or restrict to a default catalog. Default is true for backward compatibility. This parameter accepts boolean values 'true'/'false' or '1'/'0' for compatibility with tools like PowerBI.
CurtHagenlocher
requested changes
May 27, 2025
Contributor
CurtHagenlocher
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks! Either I'm missing something or the logic in the Databricks-specific implementations is backwards.
CurtHagenlocher
approved these changes
May 27, 2025
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.
Arrow-ADBC Catalog Parameter Support
Overview
This branch adds support for properly handling catalog parameters in the C# ADBC driver for Databricks, with special handling for the legacy "SPARK" catalog. The implementation ensures backward compatibility with tools that expect "SPARK" to act as a default catalog alias while also supporting multiple catalog configurations.
Key Changes
Legacy SPARK Catalog Handling: Added special handling for the "SPARK" catalog name, treating it as a null catalog to trigger default catalog behavior in the underlying API.
Multiple Catalog Support: Enhanced the implementation to respect the
EnableMultipleCatalogSupportconfiguration setting, with proper behavior for both enabled and disabled states.Metadata Query Optimization: Implemented optimized metadata query handling (GetCatalogs, GetSchemas, GetTables, GetColumns) that avoids unnecessary RPC calls when possible.
Protected Method Visibility: Modified method visibility in base classes to allow proper overriding in derived classes, enabling specialized catalog handling.
Comprehensive Testing: Added tests to verify the behavior of metadata queries with different catalog settings and configurations.
Implementation Details
The implementation follows a clean approach that:
These changes improve compatibility with various client tools while maintaining performance and adhering to the ADBC specification.