I am new to Grails and Goovy. I have reviewed the Grails Framework docs and the discussion about Optimistic vs Pessimistic locking here
Its clear from the docs that:
Grails uses optimistic locking by default.
Optimistic locking can be turned off (by using version=false)
If you turn off Optimistic locking and care about loosing data when concurrent updates occur then you must enable Pessimistic locking (by using the lock() method)
My questions:
It seems there are 3 modes. Two explicitly named: Optimistic and Pessimistic, and the other implied - where you have overridden Optimistic but not enabled Pessimistic. Is this correct?
If correct - what is this "middle" state called and are there any legitimate uses of this? (The reason for asking is I am reviewing someones code and there is a lot of use of this "middle" state and they are not around to ask, have not documented it etc.... ).