This repository has been archived by the owner on Jun 4, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 78
[Buddy] fix leaking go-routines in event-handler watcher #966
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Signed-off-by: joerger <[email protected]>
Joerger
requested review from
klizhentas,
russjones,
r0mant,
tcsc,
zmb3,
camscale and
fheinecke
as code owners
November 3, 2023 02:38
Joerger
changed the title
[Buddy] fix leaking go-routines in event-handler watcher
[buddy] fix leaking go-routines in event-handler watcher
Nov 3, 2023
Joerger
changed the title
[buddy] fix leaking go-routines in event-handler watcher
[Buddy] fix leaking go-routines in event-handler watcher
Nov 3, 2023
zmb3
reviewed
Nov 3, 2023
I gave this some more thought and realized this one line fix is not a viable solution. This change allows the event handler to drop incomplete pages of events and move on to the next page. Instead, we need to update the event handler to only spawn a single goroutine at a time, instead of spawning new goroutines for new pages when we are still trying to finish a known page. Drafting for now as I won't have time to make this change immediately. |
Joerger
force-pushed
the
joerger/pr-buddy-963
branch
from
November 5, 2023 20:06
4319631
to
6984a71
Compare
I gave another pass to this fix, and found it works after all. I've updated the tests to give better coverage to the event collection logic and cover the edge case I was concerned about. |
Joerger
force-pushed
the
joerger/pr-buddy-963
branch
from
November 28, 2023 03:36
ff7c61d
to
9b199a2
Compare
@zmb3 This is ready to review when you get a chance |
zmb3
approved these changes
Nov 28, 2023
rosstimothy
approved these changes
Nov 28, 2023
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Buddy PR for #963 with edits to resolve remaining comments.