Closed p-kozlowski closed 5 years ago
let me decline this PR and merge it with #725. the reason is that removing Get() will cause issues with etcd compaction. keeping the 2 PRs will require doing the same work twice as the affected code has been changed significantly in #725.
ETCD's API does allow Get() with a selected revision, but it's impossible to express "Get() with a revision equal or greater". When a Watch() is requested starting an given revision, we just omit the call to Get().
Previously the API will return the current revision of the given key, not the one the API user requested. Ie. the newly added test will fail with
mismatch response: &{Action:get Key:/path/to/watch/with/starting/revision Data:map[version:2] Revision:56501 Err:<nil>}, expecting version==1, revision==56500
(as seen in the CI)