ADR-0001 — Event-Driven Microservices as the platform architecture style
Forces / Drivers
- Requirement / Constraint:
../context/requirements.md#nfr-1-scalability— NFR-1 Scalability (must ingest and process bursty incident volumes from Sentinel + Defender XDR).../context/requirements.md#nfr-4-latency— NFR-4 End-to-end latency < 5 min under normal load.../context/capacity-model.md— 1000-customer envelope requires ~80 domain events/s avg → 400/s peak; historical Tiberium stack peaked at ~270 inc/day and could not scale.../context/constraints.md#tc-1— Azure-only substrate.
- Principle(s) embodied:
§ 2 Microservices,§ 4 Event-driven microservices,§ 5 No direct service-to-service calls,§ 14 Independent scalability. - WAF pillar optimized:
performance-efficiency(primary);reliability,operational-excellence(secondary).
Context
ION V2 was consolidated post the Tiberium (low-code, synchronous Logic-Apps) + Voyager (Azure cloud-native) merge. Two forces made a synchronous, HTTP-centric microservices approach untenable:
- Volume growth trajectory. Tiberium’s ~270 incidents/day was already causing Logic-App execution counts of ~4.4 M/day for enrichment + triage + adaptive-card fan-out (
references/Architecture- Tiberium Architecture Review.md). The V2 envelope needed to hold hundreds of thousands of incidents/day at 500–1000 customers (../context/capacity-model.md#demand-scenarios) — a ~1000× growth trajectory over Tiberium. - Fan-out amplification. Each incident produces ~10 alerts, ~15 entities, and (in V3) ~20 domain events. Synchronous propagation of that fan-out through service-to-service HTTP calls would compound P99 latency multiplicatively at every hop and would tie producers to consumer availability. External API ceilings (Sentinel: ~75 writes / 5 min per subscription; Cloudflare: 1200 / 5 min; AbuseIPDB: 1000 / day) make synchronous back-pressure impossible to absorb without buffering.
The Tiberium review documented the concrete limits of the LCNC + synchronous approach: no zero-downtime deploys; no meaningful testability; hard-to-mock integrations; failure handling limited to Logic-App-native retries; monitoring an afterthought. Any replacement had to solve all four.
ION also had to support multiple independent bounded contexts (Incident, Investigation, Ticket, Customer Collaboration, Reporting) each with its own volatility profile, its own external integrations, and its own team ownership. Coupling them via synchronous APIs would surrender the very independence the decomposition existed to create.
Decision
Adopt Event-Driven Microservices as ION’s platform architecture style:
- Services are independently deployable and independently scalable units.
- All cross-service collaboration is asynchronous, over a shared broker (Azure Service Bus in V3 — see ADR-0008; Event Hubs retained only as a bounded protocol adapter at the external integration ingress edge).
- No service calls another service directly. Synchronous request/response is reserved for UI-inbound traffic terminating at BFF services, and for external adapter calls out of the platform (Sentinel API, ServiceNow API, threat-intel APIs).
- Every service exposes a Trilateral API (Publisher / Subscriber / REST —
§ 10); its published events are as much a first-class contract as its REST surface.
This decision is the foundation stone on top of which volatility-based decomposition (ADR-0002), choreography (ADR-0003), event-carried state transfer (ADR-0004), CloudEvents (ADR-0005), and event sourcing (ADR-0006) are built.
Alternatives considered
- Option A — Synchronous HTTP as the sole cross-service collaboration mechanism. Rejected. This is the choice being replaced, not the presence of HTTP itself — every ION service still exposes a REST surface as one leg of its Trilateral API (
§ 10), used for UI-inbound traffic and external adapter calls. What is rejected is cross-service domain collaboration over synchronous HTTP: fan-out amplification (10 alerts × 15 entities × 20 domain events per incident) makes tail-latency and cascading-failure risk unmanageable at the V2 capacity envelope; any consumer degradation directly propagates to producers; external API ceilings (Sentinel 75/5min) cannot be respected without a buffering hop, which reintroduces the broker anyway. - Option B — Modular monolith on Azure Functions or App Service. Rejected. Bursty ingestion and steady-state reporting have wildly different scaling axes; a monolith is scaled by its noisiest component. Deployment blast radius grows with the codebase. Loses independent team ownership of bounded contexts.
- Option C — Continue Logic-Apps-based orchestration (Tiberium approach). Rejected — see the Tiberium Architecture Review: LCNC platform has no viable testing / mocking / zero-downtime-deploy / version-control story; failure handling is limited to native retries; monitoring requires custom Log Analytics API calls per step (adding latency); ~4.4 M Logic-App executions/day at Tiberium’s small scale would explode by 79× at V3 planning.
- Option D — Actor-model runtime (Orleans / Akka). Rejected. Higher operational complexity than PaaS brokers; ties platform to a single framework and its cluster-management model; less mature Azure ecosystem than Event Hubs / Service Bus; more compute footprint per message than a broker + serverless consumer combination; harder to evolve service boundaries without cluster-level coordination.
- Option E — Central orchestration engine (e.g., a workflow engine as the message backbone). Rejected as the platform-wide style, though it re-emerges at a service-local scope in V3 with Temporal for orchestrating workflows within a bounded context. The platform-wide style stays choreographed (ADR-0003); Temporal orchestrates within a service’s boundary, not across service boundaries.
Rationale
The chosen option wins on four axes that the capacity model and Tiberium review made non-negotiable:
- Bursts absorbed at the broker, not at the producer. Service Bus queueing + session-based per-aggregate ordering + broker-native dedup and DLQ let each consumer scale independently on its own axis without producers having to know consumer capacity. Direct realisation of
§ 14 Independent scalability. - Failure containment. A slow or failing consumer backs up its own subscription; producers keep publishing. Combined with DLQ patterns (
../patterns/dlq.md), this bounds blast radius. Direct realisation of§ 17 Failure containment. - Volatility containment. Each service can change its schema (subject to CloudEvents versioning discipline — ADR-0005) without breaking consumers on a hot synchronous call path. Enables
§ 1 Volatility-based decomposition(ADR-0002). - Foundation for event sourcing. With events already the currency between services, adopting event sourcing as the persistence pattern in V3 (ADR-0006) is a natural evolution, not a substrate re-choice.
The Tiberium review’s four documented pain points — testability, deployment, failure handling, monitoring — each have a first-class solution in the event-driven microservices world (test doubles at the broker interface, blue-green per service, DLQ + retry policies per subscription, distributed tracing across events).
Consequences
Positive
- Producers and consumers evolve on independent schedules; deployment blast radius is one service.
- Horizontal scaling is per-service, on the axis that matters (queue depth, CPU, event lag).
- Broker buffers bursts up to the 5× peak factor from the capacity model.
- Natural fit for CQRS-style read/write separation in the event-sourced stores (ADR-0006).
- Enables
Trilateral APIas the service contract, elevating events to first-class citizens. - Easy to add new consumers of an existing event stream (open-for-extension) — new bounded contexts can subscribe without producer changes.
Negative
- Distributed-systems complexity is explicit: idempotency, ordering, exactly-once vs. at-least-once, eventual consistency — every service designer must reason about them.
- End-to-end flow tracing requires distributed tracing infrastructure (App Insights + traceparent) to be first-class from day one — cannot be added later.
- Broker is critical infrastructure. Its DR posture (RPO 0, RTO 1 h —
../context/capacity-model.md#service-targets) governs the platform’s DR posture. Broker outage = platform outage. - Schema-evolution discipline is non-optional (see
../patterns/schema-evolution.md, CloudEvents + AsyncAPI — ADR-0005). - Learning curve for engineers used to synchronous request/response; requires investment in patterns catalog + guidelines.
Neutral / follow-ups
- Requires a Dead-Letter Queue pattern per subscription (
../patterns/dlq.md) and observable poison-message handling (§ 17). - Requires an idempotent-write discipline (
../patterns/idempotent-write.md) since at-least-once delivery is the norm. - Requires the Async REST pattern (
../patterns/async-rest-api.md) for UI-facing operations that must return a promise-like handle rather than blocking on completion.
WAF Pillar Impact
- Primary pillar:
performance-efficiency— the decision optimises for independent scaling per service and burst absorption at the broker. Every downstream V2/V3 scaling decision (Cosmos DB partitioning, Service Bus messaging-unit sizing on the shared namespace, Temporal cluster shard count) inherits from this style. - Secondary pillars:
reliability— failure containment via broker isolation + DLQ. Broker-mediated coupling is loose enough that a failing service does not fail its producers.operational-excellence— services deploy independently, own their own release cadence, and are testable in isolation.
- Trade-offs:
- Sacrifices the simplicity of synchronous call chains and their linear traceability.
- Adds operational cost of running the broker at 99.9 % SLO + zone-redundant configuration.
- Adds cognitive cost of distributed-systems reasoning for every service designer.
References
../references/Architecture- Tiberium Architecture Review.md— documents the concrete limits of the synchronous LCNC approach that this ADR replaces.../references/Architecture- Ontinue ION V2.md— V2 architecture consolidation; the event-driven microservices style is captured as the design decision here.../references/Architecture- Ontinue ION v3.md— carries the same style into V3 with event sourcing layered on top.../references/Architecture V2- Capacity Model.mdand../references/ION v3- Capacity Model.md— the growth trajectory that forces asynchronous decoupling.../context/capacity-model.md— the derived-load view driving the numbers cited above.
Related ADRs
- Enables (built on this ADR):
- ADR-0002 — Volatility-based decomposition.
- ADR-0003 — Choreography over orchestration.
- ADR-0004 — Event-Carried State Transfer.
- ADR-0005 — CloudEvents + AsyncAPI as event schema standard.
- ADR-0006 — Event Sourcing as the persistence strategy.
- Depends on: none — this is a foundational ADR.
- Related: ADR-0008 (Event backbone: shared Service Bus — the substrate), ADR-0011 (Shared APIM topology — the sync entry point that terminates at BFF).