---
id: ADR-CRM-DQ-002
title: Detect changes after saving
product_area: crm
module: data-quality
revision: 1
status: proposed
design_intent: confirmed
source_sha:
  services-crm: a8d1364f1dd44b723bb5f9acba12f983e9ec8d69
decision: >-
  Committed record changes feed background detection in repeatable batches, with
  queue delivery responsible for another attempt when a handler fails.
constrains:
  - WF-CRM-DQ-001
  - WF-CRM-DQ-002
  - SVC-CRM-DQ-duplicates
  - DOM-CRM-DQ-001
origin: >-
  Andrew, 2026-10-12, recorded in
  services-crm:modules/duplicates/services/detection/duplicate-change-events.ts
  and docs/merging/duplicate-detection.md §6
alternatives:
  - option: Match during the record save
    why_not: >-
      Lookups and scoring would increase save time and make matching errors
      prevent edits.
  - option: Refresh only overnight
    why_not: Suggestions would stay stale throughout the working day.
consequences:
  - The queue introduces a delay between an edit and its refreshed suggestions.
  - Undelivered work leaves old suggestions until recovery or another pass.
  - Import-marked changes await a completion caller that is currently missing.
supersedes: []
evidence:
  - >-
    services-crm at a8d1364f:
    modules/duplicates/services/detection/duplicate-change-events.ts,
    duplicate-detection.ts; docs/change-events.md §5.
---

# Detect changes after saving

## Context

Review evidence needs to follow edits without making a successful save depend on matching.

## Decision

Committed record changes feed background detection in repeatable batches, with queue delivery responsible for another attempt when a handler fails.

## Alternatives Considered

Match during the record save. Lookups and scoring would increase save time and make matching errors prevent edits.

Refresh only overnight. Suggestions would stay stale throughout the working day.

## Consequences

The queue introduces a delay between an edit and its refreshed suggestions. Undelivered work leaves old suggestions until recovery or another pass. Import-marked changes await a completion caller that is currently missing.
