HHH000342: Hibernate 5.4.5 with DB2390 on z/OS

Hi,

I try to migrate our application from Hibernate 5.3.4 to 5.4.5.
We use DB2390 on z/OS. So I configured DB2390V8Dialect as before.

With Hibernate 5.4.5, this warning is logged on startup:
WARN org.hibernate.engine.jdbc.env.internal.JdbcEnvironmentInitiator - HHH000342: Could not obtain connection to query metadata : Name cannot be null

After some debugging I think the reason is the implementation of SequenceInformationExtractorDB2DatabaseImpl:

 protected String sequenceNameColumn() {
	return "seqname";
}

protected String sequenceSchemaColumn() {
	return "seqschema";
}

maybe should be replaced with

protected String sequenceNameColumn() {
	return "name";
}

protected String sequenceSchemaColumn() {
	return "schema";
}

All these four columns exist in SYSIBM.SYSSEQUENCES, but at least in my case only “name” and “schema” are always filled, the other two only when an alias for a sequence is created (the “name of the target sequence”)?

See also https://www.ibm.com/support/knowledgecenter/en/SSEPEK_12.0.0/cattab/src/tpc/db2z_sysibmsyssequencestable.html