Skip to content

feat(bindings): expose max HTTP connections - #311

Merged
vuanhphung merged 2 commits into
mainfrom
vu-phung/max-connections-bindings
Sep 3, 2026
Merged

vuanhphung merged 2 commits into
mainfrom
vu-phung/max-connections-bindings

Conversation

@vuanhphung

@vuanhphung vuanhphung commented Sep 3, 2026 •

Copy link
Copy Markdown
Collaborator

Expose max_connections on the PyO3 Session and add kernel_session_config_set_max_connections to the C ABI. Both map to HttpConfig.pool_max_idle_per_host, preserve the kernel default when omitted, and reject zero.

The N-API binding already exposes the equivalent option as maxConnections; this adds matching support for Python and C ABI consumers.

Tests: cargo test --locked, PyO3 unit tests, cargo clippy --all-targets -- -D warnings, and the C ABI smoke test.

Signed-off-by: Vu Anh Phung <vu.phung@databricks.com>

@oss-reviewer-bot oss-reviewer-bot Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

✅ No issues identified by the review bot.

@vikrantpuppala

Copy link
Copy Markdown
Collaborator

do the drivers have support to configure this in the thrift mode?

@vuanhphung

Copy link
Copy Markdown
Collaborator Author

@vikrantpuppala Yes.

  1. Python has _pool_maxsize in thrift mode which we will forward to kernel (https://github.com/databricks/databricks-sql-python/blob/main/CONNECTION_PARAMETERS.md)
  2. Node already exposed maxConnections only for kernel mode (https://github.com/databricks/databricks-sql-nodejs/blob/main/CONNECTION_PARAMETERS.md)
  3. Go has WithTransport in thrift mode which we can't reuse so I'll add sth like WithKernelMaxConnections (https://github.com/databricks/databricks-sql-go/blob/main/CONNECTION_PARAMETERS.md)

@vuanhphung
vuanhphung added this pull request to the merge queue Sep 3, 2026
Merged via the queue into main with commit 167651e Sep 3, 2026
24 checks passed

This branch was previously deployed

1 inactive deployment
azure-prod — d4fb8f4e Deployed Sep 3, 2026 by vuanhphung via v0 E2E surface #665
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants