diff --git a/services/activitylog/pkg/service/service.go b/services/activitylog/pkg/service/service.go index 2183bdb24a..c97c855b54 100644 --- a/services/activitylog/pkg/service/service.go +++ b/services/activitylog/pkg/service/service.go @@ -543,6 +543,7 @@ func (a *ActivitylogService) enforceMaxActivities(ctx context.Context, resourceI a.log.Error().Err(err).Str("resourceID", resourceID).Msg("could not watch") return } + defer watcher.Stop() var keys []string for update := range watcher.Updates() {