Skip to content

Commit

Permalink
Fix bug causing excessive event sending of workload events.
Browse files Browse the repository at this point in the history
Signed-off-by: Thomas Hallgren <[email protected]>
  • Loading branch information
thallgren committed Oct 30, 2024
1 parent 86b19e1 commit 66d188c
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions cmd/traffic/cmd/manager/state/workload_info_watcher.go
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,6 @@ func rpcWorkload(wl k8sapi.Workload, as rpc.WorkloadInfo_AgentState, iClients []
}

func (wf *workloadInfoWatcher) addEvent(
ctx context.Context,
eventType workload.EventType,
wl k8sapi.Workload,
as rpc.WorkloadInfo_AgentState,
Expand All @@ -208,7 +207,7 @@ func (wf *workloadInfoWatcher) addEvent(
Type: rpc.WorkloadEvent_Type(eventType),
Workload: rpcWorkload(wl, as, iClients),
}
wf.sendEvents(ctx, false)
wf.resetTicker()
}

func (wf *workloadInfoWatcher) handleWorkloadsSnapshot(ctx context.Context, wes []workload.WorkloadEvent, initial bool) {
Expand Down

0 comments on commit 66d188c

Please sign in to comment.