Skip to content

Commit

Permalink
add metric tracking ingest-triggered config updates
Browse files Browse the repository at this point in the history
  • Loading branch information
lobsterkatie committed Aug 6, 2024
1 parent 7b23d5e commit 5dba3cc
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/sentry/grouping/ingest/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,11 @@
from django.conf import settings
from django.core.cache import cache

from sentry import features
from sentry import features, options
from sentry.locks import locks
from sentry.models.project import Project
from sentry.projectoptions.defaults import BETA_GROUPING_CONFIG, DEFAULT_GROUPING_CONFIG
from sentry.utils import metrics

logger = logging.getLogger("sentry.events.grouping")

Expand Down Expand Up @@ -70,6 +71,11 @@ def update_grouping_config_if_needed(project: Project) -> None:
event=audit_log.get_event_id("PROJECT_EDIT"),
data={**changes, **project.get_audit_log_data()},
)
metrics.incr(
"grouping.config_updated",
sample_rate=options.get("grouping.config_transition.metrics_sample_rate"),
tags={"current_config": current_config},
)


def is_in_transition(project: Project) -> bool:
Expand Down

0 comments on commit 5dba3cc

Please sign in to comment.