ISPN-2405 Pessimistic transactions can leak locks when cluster topology changes

* In PessimisticLockingInterceptor.visitLockControlCommand there is an optimization to avoid remote calls if the key is local. Unfortunatelly this had the unintended side effect of not adding the locked key to TX.afectedKeys collection if the key was local.

* BaseRpcInterceptor.shouldInvokeRemoteTxCommand() and AbstractEnlistmentAdapter.mayHaveRemoteLocks will return true if the TX was started in an older topology than current, regardless if modifications or remote locks are present. This ensures the TX command reaches all locked key owners not just the ones registered in TX.getRemoteLocksAcquired() which can become out of date after rehashing.

* RpcManagerImpl.getTopologyId() should return -1 instead of throwing NPE if the cache has not joined yet (ie. during preloading)

* Add unit test for the pessimistic locking case.

* Minor cleanup in the existing UT for optimistic locking.