You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The SpringPersistenceUnitInfo property 'persistenceXMLSchemaVersion' defaults to 1.0 and is never changed. This is a MAJOR headache for ORMs which use the version information to adjust their behavior.
The bug appears to be in org.springframework.orm.jpa.persistenceunit.PersistenceUnitReader. The version attribute is not used when the document is read to set the value in the SpringPersistenceUnitInfo instances.
The bug is in org.springframework.orm.jpa.persistenceunit.PersistenceUnitReader.java. The version attribute of the <persistence> element needs to be read and then passed in to the function which parses each <persistence_unit>.
The fix adds three lines and changes a fourth. All changes are marked with // JC:
Good catch: We indeed missed the version parsing there. This wasn't noticed simply because EclipseLink 2.0 and Hibernate 3.5 apparently activate JPA 2.0 support in any case.
Fixed as of Spring 3.0.2 - will be available in the next snapshot (611).
Jerry Carter opened SPR-6975 and commented
The SpringPersistenceUnitInfo property 'persistenceXMLSchemaVersion' defaults to 1.0 and is never changed. This is a MAJOR headache for ORMs which use the version information to adjust their behavior.
The bug appears to be in org.springframework.orm.jpa.persistenceunit.PersistenceUnitReader. The version attribute is not used when the document is read to set the value in the SpringPersistenceUnitInfo instances.
Affects: 3.0.1
Attachments:
Referenced from: commits 7da13e7
The text was updated successfully, but these errors were encountered: