Usage Metering & Billing Pipeline · View 12 of 22 · Runtime
The decisive message
- Message 5 is the whole design: the 202 follows durable replication, so an accepted event cannot be lost. If the acknowledgement came first, the ledger would not be the system of record and messages 13 to 15 could not be answered honestly.
- Message 9 applies the plan version in force at event time, not at rating time. That is what makes a mid-period plan change split the period instead of retroactively repricing it.
- Messages 13 to 15 read the ledger, not the aggregate store. A dispute is answered from the record.
Assumptions
- Accept path p99 ≤ 50 ms with replication inside it (stated assumption). This is the budget that decides how many replicas the ledger write can wait for.
- The aggregate handed to rating carries its event_range, so the evidence query in message 14 is a bounded scan rather than a full-period one.
Risks
- The self-messages hide the expensive parts: dedup lookup at rate, and window state size on the aggregator. Both are capacity questions this view does not answer.
- Message 11's anomaly gate is the last chance to catch a wrong figure before it becomes a correction with a customer attached.