trinodb / trino

Official repository of Trino, the distributed SQL query engine for big data, formerly known as PrestoSQL (https://trino.io)
https://trino.io
Apache License 2.0
10.49k stars 3.02k forks source link

Add iceberg.jdbc-catalog.retryable-status-codes configuration property #24066

Closed asolovey closed 6 days ago

asolovey commented 2 weeks ago

Allows retrying additional, JDBC driver and database specific errors such as Postgres status codes 57000,57P03,57P04 if using Postgres.

Add iceberg.jdbc-catalog.retryable-status-codes configuration property.

Description

Iceberg JDBC catalog uses internal connection pool which supports retrying transient connection errors which improves Iceberg catalog resilience.

By default, only a limited set of status codes is supported: https://github.com/apache/iceberg/blob/main/core/src/main/java/org/apache/iceberg/jdbc/JdbcClientPool.java#L50

These codes are database-agnostic and do not include database-specific transient errors.

To configure additional status codes, Iceberg JDBC Catalog supports retryable_status_codes configuration property: https://github.com/apache/iceberg/blob/main/core/src/main/java/org/apache/iceberg/jdbc/JdbcClientPool.java#L73

This PR adds this property to the Trino Iceberg catalog properties so it can be configured.

Additional context and related issues

Partially fixes #23095.

Release notes

(x) Release notes are required, with the following suggested text:

## Iceberg
* Add `iceberg.jdbc-catalog.retryable-status-codes` configuration property in JDBC catalog
 to allow configuring retryable status codes on JDBC connection errors.  ({issue}`23095`)
cla-bot[bot] commented 2 weeks ago

Thank you for your pull request and welcome to the Trino community. We require contributors to sign our Contributor License Agreement, and we don't seem to have you on file. Continue to work with us on the review and improvements in this PR, and submit the signed CLA to cla@trino.io. Photos, scans, or digitally-signed PDF files are all suitable. Processing may take a few days. The CLA needs to be on file before we merge your changes. For more information, see https://github.com/trinodb/cla

asolovey commented 1 week ago

Did you submit CLA?

Yes, I did, yesterday (11/07) so it may take a few days to get processed.

cla-bot[bot] commented 1 week ago

Thank you for your pull request and welcome to the Trino community. We require contributors to sign our Contributor License Agreement, and we don't seem to have you on file. Continue to work with us on the review and improvements in this PR, and submit the signed CLA to cla@trino.io. Photos, scans, or digitally-signed PDF files are all suitable. Processing may take a few days. The CLA needs to be on file before we merge your changes. For more information, see https://github.com/trinodb/cla

cla-bot[bot] commented 1 week ago

Thank you for your pull request and welcome to the Trino community. We require contributors to sign our Contributor License Agreement, and we don't seem to have you on file. Continue to work with us on the review and improvements in this PR, and submit the signed CLA to cla@trino.io. Photos, scans, or digitally-signed PDF files are all suitable. Processing may take a few days. The CLA needs to be on file before we merge your changes. For more information, see https://github.com/trinodb/cla