Closed rainest closed 2 months ago
Attention: Patch coverage is 0%
with 10 lines
in your changes missing coverage. Please review.
Project coverage is 41.35%. Comparing base (
61fbc91
) to head (96cece3
).
Files | Patch % | Lines |
---|---|---|
pkg/diff/diff.go | 0.00% | 10 Missing :warning: |
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
Summary
Fixes a bug in the event sender. The original structure of this section meant that GDR only sent change events to the channel if they had encountered in an error. This did not make the KIC DB mode error event generator unhappy, but did not work very well for https://github.com/Kong/kubernetes-ingress-controller/pull/6131, as it did not see most change events. Whoops.
This assigns the error to the event regardless of whether it's nil or not (it'll either populate or just remain nil) and sends the event off before checking for a non-nil error and performing the error return.
After this change, the channel will receive successful events also. This was the original intent, but the breakage went unnoticed til I tried to actual look at successful events.