Gavin King (
https://hibernate.atlassian.net/secure/ViewProfile.jspa?accountId=557058%...
) *created* an issue
Hibernate ORM (
https://hibernate.atlassian.net/browse/HHH?atlOrigin=eyJpIjoiYzdkYThiM2M3...
) / Bug (
https://hibernate.atlassian.net/browse/HHH-16520?atlOrigin=eyJpIjoiYzdkYT...
) HHH-16520 (
https://hibernate.atlassian.net/browse/HHH-16520?atlOrigin=eyJpIjoiYzdkYT...
) detection of duplicate id generator definitions is broken (
https://hibernate.atlassian.net/browse/HHH-16520?atlOrigin=eyJpIjoiYzdkYT...
)
Issue Type: Bug Affects Versions: 6.2.1 Assignee: Unassigned Components: hibernate-core
Created: 26/Apr/2023 04:29 AM Priority: Major Reporter: Gavin King (
https://hibernate.atlassian.net/secure/ViewProfile.jspa?accountId=557058%...
)
There is code in InFlightMetadataCollector.addIdentifierGenerator that purports to detect
duplicate named generator definitions. In fact this is almost completely useless, since id
generator names are global (they usually correspond to named objects in the database) but
there is a new instance of InFlightMetadataCollector for each entity class.
This means that we fail to inform the user when their dupe id generator definition is
ignored. You can see this in action in our very own SequenceGeneratorIncrementTest which
should fail, since there are conflicting definitions of the generator named ID_GENERATOR
but actually doesn’t, since the first definition gets reused by the second entity.
This is bad.
(
https://hibernate.atlassian.net/browse/HHH-16520#add-comment?atlOrigin=ey...
) Add Comment (
https://hibernate.atlassian.net/browse/HHH-16520#add-comment?atlOrigin=ey...
)
Get Jira notifications on your phone! Download the Jira Cloud app for Android (
https://play.google.com/store/apps/details?id=com.atlassian.android.jira....
) or iOS (
https://itunes.apple.com/app/apple-store/id1006972087?pt=696495&ct=Em...
) This message was sent by Atlassian Jira (v1001.0.0-SNAPSHOT#100223- sha1:038ca59 )