Hello guys,

I am trying to make a pessimitic_write lock with Spring Data JPA 1.1.0 RC1.

I declare my interface method like this:

@Lock(LockModeType.PESSIMISTIC_WRITE)
ProcessInstance findOne(Integer arg0);

When I execute the code that uses this interface, with two threads, the second thread dont get locked in that method. When I use directly JPA API works fine.

Is locking working find in Spring Data JPA 1.1.0 RC1?

Regards,
Ranob