Brett Meyer commented on an issue
Hibernate ORM / Improvement HHH-8521
LockMode should be checked on query execution, not during call to setLockMode
{{org.hibernate.jpa.spi.AbstractQueryImpl#setLockMode}} checks to see if a transaction is in progress. Really that check ought to be delayed until we actually execute the query