JPA Pessimistic Lock attempt never times out

后端 未结 3 731
悲&欢浪女
悲&欢浪女 2021-01-05 09:34

I\'m trying to use Pessimistic locking in JPA, over Hibernate 3 against a Postgres Database. I can\'t get the lock to time out - it just seems to hang forever.

Here

3条回答
  •  夕颜
    夕颜 (楼主)
    2021-01-05 10:21

    Put this in your persistence.xml:

    
    

    Or set the property before calling the first lock.

提交回复
热议问题