Skip to main content

check_write_key_conflicts

Function check_write_key_conflicts 

Source
pub fn check_write_key_conflicts(req: &ParsedRequest) -> Result<(), DslError>
Expand description

Check a parsed batch for write-key conflicts (ADR-038 preflight).

Write operations (update, delete, merge, link) target specific UUIDs. If two ops in the same parallel (or single-op) batch write to the same UUID, the batch is rejected before any op is dispatched.

Chain mode is excluded: sequential ops intentionally build on prior results and the runtime resolves $prev references between them.

The checked keys per verb:

  • update / delete: id
  • merge: into_id, from_id
  • link: source_id, target_id

Only concrete ArgValue::Value(String) arguments are checked; $prev references are skipped because their target is not known until dispatch time.