Documentation
How mediation models telecom usage, one failure per page, with compiled examples.
Each page states the failure it prevents and shows the code that prevents it. Every Rust block on this site is compiled and run as a doctest.
- Evaluating: Getting started, then The conservation law.
- Integrating: One pass, and the order it runs in.
- Fixed-line voice: Fixed-line voice.
- Something bills wrong: Time, Completeness, Deduplication.
Every page
- Getting startedInstall the crate, run a batch through the one-pass driver, and see where every record went.
- Time is local, not UTCA charging record carries a local wall clock and a quarter-hour offset to UTC, and reading it as an instant books evening events onto the wrong day.
- Octets, seconds and eventsEvery chargeable quantity is an integer, uplink and downlink stay apart, and rounding is named but never applied.
- IdentitySubscriber and equipment identifiers, validated and check-digited, never split without a table.
- Where a record was producedCells, tracking areas, the User Location Information element, slices and charging characteristics.
- One pass, and the order it runs inHow `process` assembles the pieces, and why the order matters.
- Fixed-line voiceFrom the dialled string to the itemised bill: dial plans, destination classes, Call-ID keys and § 11 TDDDG itemisation.
- The conservation lawEvery record reaches exactly one outcome, across batches and periods; corrections are signed events.
- Completeness and sequence gapsA hole in a per-source sequence number is the only evidence of a lost file.
- DeduplicationA natural key from the standard, held for a mandatory window.
- Partial records and correlationReassembling partial runs and joining multi-node records without inventing or double-billing usage.
- The rule catalogue and the release gateTwenty-one numbered rules, and the one call a release path makes.
- Splitting a session at a tariff boundaryExact time splits, labelled volume splits, and apportionment that never creates or destroys usage.
- Roaming, interconnect and numberingTAP batch audits, the two RAP rejection classes, and terminating operator lookup under number portability.
- Jurisdiction, fair use, retention and privacyUsage country versus customer country, the EU roaming fair-use test, retention without default durations, and pseudonymisation.
- Fraud signalsEvidence, never verdicts: the measurements that fired and the records behind them.
- Wire formatsThe X.690 framing a CDR arrives in, and the BCD and TBCD codecs for its fields.
- Design constraints and testingZero I/O, no async, no clock, exact integers, no unsafe: how each constraint is enforced and tested.