Gavin King (
https://hibernate.atlassian.net/secure/ViewProfile.jspa?accountId=557058%...
) *updated* an issue
Hibernate ORM (
https://hibernate.atlassian.net/browse/HHH?atlOrigin=eyJpIjoiZTI0NWI5NDYy...
) / Improvement (
https://hibernate.atlassian.net/browse/HHH-15683?atlOrigin=eyJpIjoiZTI0NW...
) HHH-15683 (
https://hibernate.atlassian.net/browse/HHH-15683?atlOrigin=eyJpIjoiZTI0NW...
) Query.setLockOptions() ignores some of the options, apparently by design (
https://hibernate.atlassian.net/browse/HHH-15683?atlOrigin=eyJpIjoiZTI0NW...
)
Change By: Gavin King (
https://hibernate.atlassian.net/secure/ViewProfile.jspa?accountId=557058%...
)
So look, frankly it smells a bit that {{LockOptions}} has {{aliasSpecificLockModes}} that
only apply to queries, and not to {{get()}}, {{refresh()}} or {{lock()}}. But now I see
that when you call {{Query.setLockOptions()}}, these {{aliasSpecificLockModes}} are
actually ignored and not copied over, making them almost useless. And this is actually the
_documented behavior_, so I can’t even call it a bug.
This is frankly a bit crazy, and either:
* {{Query.setLockOptions()}} should respect all the options in its argument, or
* We we should remove {{aliasSpecificLockModes}} from {{LockOptions}}.
Both of those would be in principle a backward-incompatible change, but the first looks
pretty innocuous to me.
(
https://hibernate.atlassian.net/browse/HHH-15683#add-comment?atlOrigin=ey...
) Add Comment (
https://hibernate.atlassian.net/browse/HHH-15683#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#100210- sha1:4f8bc0d )