Skip to content

[PECOBLR-3982] Use JDBC-standard exception for unimplemented features - #1650

Draft
prathamesh-db wants to merge 1 commit into
databricks:mainfrom
prathamesh-db:brickyard/not-implemented-jdbc-contract
Draft

[PECOBLR-3982] Use JDBC-standard exception for unimplemented features#1650
prathamesh-db wants to merge 1 commit into
databricks:mainfrom
prathamesh-db:brickyard/not-implemented-jdbc-contract

Conversation

@prathamesh-db

Copy link
Copy Markdown
Contributor

Description

Brickyard’s driver-error alert for 3.0.1 surfaced a large volume of unsupported-operation failures. Transactions and callable statements were implemented in later driver releases, but the current driver still reports genuinely unsupported JDBC methods through an exception that does not implement the standard SQLFeatureNotSupportedException contract.

This change makes DatabricksSQLFeatureNotImplementedException extend SQLFeatureNotSupportedException while preserving the existing NOT_IMPLEMENTED_OPERATION telemetry export and vendor code 0.

Testing

The new focused test verifies the JDBC exception type, SQL state, vendor code, and telemetry export. All 46 DatabricksConnectionTest cases pass, and Spotless passes.

Telemetry Errors

  • Not applicable — this PR does not add or change a telemetry-visible error.
  • Applicable — the error uses DatabricksDriverErrorCode where appropriate, and any new code is uniquely numbered and tested.
  • Applicable — maintainer help is requested to confirm that the existing NOT_IMPLEMENTED_OPERATION classification remains driver-owned.

Additional Notes to the Reviewer

This reuses the existing error enum; no new telemetry code is added.

Compatibility tradeoff: code that catches only DatabricksSQLException will no longer catch this exception. Code catching SQLException, SQLFeatureNotSupportedException, or the concrete exception continues to work. Please review whether adopting the JDBC-standard hierarchy justifies that source-level behavior change.

Jira: PECOBLR-3982

Signed-off-by: Prathamesh Baviskar <prathamesh.baviskar@databricks.com>
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.

1 participant