Aglet

Investigate out-of-order webhook state changes

Investigation should show why an older event was accepted or a newer event was delayed. Build ordered, reversed, duplicate, equal-time, and missing-version fixtures, then trace each write. Keep sender ordering, network delay, worker scheduling, and local guards as competing explanations.

Build a useful investigation brief

  1. Build ordered event pairs

    Create two events for one resource with known states, IDs, versions, timestamps, and expected order. Add reversed receipt, equal timestamps, duplicate delivery, and missing version cases. Record expected final state before execution.

  2. Trace each state write

    Capture receipt, identity, event time, sequence or version, current local version, comparison result, handler, and write outcome. Compare the first point where an older event becomes eligible. Preserve resource history for review.

  3. Vary one ordering input

    Change only receipt delay, worker order, timestamp precision, sequence, version, or duplicate status. Compare stale rejection, application, and reconciliation. If source order cannot be observed, state that contract limit instead of inventing a sort rule.

What to carry forward

The investigation is ready when event pairs reproduce the first stale acceptance or rejection and its state effect. Deliver a narrow version guard or evidence request. Keep sender and cross-resource ordering limits explicit. Keep sender order and worker order distinct in the state trace.

Technical background: Stripe documentation.

Keep the decision with the work.

Use a Work Item in Aglet to record the problem, the evidence you have, and the next decision. Add an owner and priority, then keep updates in the discussion so the next person can follow the reasoning.

Create an account See the product workflow