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

Add connection_parameters for databricks-sql-connector connection parameters #135

Merged
merged 4 commits into from
Jul 21, 2022

Conversation

ueshin
Copy link
Collaborator

@ueshin ueshin commented Jul 20, 2022

Description

Adds connection_parameters as part of credential for databricks-sql-connector connection parameters.

This can be used to customize the connection by setting additional parameters.
The full parameters are listed at Databricks SQL Connector for Python.

Currently, the following parameters are reserved for dbt-databricks.

  • server_hostname
  • http_path
  • access_token
  • session_configuration
  • catalog
  • schema

@ueshin ueshin requested a review from allisonwang-db July 20, 2022 21:21
@ueshin ueshin requested a review from bilalaslamseattle July 21, 2022 18:05
CHANGELOG.md Outdated Show resolved Hide resolved
- Add `connection_parameters` for databricks-sql-connector connection parameters ([#135](https://github.com/databricks/dbt-databricks/pull/135))
- This can be used to customize the connection by setting the additional parameters.
- The full parameters are listed at [Databricks SQL Connector for Python](https://docs.databricks.com/dev-tools/python-sql-connector.html#connect-method).
- Currently, the following parameters are reserved for `dbt-databricks`. Please use the normal credential settings instead.
Copy link
Collaborator

Choose a reason for hiding this comment

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

From the documentation, it seems that the only parameter users can set is http_headers? I do see a list of internal arguments that can be set as well https://github.com/databricks/databricks-sql-python/blob/161b94e9c7832fa8393cdff7bc9eac14f6ba840e/src/databricks/sql/client.py#L50

Copy link
Collaborator Author

@ueshin ueshin Jul 21, 2022

Choose a reason for hiding this comment

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

Yeah, actually the purpose here includes to provide the way to set them, but I'm not sure we should mention the internal parameters here.

Copy link
Collaborator

Choose a reason for hiding this comment

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

Yea we don't need to mention the internal ones. Just realized the only one that can be set is http_headers (maybe there will be more in the future).

@ueshin
Copy link
Collaborator Author

ueshin commented Jul 21, 2022

Thanks! merging.

@ueshin ueshin merged commit d65568f into databricks:main Jul 21, 2022
@ueshin ueshin deleted the connection_parameters branch July 21, 2022 21:56
ueshin added a commit that referenced this pull request Jul 21, 2022
…ameters (#135)

### Description

Adds `connection_parameters` as part of credential for `databricks-sql-connector` connection parameters.

This can be used to customize the connection by setting additional parameters.
The full parameters are listed at [Databricks SQL Connector for Python](https://docs.databricks.com/dev-tools/python-sql-connector.html#connect-method).

Currently, the following parameters are reserved for `dbt-databricks`.

- server_hostname
- http_path
- access_token
- session_configuration
- catalog
- schema
ueshin added a commit to ueshin/dbt-databricks that referenced this pull request Aug 19, 2022
…ameters (databricks#135)

### Description

Adds `connection_parameters` as part of credential for `databricks-sql-connector` connection parameters.

This can be used to customize the connection by setting additional parameters.
The full parameters are listed at [Databricks SQL Connector for Python](https://docs.databricks.com/dev-tools/python-sql-connector.html#connect-method).

Currently, the following parameters are reserved for `dbt-databricks`.

- server_hostname
- http_path
- access_token
- session_configuration
- catalog
- schema
@ueshin ueshin mentioned this pull request Aug 19, 2022
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.

3 participants