Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove GC and callback from store.go #3840

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

grobinson-grafana
Copy link
Contributor

@grobinson-grafana grobinson-grafana commented May 13, 2024

This commit removes the GC and callback function from store.go to address a number of data races and deadlocks that have occurred in the past (#2040 and #3175). The store is no longer responsible for removing resolved alerts after some elapsed period of time, and is instead deferred to the consumer of the store (as done in #2040). This change avoids situations where the callback function for the store attempts to acquire a mutex on A but another goroutine holds the mutex for A and needs to acquire the mutex in the store, causing a deadlock.

This commit removes the GC and callback function from store.go
to address a number of data races that have occurred in the past
(prometheus#2040 and prometheus#3648). The store is no longer responsible for removing
resolved alerts after some elapsed period of time, and is instead
deferred to the consumer of the store (as done in prometheus#2040 and prometheus#3648).

Signed-off-by: George Robinson <george.robinson@grafana.com>
@grobinson-grafana grobinson-grafana marked this pull request as ready for review May 26, 2024 18:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant