I see that maintaining a timestamp cache is more of an optimization and it is ok to reinitialise it as long as the low water mark is set to the server start/initialization time?
The alternative could do all the writes at the latest timestamp? Because each server's hlc is updated and adjusted at every request, both Get and Put, the timestamp assigned to a put request is guaranteed to be after any get request which happened before.
I will recheck, but I guess Spanner writes (and even Percolator writes) happen this way with writes happening at the latest server timestamp and then coordinator picking up the latest timestamp across the participating servers at the commit time.
So I see two requirements
1. Each request (get or put) should adjust the server hlc with the most up-to-date timestamp
2. Each put should advance the hlc and use it as a timestamp of the put. So the txn timestamp is advanced on every put.
This way the write-follows-read and snapshot isolation guarantee can be provided even without a timestamp cache. ?