Skip to content

Commit

Permalink
Add metric for no matching case in dedupe
Browse files Browse the repository at this point in the history
  • Loading branch information
gherceg committed Sep 30, 2024
1 parent 7fb17e3 commit f3d778a
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions corehq/apps/data_interfaces/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@
)
from corehq import toggles
from corehq.util.log import with_progress_bar
from corehq.util.metrics import metrics_counter
from corehq.util.metrics.load_counters import dedupe_load_counter
from corehq.util.quickcache import quickcache
from corehq.util.test_utils import unit_testing_only
Expand Down Expand Up @@ -1178,6 +1179,7 @@ def _handle_case_duplicate(self, case, rule):
# but disabling this to avoid further quota issues.
# raise ValueError(f'Unable to find current ElasticSearch data for: {case.case_id}')
# Ignore this result for now
metrics_counter('commcare.dedupe.no_matching_case', tags={'domain': case.domain})
return CaseRuleActionResult(num_errors=1)
else:
# Normal processing can involve latency between when a case is written to the database and when
Expand Down

0 comments on commit f3d778a

Please sign in to comment.