-
Notifications
You must be signed in to change notification settings - Fork 41.4k
Description
I'm not sure if this is a question or a bug, so to be extra cautious, I decided to also open an issue. Sorry if this wasn't the proper course of action.
After upgrading spring boot to 3.4, the following method :
@Override
@Lock(LockModeType.PESSIMISTIC_WRITE)
@Nonnull
Optional<DossierDb> findById(@Nonnull UUID id);
in a CrudRepository (defined by
@Repository
public interface DossierDbRepository
extends CrudRepository<DossierDb, UUID>
has stopped throwing PessimisticLockingFailureException (in a test method using retryable).
I still see the log
ERROR: current transaction is aborted, commands ignored until end of transaction block
, but I now get an optional empty when in spring boot 3.3 I got the log AND the error.
I looked in spring data jpa, spring boot release and hibernate 6.5 and 6.6 migration guide but didn't see anything mentioning clearly this change of behaviour.
I also posted a SO question, but in the case it is a true bug, an issue could be warranted.
The expected behavior would be that spring boot 3.4 still throws the PessimisticLockingFailureException rather than "gobbling it up"