When using distributed locks, we currently use Owner as identity that holds a lock. Owner consists of the node's address and the thread's ID.
This has the same semantics as ReentrantLock which makes the thread which called Lock.lock() the owner.
However, in some scenarios, this is too strong and some applications only want the current node to be the lock owner. This is needed in cases where thread T1 locks a lock but thread T2 needs to unlock it.
This means, however, that all threads in a given node can lock or unlock the same lock.
- Add property use_thread_id_for_lock_owner to CENTRAL_LOCK (default: false)
- When set, getOwner() sets the thread-id to -1