Skip to content

Conversation

@jackyhu-db
Copy link
Contributor

Motivation

Currently, the default QueryTimeoutSeconds is 60s (set by Hive2Server2Connection here), which is too short as some customers may run some large and complex queries which takes long time.

Change

Change the QueryTimeoutSeconds in the DatabricksConnection to 3 hours if it is not configured by the connection parameter in the client

Test

  • Existing E2E test
  • Test a long running query ( >. 2 mins)

@github-actions github-actions bot added this to the ADBC Libraries 20 milestone Jul 18, 2025
Copy link
Contributor

@CurtHagenlocher CurtHagenlocher left a comment

Choose a reason for hiding this comment

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

This change will obviously work, but I think it's pretty confusing. Can we instead put a virtual int DefaultQueryTimeoutSeconds { get; } on Hive2Connection` and then override it from DatabricksConnection?

(Feel free to push back; I don't feel super strongly about it.)

@jackyhu-db
Copy link
Contributor Author

jackyhu-db commented Jul 18, 2025

This change will obviously work, but I think it's pretty confusing. Can we instead put a virtual int DefaultQueryTimeoutSeconds { get; } on Hive2Connection` and then override it from DatabricksConnection?

(Feel free to push back; I don't feel super strongly about it.)

I am not sure if this change will work as the initial value of QueryTimeoutSeconds is set in the base class Hive2ServerConnection, at this time it does not get the value DefaultQueryTimeoutSeconds from the subclass DatabricksConnection. The logic I added here is it will set the QueryTimeoutSeconds with 3 hours as long as it is not customized by the client with connection parameter adbc.apache.statement.query_timeout_s, which means even if it is configured by the base class with some other logic, it will still be overwritten with 3 hours.

@CurtHagenlocher CurtHagenlocher merged commit ebb2fd0 into apache:main Jul 18, 2025
8 checks passed
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