System Design Atlas

International humanitarian aid logistics

10 / 10Worked example

Final design

The end-to-end test ends with all goods accounted for. Which conditions ensure this outcome?

Dispatch confirmation alone does not prove arrival.

Starting point Documented disposition of the goods closes the investigation.

Assumptions for the example case

A fictional shipment of 100 boxes of hygiene supplies between a warehouse and a distribution point. Local inventory ownership remains clear; offline devices document assigned shipments. All quantities, thresholds and operational targets in this design are illustrative assumptions.

Aid supplies with evidence

Central allocation, local supporting documents

Warehouse interfaceContention
Offline transport devicelocal buffers
Logistics APIAllocation + clarification
Relational datastoreStock + S-49 + Inbox
Synchronization adapterOffline receipt
Evidence storeU-49 + disposition
Coordination viewDifferences
Warehouse interface → Logistics APIAllocation
Logistics API → Relational data storeS-49 + stock
Offline transport device → synchronization adapterU-49 from buffer
Synchronization adapter → Relational data storeEvent inbox + shipment
Synchronisation adapter → Evidence storeStore immutable handover record before changing quantities
Logistics API → Evidence storeStore disposal record
Coordination View → Logistics APIDifference Clarification

Only the API allocates available stock; the offline device submits events through the adapter to the same shipment records.

Topology from step 6 plus inventory contention, replay and damage resolution; links back to 4, 5, 9.

Test plan with expected outcomes

Input and initial stateExpected resultReturn to an earlier step
C-49 has 100 available → Attempt two allocations of 100 in both arrival ordersOne succeeds, the other is rejected; available stock 0.Step 5
U-49 stored with 98/2 → Identical replay; then 99/1 under the same identifierOne quantity effect; the changed replay conflicts.Step 4
S-49 dispatched 100 → Receipt sums 99/100/10199 leaves 1 unaccounted for; 100 can be fully accounted for; 101 conflicts without changing quantities.Step 2
98 accepted, 2 damaged → Accept the disposal record for 2 twiceResolved and completed; exactly 100 accounted for; originating warehouse stock remains unchanged.Step 5/10

C-49 has 100 available → Attempt two allocations of 100 in both arrival orders

Expected result
One succeeds, the other is rejected; available stock 0.
Return to an earlier step
Step 5

U-49 stored with 98/2 → Identical replay; then 99/1 under the same identifier

Expected result
One quantity effect; the changed replay conflicts.
Return to an earlier step
Step 4

S-49 dispatched 100 → Receipt sums 99/100/101

Expected result
99 leaves 1 unaccounted for; 100 can be fully accounted for; 101 conflicts without changing quantities.
Return to an earlier step
Step 2

98 accepted, 2 damaged → Accept the disposal record for 2 twice

Expected result
Resolved and completed; exactly 100 accounted for; originating warehouse stock remains unchanged.
Return to an earlier step
Step 5/10

End-to-end test and unresolved agreements

First end-to-end path
Allocate 100 boxes, dispatch offline and record receipt as 98/2; test duplicate synchronisation and close the damage case with a disposal record.
Clarify before real use
Customs, transfer of ownership, donor documentation, storage and actual responsibilities must be agreed for each mission.

The end-to-end test ends with all goods accounted for.

The end-to-end test ends with all goods accounted for.

Test offline replay and damage resolution together.

Dispatch confirmation alone does not prove arrival.

One successful allocation of 100; failures lead back to 5. 98 + 2 reaches closure with evidence; failures lead back to 2 and 9.

Alternative considered
The happy path overlooks lost quantities.
Trade-off
The test needs physical disposition categories.
Reassess
Extend to other goods after validating the evidence path.

Try it yourself

Map contention and damage tests to earlier design steps.

A hint for your attempt

Dispatch confirmation alone does not prove arrival.

Compare with a possible solution
Contention
One successful allocation of 100; failures lead back to 5.
Disposition
98 + 2 reaches closure with evidence; failures lead back to 2 and 9.

Apply to your project

How does “The end-to-end test ends with all goods accounted for” apply to your own project?

Transfer the decisions and their counterexamples to the editable design template.

Start your own design

Choose a small case from your project. The template collects the ten design tasks and leaves space for your sketches, decisions, and open assumptions. You can edit it in your text editor or note-taking app.

Download design template (.md)
Compare the ten tasks with the example case
  1. Purpose and boundary

    How does “Offline records document assigned goods” apply to your own project?

    In the example: New allocations remain the warehouse team's responsibility.

  2. Requirements

    How does “Every box needs an evidenced disposition” apply to your own project?

    In the example: The inventory balance distinguishes acceptance from damage.

  3. Scale estimates

    How does “Data buffers and goods use different units” apply to your own project?

    In the example: Calculate storage capacity and goods quantities separately.

  4. Interfaces

    How does “Event identifiers remain stable across offline retries” apply to your own project?

    In the example: Replay uses the same identifier and payload.

  5. Data and states

    How does “In transit is not a completed outcome” apply to your own project?

    In the example: The remaining goods' whereabouts stay unresolved until evidenced.

  6. Overall architecture

    How does “The offline buffer is not a second inventory ledger” apply to your own project?

    In the example: The synchronisation adapter accepts records; the API manages inventory.

  7. Critical flow

    How does “Resolve competing allocations before dispatch” apply to your own project?

    In the example: Allocation checks and reserves stock atomically.

  8. Bottlenecks and trade-offs

    How does “Missing files and missing goods require different actions” apply to your own project?

    In the example: Track technical discrepancies and physical discrepancies separately.

  9. Operations and security

    How does “Disposal closes the damage case” apply to your own project?

    In the example: Documented disposition of the goods closes the investigation.

  10. Final design

    How does “The end-to-end test ends with all goods accounted for” apply to your own project?

    In the example: Test offline replay and damage resolution together.