I am using `hibernate.jdbc.time_zone=UTC` to have predictable timezone from database (i.e don't convert database values to system timezone)
However, when reading from database, org.hibernate.type.descriptor.java.OffsetDateTimeJavaDescriptor#wrap and org.hibernate.type.descriptor.java.ZonedDateTimeJavaDescriptor#wrap use ZoneId.systemDefault() instead of options.getJdbcTimeZone().toZoneId().
Did I have wrong expectations? Does `hibernate.jdbc.time_zone` setting exist only for the purpose of making sure that the date time value is correctly stored in database and received and from database. And the purpose is not to show actual ZonedDateTime/OffsetDateTime values in the `hibernate.jdbc.time_zone` of the resulting ? |
|