Skip to content

JDBC: Update to pgjdbc 42.7.7 #333

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

Merged
merged 2 commits into from
Jun 14, 2025
Merged

JDBC: Update to pgjdbc 42.7.7 #333

merged 2 commits into from
Jun 14, 2025

Conversation

amotl
Copy link
Member

@amotl amotl commented Jan 15, 2025

About

pgjdbc 42.7.5 has been released yesterday. When running the stock jdbc test cases, errors can be observed on Jenkins after bumping manually per this PR.

References

Validating an automatic Dependabot update failed over here on GHA, apparently tripping test_getFunctions, test_getColumns, test_getPrimaryKeys, and test_getTables in JdbcMetaDataTest.java.

/cc @kneth, @seut

@kneth
Copy link
Contributor

kneth commented Feb 7, 2025

Issues encountered:

@amotl
Copy link
Member Author

amotl commented Feb 7, 2025

Thank you very much for your evaluations. Can you converge relevant flaws into corresponding tickets to improve CrateDB?

@hlcianfagna
Copy link

Regarding indnkeyatts, if crate/crate#17377 were addressed, perhaps we could submit a patch to
https://github.com/pgjdbc/pgjdbc/blob/b7bd9ffa25647ca0df76f7fa5b0883324ce79e45/pgjdbc/src/main/java/org/postgresql/jdbc/PgDatabaseMetaData.java#L2345 using

(
SELECT count(*)
FROM information_schema.key_column_usage
JOIN pg_catalog.pg_class ci2 ON ci2.relname = key_column_usage.constraint_name
WHERE ci2.oid = i.indexrelid
)

?

@amotl
Copy link
Member Author

amotl commented Feb 19, 2025

Hi. Because this patch seems to possibly converge well (thank you, @kneth)...

and that issue has apparently been resolved (thank you, @hlcianfagna and @matriv)...

is there another patch to be staged to pgjdbc/pgjdbc, about the problems around indnkeyatts?

@hlcianfagna
Copy link

is there another patch to be staged to pgjdbc/pgjdbc, about the problems around indnkeyatts?

One option could be pgjdbc/pgjdbc#3533 , another option could be to raise a ticket in crate/crate to have indnkeyatts populated.

@kneth
Copy link
Contributor

kneth commented Feb 20, 2025

Dave Cramer says: "Please make sure this does not introduce a performance regression"

My question to @hlcianfagna, do you want me to try to evaluate the performance?

@hlcianfagna
Copy link

Dave Cramer says: "Please make sure this does not introduce a performance regression"

My question to @hlcianfagna, do you want me to try to evaluate the performance?

Let's maybe see what the timeline would be for crate/crate#17486 instead?

@kneth
Copy link
Contributor

kneth commented Mar 14, 2025

I have opened crate/crate#17616 as a fix to the issue with indnkeyatts

@matriv matriv force-pushed the pgjdbc-42.7.5 branch 2 times, most recently from 1191569 to b6b345e Compare May 21, 2025 12:49
@matriv matriv marked this pull request as ready for review June 3, 2025 10:50
@matriv matriv changed the title JDBC: Update to pgjdbc 42.7.5 JDBC: Update to pgjdbc 42.7.6 Jun 3, 2025
@matriv matriv self-requested a review June 4, 2025 04:34
matriv added a commit to crate/crate that referenced this pull request Jun 4, 2025
PG JDBC 42.7.5 & 6 use this function in various metadata related
calls. As CrateDB doesn't support multiple catalogs, it always returns
`crate` thus is registered as an alias to `current_database`.

Relates: crate/crate-qa#333
matriv added a commit to crate/crate that referenced this pull request Jun 4, 2025
PG JDBC 42.7.5 & 6 use this function in various metadata related
calls. As CrateDB doesn't support multiple catalogs, it always returns
`crate` thus is registered as an alias to `current_database`.

Relates: crate/crate-qa#333
matriv added a commit to crate/crate that referenced this pull request Jun 4, 2025
PG JDBC 42.7.5 & 6 use this function in various metadata related
calls. As CrateDB doesn't support multiple catalogs, it always returns
`crate` thus is registered as an alias to `current_database`.

Relates: crate/crate-qa#333
@matriv matriv requested review from seut and removed request for matriv June 4, 2025 18:01
matriv added a commit to crate/crate that referenced this pull request Jun 10, 2025
PG JDBC 42.7.5 & 6 use this function in various metadata related
calls. As CrateDB doesn't support multiple catalogs, it always returns
`crate` thus is registered as an alias to `current_database`.

Relates: crate/crate-qa#333
matriv added a commit to crate/crate that referenced this pull request Jun 11, 2025
PG JDBC 42.7.5 & 6 use this function in various metadata related
calls. As CrateDB doesn't support multiple catalogs, it always returns
`crate` thus is registered as an alias to `current_database`.

Relates: crate/crate-qa#333
matriv added a commit to crate/crate that referenced this pull request Jun 11, 2025
PG JDBC 42.7.5 & 6 use this function in various metadata related
calls. As CrateDB doesn't support multiple catalogs, it always returns
`crate` thus is registered as an alias to `current_database`.

Relates: crate/crate-qa#333
matriv added a commit to crate/crate that referenced this pull request Jun 11, 2025
PG JDBC 42.7.5 & 6 use this function in various metadata related
calls. As CrateDB doesn't support multiple catalogs, it always returns
`crate` thus is registered as an alias to `current_database`.

Relates: crate/crate-qa#333
matriv added a commit to crate/crate that referenced this pull request Jun 11, 2025
PG JDBC 42.7.5 & 6 use this function in various metadata related
calls. As CrateDB doesn't support multiple catalogs, it always returns
`crate` thus is registered as an alias to `current_database`.

Relates: crate/crate-qa#333
mergify bot pushed a commit to crate/crate that referenced this pull request Jun 11, 2025
PG JDBC 42.7.5 & 6 use this function in various metadata related
calls. As CrateDB doesn't support multiple catalogs, it always returns
`crate` thus is registered as an alias to `current_database`.

Relates: crate/crate-qa#333
@matriv
Copy link
Contributor

matriv commented Jun 12, 2025

retest this please

@matriv
Copy link
Contributor

matriv commented Jun 12, 2025

retest this please

@matriv matriv requested review from matriv and removed request for seut June 12, 2025 06:44
@matriv matriv enabled auto-merge (rebase) June 12, 2025 06:44
@matriv matriv disabled auto-merge June 12, 2025 06:44
amotl and others added 2 commits June 12, 2025 18:04
Use `null` instead of empty string `''` to avoid adding `like` WHERE
clauses to the metadata queries.
@matriv matriv changed the title JDBC: Update to pgjdbc 42.7.6 JDBC: Update to pgjdbc 42.7.7 Jun 12, 2025
@matriv
Copy link
Contributor

matriv commented Jun 13, 2025

retest this please

1 similar comment
@matriv
Copy link
Contributor

matriv commented Jun 14, 2025

retest this please

@matriv matriv enabled auto-merge (rebase) June 14, 2025 09:02
@matriv matriv merged commit eab05d8 into master Jun 14, 2025
1 check passed
@matriv matriv deleted the pgjdbc-42.7.5 branch June 14, 2025 09:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants