ION DocsV3
  • Architecture
    • ION Architecture V2
      • ION V2 — Architecture Overview
      • V2 context
        • V2 capacity model
        • V2 constraints
        • V2 integration boundaries
        • V2 requirements
        • V2 solution strategy
      • V2 Structural Design
        • ION V2 Landscape
        • ION V2 Platform Views
          • ION V2 Delivery and Runway
          • ION V2 Incident-Processing Pipelines
          • ION V2 Platform Networking
          • ION V2 Platform Observability
          • ION V2 Platform Security
        • ION V2 System Context
        • ION V2 Systems
          • Alya System Topology
          • Cogs System Topology
          • Ion IQ System Topology
          • Kingsman System Topology
          • Pigeon System Topology
          • Veritas System Topology
          • Watchtower System Topology
      • V2 evolution and platform lineage
        • Tiberium Origins
          • Tiberium Architecture Overview
          • Tiberium Components Architecture Overview
        • Voyager and the V2 Merge
          • Voyager Architecture Overview
          • Voyager Identity Architecture Overview
          • Voyager Services Architecture Overview
      • V2 Platform Architecture
        • Alya Workbench
          • Mission Brief: Alya (Workbench for Cyber Defenders)
        • Asset Discovery
        • Automation
        • Customer Communications
          • Notification and Escalation Design
        • Reporting and Dashboards
        • Vulnerability Mitigations
      • V2 Well-Architected
        • V2 Reliability
          • Availability Architecture
        • V2 Security
          • API Management
            • API Management Architecture
            • API Management Guidelines
            • API Management Implementation
              • APIM Deployment and Debugging
              • APIM Global Policy Implementation
              • APIM Platform Provisioning
              • APIM Policy Authoring
              • APIM Service Onboarding
              • APIM Webhook Flow Implementation
            • API Management Policy Model
          • V2 Security Architecture
          • Teams Notification Security
          • Customer Data and PII
          • V2 Identity
            • Applications and Authorization
            • V2 Identity Architecture
            • Microsoft Entra ID
            • V2 Identity Standard
            • V2 Identity Implementation
              • Application Registration
              • Application Roles
              • Customer Identity Onboarding
              • Identity Lifecycle and Operations
              • Managed Identity
            • V2 Identity Workflows
              • Alya Workbench Identity Workflow
              • Customer Portal Identity Workflow
              • Microservices Identity Workflow
              • ServiceNow Inbound Identity Workflow
              • Microsoft Teams Identity Workflow
          • Customer Environment Access
            • Customer Environment Access Architecture
            • Customer Environment Access Guidelines
            • Customer Environment Access How-to
    • ION Architecture V3
      • ION V3 Architecture Overview
      • V3 context
        • V3 capacity model
        • V3 constraints
        • V3 integration boundaries
        • V3 requirements
        • V3 solution strategy
      • V3 Structural Design
        • Data and events
          • Archival and retention
          • Event model
          • Event sourcing
          • Event store
          • Micro-frontend interaction
          • Recovery and disaster recovery
          • Replay and reconstruction
          • Reporting and customer analytics
          • Event-sourcing requirements
          • Snapshots
          • UI interaction
        • ION v3 domains
          • Assets domain
            • Assets domain flows
            • Assets domain implementation
            • Assets domain model
          • Customer Collaboration domain
            • Customer Collaboration domain flows
            • Customer Collaboration domain implementation
            • Customer Collaboration domain model
          • Incident domain
            • Incident domain flows
            • Incident domain implementation
            • Incident domain model
          • Investigation domain
            • Investigation domain flows
            • Investigation domain implementation
            • Investigation domain model
          • Remediation domain
            • Remediation domain implementation
            • Remediation domain model
          • Ticket domain
            • Ticket domain flows
            • Ticket domain implementation
            • Ticket domain model
        • ION V3 Landscape
        • ION V3 Platform Views
          • Internal API
            • Internal API architecture
            • Internal API consumer guide
            • Internal API identity and access
            • Internal API implementation
          • Micro-Frontends
            • Micro-Frontends architecture
            • Micro-Frontends capability service (Signet)
            • Micro-Frontends composition
            • Micro-Frontends identity and access
            • Micro-Frontends implementation
            • Micro-Frontends real-time (SignalR)
            • Micro-Frontends routing and ingress
            • Shells and MFEs
          • SOAR Integration
            • SOAR Integration architecture
            • SOAR Integration customer onboarding
            • SOAR Integration Identity and Access Design
            • SOAR Integration implementation
            • SOAR Integration operations
        • ION V3 System Context
        • ION V3 systems
          • Alya
          • Cogs
          • ION IQ
          • Kingsman
          • Pigeon
          • Veritas
          • Watchtower
      • V2 to V3 evolution
        • V2 to V3 architecture delta
        • V2 to V3 decision changes
        • V2 to V3 migration guidance
        • V2 to V3 service impact
      • Well-Architected
        • Cost Optimization
          • Cost Governance
            • Cost Governance Architecture
            • Cost Governance Guidelines
            • Cost Governance Implementation
          • SKU Strategy
            • SKU Strategy Architecture
            • SKU Strategy Guidelines
            • SKU Strategy Implementation
        • Operational excellence
          • Audit Logs
            • Audit Logs Architecture
            • Audit Logs Guidelines
            • Audit Logs Implementation
          • CI/CD Runway
            • CI/CD Runway Architecture
            • CI/CD Runway Guidelines
            • CI/CD Runway Implementation
          • Feature Flags
            • Feature Flags Architecture
            • Feature Flags Guidelines
            • Feature Flags Implementation
          • Incident management
            • Incident management architecture
            • Incident management guidelines
            • Incident management implementation
          • Azure Landing Zone
            • Azure Landing Zone Architecture
            • Azure Landing Zone Guidelines
            • Azure Landing Zone Implementation
          • Notifications
            • Notifications Architecture
            • Notifications Guidelines
            • Notifications Implementation
          • Observability
            • Observability Architecture
            • Observability Guidelines
            • Observability Implementation
        • Performance efficiency
          • Capacity, sizing, and scaling
            • Capacity, sizing, and scaling architecture
            • Capacity, sizing, and scaling guidelines
            • Implement capacity, sizing, and scaling
          • UI responsiveness
            • UI responsiveness architecture
            • UI responsiveness guidelines
            • Implement UI responsiveness
        • V3 reliability
          • Application resilience patterns
          • Critical flows
          • Customer reliability assurance
            • ION Platform reliability and service continuity
            • Customer reliability slides
          • Disaster recovery
            • Disaster recovery architecture
            • Disaster recovery guidelines
            • Disaster recovery implementation
              • DR implementation: API Management
              • DR implementation: App Configuration
              • DR implementation: Application Gateway
              • DR implementation: Azure SQL Database
              • DR implementation: Container Apps
              • DR implementation: Container Registry
              • DR implementation: Cosmos DB
              • DR implementation: Event Hubs
              • DR implementation: Azure Front Door
              • DR implementation: Function Apps
              • DR implementation: Key Vault
              • DR implementation: Log Analytics and Application Insights
              • DR implementation: MySQL Flexible Server (Temporal)
              • DR implementation: PostgreSQL Flexible Server
              • DR implementation: Azure Managed Redis
              • DR implementation: Service Bus
              • DR implementation: SignalR
              • DR implementation: Storage accounts
            • Operational-data replication
            • Disaster recovery operations
          • Edge and routing
            • Azure Application Gateway
              • Azure Application Gateway architecture
              • Azure Application Gateway guidelines
              • Azure Application Gateway implementation
              • Azure Application Gateway resiliency
              • Azure Application Gateway security
            • Azure Front Door
              • Azure Front Door architecture
              • Azure Front Door guidelines
              • Azure Front Door implementation
              • Azure Front Door resiliency
              • Azure Front Door security
          • Event-store disaster recovery (moved)
          • Failure mode analysis
          • Graceful degradation
            • Graceful degradation architecture
            • Graceful degradation guidelines
            • Graceful degradation implementation
          • V3 reliability maturity model
            • V3 reliability maturity assessment
            • Maturity level 2: self-preservation
            • Maturity level 3: recovery readiness
            • Maturity level 4: maintain stability
            • Maturity level 5: stay resilient
          • Multi-region replication
            • Multi-region replication architecture
            • Multi-region replication guidelines
            • Multi-region replication implementation assessment
          • Reliability testing
          • Scaling and headroom
          • Targets and health model
          • Trade-offs and accepted risks
        • V3 Security
          • API Management
            • API Management Architecture
            • API Management Guidelines
            • API Management Implementation
              • API Contracts and Asynchronous Operations
              • APIM Deployment and Debugging
              • APIM Global Policy Implementation
              • APIM Platform Provisioning
              • APIM Policy Authoring
              • APIM Service Onboarding
              • APIM Webhook Flow Implementation
            • API Management Policy Model
          • V3 Security Architecture
          • Data protection
            • Data protection architecture
            • Data protection guidelines
            • Data protection implementation guidelines
              • API Management
              • Application Gateway
              • Azure SQL Database
              • Azure Container Apps
              • Azure Cosmos DB
              • Azure Front Door
              • Azure Function Apps
              • Azure Database for MySQL
              • Azure Database for PostgreSQL
              • Data protection procedures
          • V3 Security Guidelines
          • V3 Identity
            • Applications and Authorization in ION V3
            • V3 Identity Architecture
            • Capabilities
            • Microsoft Entra ID for ION V3
            • V3 Identity Standard
            • V3 Identity Implementation
              • App Service Authentication
              • Application Registration
              • Application Roles
              • Customer Azure RBAC
              • Customer Identity Onboarding
              • Identity Lifecycle and Operations
              • Mailbox-Scoped Access
              • Managed Identity
              • Workload Identity Federation
            • V3 Identity Workflows
              • Alya Workbench Identity Workflow
              • Customer Azure RBAC Identity Workflow
              • Customer Portal Identity Workflow
              • Mailbox Access Identity Workflow
              • Microservices Identity Workflow
              • ServiceNow Inbound Identity Workflow
              • Shell and MFE Identity Workflow
              • Microsoft Teams Identity Workflow
          • Customer Environment Access
            • Azure Lighthouse
              • Azure Lighthouse implementation
            • GDAP and Tenant Governance
              • Access Packages (legacy)
              • GDAP human access implementation
            • Customer environment access guidelines
            • Multi-tenant Entra apps
              • Multi-tenant Entra apps implementation
            • Teams B2B Direct Connect
              • Teams B2B Direct Connect implementation
          • Network Security
            • Network Security Architecture
            • Network Security Guidelines
            • Network Security Implementation
              • Egress and Static IPs
              • Resource Access Restrictions
          • V3 Security Patterns
    • ION Architecture V4
      • How V4 evolves from V3
  • Principles
  • Patterns
    • Application Permissions Only
    • Async REST
    • Audit Logs (Pattern)
    • Auth / AuthZ
    • Dead Letter Queue (DLQ)
    • Dual Writes (and how to avoid them)
    • ECST — Event-Carried State Transfer
    • Event Hubs Throttling
    • Feature Flags (Pattern)
    • Idempotent Write
    • MFE UI Interaction
    • Notifications (Pattern)
    • Private Data Store Access
    • Schema Evolution
    • Service Bus Topic Throttling
    • UI Interaction with an Event-Sourced Backend
  • Standards
    • API Standard
    • API Standards
    • Coding Standard
    • Coding Standards
    • Documentation Standard
    • Documentation Standards
    • Microservice Standard
    • Microservice Checklist
    • Operational Readiness Standard
    • ORR — Operational Readiness Review Checklist
  • Decisions
    • ADR-0001
    • ADR-0002
    • ADR-0003
    • ADR-0004
    • ADR-0005
    • ADR-0006
    • ADR-0007
    • ADR-0008
    • ADR-0009
    • ADR-0010
    • ADR-0011
    • ADR-0012
    • ADR-0013
    • ADR-0014
    • ADR-0015
    • ADR-0016
    • ADR-0017
    • ADR-0018
    • ADR-0019
    • ADR-0020
    • ADR-0021
    • ADR-0022
    • ADR-0023
    • ADR-0024
    • ADR-0025
    • ADR-0026
    • ADR-0027
    • ADR-0028
    • ADR-0029
    • ADR-0030
    • ADR-0031
    • ADR-0032
    • ADR-0033
    • ADR-0034
  • Services
  • Governance
    • Assumptions
    • Discrepancies
    • V3 reference coverage and conflict matrix
OntinueION Docs
  1. Decisions
  2. Event Sourcing as the persistence strategy

Event Sourcing as the persistence strategy

activereliability
decisionsv3v4active0006event-sourcingpersistencecqrsauditreplayv3-foundational

ADR-0006 — Event Sourcing as the persistence strategy

Forces / Drivers

  • Requirement / Constraint:
    • ../context/requirements.md#fr-2-event-store — FR-2 Event store: durable, append-only, versioned, stream-based, immutable.
    • ../context/requirements.md#fr-7-auditing-and-replayability — FR-7 Auditing + replay: complete history per aggregate, replayable to any point in time, per-user / per-entity / per-customer query.
    • ../context/requirements.md#nfr-2-reliability — NFR-2 Reliability: SLO 99.9 %, RTO 1 h, RPO 0 (no data loss).
    • ../context/constraints.md#tc-4-eventual-consistency — TC-4 Eventual consistency across systems is accepted; strong consistency required per-aggregate.
    • ../context/constraints.md#bc-3-compliance-and-regulatory — BC-3 Compliance (GDPR / HIPAA / PCI DSS): auditable trail; per-customer deletion on off-boarding.
    • ../context/capacity-model.md#derived-processing-load — At the 1,000-customer reference envelope: approximately 208M domain events/month (D9: 20 events/incident × approximately 10.4M incidents/month); six months hot plus one year cold retention.
  • Principle(s) embodied: § 8 Event Sourcing, § 7 ECST, § 6 Choreography, § 3 DDD modelling.
  • WAF pillar optimized: reliability (primary); operational-excellence, performance-efficiency, security (secondary).

Context

V2 used a traditional operational store per bounded context: an aggregate’s current state was the row (or document), mutated in place; history — where kept at all — lived in a bolted-on audit log or in the source system (Sentinel, ServiceNow). Three forces made this untenable for V3:

  1. Auditability as a hard requirement, not a feature. As an MXDR provider, every state transition on a security incident, ticket, or investigation is a compliance artefact. “Who changed the status of incident X to AutoClosed at 03:12 UTC, on the strength of which enrichments, in reaction to which upstream Sentinel event?” must be answerable years after the fact — not “usually” answerable from log queries. V2’s audit-log-as-side-effect could not guarantee this without heroic effort per query.

  2. Replay as a routine operation. The V3 platform runs many downstream projections — operational stores, reporting/dashboard stores, external integrations (ServiceNow, Sentinel writeback), automation triggers (Cogs), notifications (Pigeon), AI investigator inputs (ION IQ). Any of these can be added later, changed later, or need to backfill. In a state-store world, every backfill is a bespoke migration script against the source system’s API — expensive, fragile, rate-limited (see TC-2 external API ceilings). If the log is the source of truth, backfill is replay the log into the new projection.

  3. Choreography (ADR-0003) needs a source of truth for events. ADR-0003 makes events the coordination substrate; ADR-0004 makes events carry state; ADR-0005 makes the event schema a first-class contract. If events are the currency of the platform, the natural persistence primitive is not “the current state” but “the append-only sequence of events that produced it”. Anything else creates a dual-write problem (write to state store + publish to broker) that has to be solved with outbox patterns and CDC anyway (see patterns/handling-dual-writes.md). Event Sourcing dissolves the dual-write problem: the event is the state change.

At the same time, the pattern is not universally applicable. Every service adopting event sourcing pays a real cost: aggregate design becomes load-bearing; projections need to be authored and maintained; read-your-writes semantics do not come for free; event schema evolution has to be disciplined (ADR-0005 is a prerequisite, not an afterthought). The decision is not “everything is event-sourced everywhere” — it is “event sourcing is the default persistence strategy for domain aggregates whose history matters, and V3 identifies which aggregates those are”.

Decision

V3 adopts Event Sourcing as the persistence strategy for domain aggregates whose history is a first-class product concern. Concretely:

  • The event log is the system of record. For each in-scope aggregate, every meaningful state transition is captured as an immutable, versioned, timestamped domain event appended to that aggregate’s stream in an event store. The event store is authoritative; any other representation of state is a projection.
  • Streams are per-aggregate. Stream ID = <AggregateType>-<AggregateId> (e.g. SecurityIncident-{incidentId}). Streams are the unit of write consistency: atomic append + optimistic-concurrency check per stream.
  • In-scope aggregates for V3:
    • Incident (owned by Watchtower) — ../references/ION v3- Incidents Event Store.md
    • Ticket (owned by Watchtower’s ServiceNow integration boundary) — ../references/ION v3- Tickets Event Store.md
    • Investigation (owned by the Investigation domain) — ../references/ION v3- Investigation Event Store.md
    • Additional aggregates (customer collaboration, assets, vulnerabilities) evaluated per the adoption test below.
  • CQRS is the read model. The event log is the write model; projections into query-optimised stores (operational DBs, reporting store, cache) are the read models. Projections are recomputable from the log by replay. See ../references/ION v3- Reporting Data Store.md.
  • Events are notified downstream via broker subscriptions, not dual writes. Change Feed / CDC-style projection from the event store into a message broker eliminates the dual-write problem (patterns/handling-dual-writes.md).
  • Consistency posture: strong within a stream (per-aggregate optimistic concurrency, atomic append); eventual across streams and projections — this is the TC-4 acceptance, not an accident.
  • Retention: hot 6 months (queryable at write-store latency), cold 1 year (archived; replay-capable but higher-latency). Beyond 1 year: subject to per-customer archival / deletion policy (BC-3).
  • Schema discipline is ADR-0005. Events use CloudEvents envelope + AsyncAPI-described payloads; every event carries type with .vN versioning; backward-compat evolution rules apply.

Adoption test — an aggregate is event-sourced when at least two of the following hold: (a) its history is a compliance or product requirement (audit, timeline, replay); (b) multiple downstream projections consume its state; (c) it is coordinated cross-system via events already (ADR-0004); (d) rebuild-from-scratch of downstream stores must be possible without upstream re-fetch. Aggregates failing this test — configuration data, key-asset store, ephemeral operational state — use conventional persistence.

Explicitly out of scope for event sourcing: the Key Asset Store (Veritas), configuration/customer registry, cache tiers, and the reporting projection itself. Event sourcing is the source-of-truth pattern for domain aggregates; it is not a database category.

Technology choice deliberately deferred to a separate ADR — see ADR-0007 (planned: Cosmos DB as event store technology). This ADR is about the pattern; the technology decision must survive on its own merits.

Alternatives considered

  • Option A — Traditional CRUD state store + audit log as a side effect. The V2 posture. Rejected because: (i) audit log is a best-effort side effect, not a system-of-record — reconstructing history requires trust in log completeness, which cannot be guaranteed without transactional coupling; (ii) creates the dual-write problem (state store + broker) that has to be solved with outbox or CDC patterns anyway; (iii) backfilling a new downstream projection means bespoke migration against upstream APIs, hitting TC-2 rate limits and losing history that upstream systems do not preserve.

  • Option B — Change Data Capture (CDC) on the operational database as the “event stream”. Rejected because: (i) CDC events are database-row change records, not domain events — they leak schema and lose intent (a status change from Open → AutoClosed looks the same as a manual Open → Closed at the row level, but they are different domain events with different downstream consequences); (ii) CDC couples every consumer to the write-model schema, defeating volatility-based decomposition (ADR-0002); (iii) evolving the write-model schema breaks every CDC consumer, which is precisely the coupling ADR-0005 eliminates.

  • Option C — Event sourcing on a distributed log broker (Kafka / Event Hubs) as the store itself. The “log as database” approach. Rejected as the persistence primitive because: (i) Event Hubs retention is capped (max 90 days on Premium, ≤ 7 days on Standard) — insufficient for the 6-month hot / 1-year cold retention (D10); (ii) point-read latency on a log broker is not competitive with a document store for stream reconstruction on the command path; (iii) log brokers are optimised for throughput and sequential read, not for the aggregate read pattern (read all events for stream X, in order, in one transaction) that Event Sourcing requires. Event Hubs is also not part of the V3 internal event backbone (see ADR-0008).

  • Option D — Hybrid: event source only some aggregates, CRUD the rest, connect via outbox. Rejected as the platform default rule — but adopted as the outcome of the adoption test. The pattern-level decision is that event sourcing is the default for aggregates passing the adoption test; the adoption test itself acknowledges that not everything qualifies. Making hybrid the default would fragment discipline: engineers would default to CRUD (the more familiar option) and every event-sourced aggregate would need to be justified individually. The adoption test flips the burden of proof.

  • Option E — Adopt an off-the-shelf event-sourcing framework (EventStoreDB, Marten). Rejected on two independent grounds. First, § 21 Azure-native managed services first — EventStoreDB has no Azure PaaS offering; adopting it as the pattern’s substrate would commit ION to a second self-hosted stateful cluster forever (the tech-choice consequences of this are formally discharged in ADR-0007). Second, at the pattern level: (i) ION services live in multiple language stacks (TypeScript, Python, C#) and framework maturity varies wildly across them; (ii) the pattern is well-understood and the primitives (append, optimistic concurrency, read stream, project change feed) are small — a shared library across services beats a per-language framework; (iii) frameworks tend to bring their own storage assumptions, defeating the ADR-0007 deferral.

Rationale

Event Sourcing wins on the four requirements that the V2 posture could not meet without heroic effort:

  • Auditability by construction. FR-7 becomes a query, not a project. The log is the audit trail; any question of the form “what was the state of aggregate X at time T?” or “what caused the transition Y → Z?” is answerable by reading a stream — no separate audit-log system to keep in sync, no gaps.
  • Replay by construction. Adding a new projection (a new dashboard view, a new external integration, a new AI investigator input) is “subscribe to the change feed from timestamp T and project forward”. Rebuilding a corrupted projection is “truncate the projection, replay the log”. Neither operation requires touching upstream systems or hitting their rate limits.
  • Choreography’s natural persistence primitive. ADR-0003 makes events the coordination substrate. Event Sourcing makes events the persistence substrate. The two align: a service that changes state emits an event, and emitting the event is the state change. No dual-write. No outbox pattern needed at the aggregate boundary (still needed at broker-fan-out — see patterns/handling-dual-writes.md).
  • RPO 0 becomes tractable. Append-only writes to a durably-replicated store, with the change feed as the fan-out mechanism, gives a clear DR story per store (see planned ADR: Event Store DR): if the store survives, no committed event is lost; if the store is lost, replay from the last snapshot + change-feed catch-up restores every downstream projection.

The trade-offs are real (see Consequences) — projection maintenance, aggregate design as a load-bearing decision, eventual consistency across projections, storage growth — but they are the right trade-offs for aggregates whose history is a product concern. The adoption test keeps event sourcing from being over-applied.

Consequences

Positive

  • Full auditability. Every state transition is a first-class, immutable, timestamped, attributed record. Compliance queries (GDPR right-to-erasure, incident-history discovery) reduce to stream reads.
  • Full replayability. New projections, corrupted projections, and downstream-consumer re-processing all reduce to change-feed subscription from a chosen offset. Backfill against upstream Sentinel / ServiceNow is no longer needed once the event is captured.
  • CQRS unlocks read-side scaling. Reporting store (V3-new — ../references/ION v3- Reporting Data Store.md) is a projection tuned for dashboard freshness; operational store is tuned for command-path reads; each scales independently on its own axis.
  • Temporal queries by default. “What did we know about this incident at 04:00 UTC?” is a stream read at that offset. This directly supports incident-response forensics — a real product feature.
  • Dual-write problem dissolves at the aggregate boundary. The event log is the single write; broker fan-out is a downstream projection, not a co-committed side effect.
  • Vendor-lock-in mitigation (§ 20). The event log is portable data; migrating a downstream projection (or the whole downstream stack) is easier than migrating a CRUD state store.
  • AI investigator (ION IQ) input surface is natural. The event log is literally what happened, in the order it happened, with intent captured. No feature-engineering pipeline needed on the write side.

Negative

  • Aggregate design becomes load-bearing. Getting the aggregate boundary wrong (too coarse → contention on the stream; too fine → cross-stream transactions needed) is much more expensive to fix than in CRUD. Requires up-front DDD discipline (§ 3).
  • Projection maintenance is real work. Every read model is a separately-authored, separately-deployed, separately-monitored component. Bug in a projection = rebuild the projection.
  • Read-your-writes on projections is not free. A command that appends to the log completes before the projection catches up. UIs must be designed for this (optimistic UI, projection versioning header, or session-consistent read-your-writes on the write store) — see ../references/Event Sourcing- MFE UI Interaction Design Pattern.md.
  • Storage growth is monotonic. At 1000-cust plan: ~208M domain events/month × ~2 KB = ~416 GB/month of event storage growth (before compression). Hot 6 mo alone is ~2.5 TB. Archival + tiering (hot → cold → deletion) becomes a hard operational requirement, not a nice-to-have. See ../context/capacity-model.md#data-volume-and-lifecycle.
  • Schema evolution is unforgiving. An event written today must deserialise a year from now. ADR-0005’s schema-evolution rules are a hard prerequisite; there is no “just migrate the row” escape hatch.
  • Debugging shifts. “What is the state of X?” is not a single row lookup — it is a stream reconstruction (or a projection query with a caveat about staleness). New engineers need to learn to read the log.
  • Eventual consistency across streams. Cross-aggregate invariants cannot be enforced transactionally — they become sagas or process managers (which V3 keeps out via ADR-0003 choreography). Requires explicit domain design to keep invariants inside single aggregates.

Neutral / follow-ups

  • ADR-0007 — Event store technology choice (Cosmos DB — pending). The pattern here is technology-agnostic; the tech decision has to survive its own analysis.
  • Snapshotting policy. V3 references note snapshots are unnecessary while streams stay under ~100 events per aggregate (typical for security incidents). Codified as a per-aggregate operational decision; reconstruction capacity is documented in Capacity, sizing, and scaling.
  • Archival policy. Hot (queryable) → cold (blob, replay-capable) → deletion (per-customer off-boarding). Documented in well-architected/reliability/dr/implementation/cosmos-db.mdx and well-architected/security/data-protection/.
  • Projection catalog. Projection ownership, freshness, and rebuild behavior are documented in the canonical V3 data and events design.
  • Idempotent-write pattern (patterns/idempotent-write.md) — every command handler must produce the same event on replay. Enforced at code-review and by unit tests.
  • Change-feed transport binding — how the event store’s change feed maps onto shared Service Bus topics + subscriptions. Documented under ADR-0008.

WAF Pillar Impact

  • Primary pillar: reliability — RPO 0, replayable recovery of projections, no data loss on the source-of-truth path, single write per state change (no dual-write to reconcile).
  • Secondary pillars:
    • operational-excellence — auditability by construction, debugging via replay, projection rebuild without upstream re-fetch. Turns runtime forensics into log reads.
    • performance-efficiency — CQRS enables per-read-model scaling; write path is append-only (best-case Cosmos performance profile); freshness targets tuned per projection independently.
    • security — immutable event log provides tamper-evident audit trail; per-customer partition scheme (stream ID prefix) enables clean off-boarding and data-residency scoping.
  • Trade-offs:
    • Sacrifices simplicity of “one row = current state” for the durability and replayability of the log.
    • Sacrifices storage cost (monotonic growth) for auditability and replay — tiering + archival policy is a hard operational requirement.
    • Sacrifices cross-aggregate transactional consistency for per-aggregate append-only guarantees and independent scaling.
    • Sacrifices projection freshness (eventual consistency) for read-model scaling and rebuild-ability.
    • Increases design cost per aggregate (DDD discipline is a prerequisite, not a nice-to-have).

Previous approach (V2)

V2 used per-bounded-context operational databases as the source of truth, with history captured — where captured at all — via bolted-on audit-log tables, Log Analytics workspace queries, or the source-system’s own history (Sentinel incident history, ServiceNow audit records). Three concrete pain points drove the change:

  1. Audit coverage was inconsistent. Whether a given state change was auditable depended on which service made it and whether the developer remembered to write an audit-log row. Compliance queries required stitching across systems and could not guarantee completeness.
  2. Adding a new consumer meant fetching from upstream. New dashboards, new reporting features, new external integrations all required re-fetching from Sentinel / ServiceNow — hitting rate limits (TC-2) and losing history the upstream systems did not preserve.
  3. The dual-write problem was pervasive. Every service that changed state and published an event had to solve write-then-publish reliability separately. Some used outbox, some used at-least-once + idempotent consumers, some just accepted lost publishes. Inconsistency was the norm.

V3 dissolves all three by making the event log the source of truth: audit is free, replay is free, dual-write is gone at the aggregate boundary.

The V2 posture is not fully deprecated — the adoption test explicitly keeps CRUD as the right choice for aggregates that fail the test. What changed is the default, and the identification of which aggregates in ION belong on which side of the line.

Amendments

  • 2026-10-15 — Reliability objectives pointer. The RTO 1 h and RPO 0 cited in this ADR are design objectives for the planned warm spare, not current guarantees. Current objectives are stated per scenario in the ADR-0017 amendment “Reliability objectives clarified”.

References

  • ../references/Architecture- Event Sourcing.md — the V3 event-sourcing requirements + rationale foundation (business + FR + NFR).
  • ../references/Event Sourcing- Design.md — the end-to-end command-to-projection design flow.
  • ../references/Event Sourcing- Event Store.md — event-store feature requirements + tech-comparison (feeds ADR-0007).
  • ../references/Event Sourcing- Event Model.md — the event-type inventory.
  • ../references/Event Sourcing- Security Incidents.md — Incident aggregate design + phased rollout plan.
  • ../references/Event Sourcing- Event Store Disaster Recovery.md — DR posture that this ADR enables (RPO 0).
  • ../references/Event Sourcing- UI Interaction Design Pattern.md, ../references/Event Sourcing- MFE UI Interaction Design Pattern.md — read-your-writes on projections at the UI boundary.
  • ../references/ION v3- Incidents Event Store.md, ../references/ION v3- Tickets Event Store.md, ../references/ION v3- Investigation Event Store.md — the three in-scope aggregates for V3.
  • ../references/ION v3- Reporting Data Store.md — the reporting projection.
  • ../references/Incident Bounded Context- Design.md — capacity envelope for the Incident event store.
  • ../references/Design Pattern- Idempotent Write.md, ../references/Design Pattern- Handling Dual Writes.md, ../references/Design Pattern- Audit Logs.md — supporting patterns.
  • External: Martin Fowler — Event Sourcing, Martin Fowler — Domain Event.

Related ADRs

  • Depends on:
    • ADR-0003 — choreography treats the event as coordination; ES treats the event as persistence. Same primitive, two roles.
    • ADR-0004 — ECST needs a durable source for event state; ES is that source.
    • ADR-0005 — event schema discipline is a prerequisite for a multi-year event log.
  • Enables:
    • ADR-0007 (pending) — Cosmos DB as event store technology.
    • ADR-0008 — Event backbone (shared Service Bus): change-feed → broker binding.
    • Pending: Event Store DR posture, Reporting data store choice, MFE UI interaction pattern.
  • Related:
    • ADR-0001 — the architecture style that assumes events as the primary interaction; ES makes that assumption durable.
    • ADR-0002 — each system owns its event streams; volatility containment applies to the event log too.

On this page

  • Forces / Drivers
  • Context
  • Decision
  • Alternatives considered
  • Rationale
  • Consequences
  • WAF Pillar Impact
  • Previous approach (V2)
  • Amendments
  • References
  • Related ADRs
PreviousCloudEvents + AsyncAPI as the event schema and description standard
NextAzure Cosmos DB (NoSQL API) as the event store technology
Edit on GitHubSecurity