Fixed vector clock contention

It fixes internal contention on the vector clocks where it was possible to write partially changed clocks or end up using mixed up vector clocks on multiple threads changing it simultanously. This might have ended up with lost updates.