Commit b78983e6 authored by Vihang Mehta's avatar Vihang Mehta
Browse files

Drop already applied updates correctly

Summary:
This check wasn't handling the fact that we might see the same update
multiple times. As a result we were requesting missing updates with equal from
and to values and holding on to that connection for 20 minutes until it timed
out. This should get rid of such spurious requests.

Test Plan:
The async nature of this and double delivery of stan is hard to
reproduce in a test environment. I think it's doable but will require some
rewriting of the existing test. Will be added in a followup.

Reviewers: michelle, #engineering

Reviewed By: michelle, #engineering

Differential Revision: https://phab.corp.pixielabs.ai/D7589

GitOrigin-RevId: 56f52f4538563619458f6ac3d7b1f611f6924f5d
parent 991a794a
Showing with 1 addition and 1 deletion
+1 -1
......@@ -315,7 +315,7 @@ func wrapMetadataRequest(vizierID uuid.UUID, req *metadatapb.MissingK8SMetadataR
}
func (m *MetadataReader) processVizierUpdate(update *metadatapb.ResourceUpdate, vzState *VizierState) error {
if update.UpdateVersion < vzState.updateVersion {
if update.UpdateVersion <= vzState.updateVersion {
// Old update, drop.
return nil
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment