I'm trying to write a custom schema validator but I ran into an issue when trying to retrieve the primary keys from a TableInformation object.
Apparently the default extractor InformationExtractorJdbcDatabaseMetaDataImpl assumes that java.sql.DatabaseMetaData.getPrimaryKeys() returns the columns in order of "KEY_SEQ" but that is not always the case (in fact the interface makes no such guarantees). The extractor then tries to insert the ColumnInformation out of bounds of the array list.
I originally ran into this issue with an Oracle 12c DB using the Oracle 22.214.171.124 JDBC driver, but I could also reproduce it with H2, so it does not seem to be an isolated JDBC implementation problem.
I attached a test case. The setup is a bit sloppy but it does run into the issue. It includes a simplified version of one of the entities giving me problems.