Acme Marketing Architecture

Layers Overview

Layers Overview

One band per layer, left to right: the three SaaS sources, ingestion into landing files, the anonymisation gate with its token vault, the Bronze, Silver and Gold medallion layers, and consumption. Icons mark each source and each medallion layer. Arrow labels name the job that moves data across a boundary. Colours in this diagram are the layer metals, not the C4 colour convention of the other views.

flowchart LR
    subgraph SRC["Sources"]
        SF["☁️ Salesforce<br/>CRM"]
        HS["🧲 HubSpot<br/>marketing automation"]
        GA["📣 Google Ads<br/>paid media"]
    end
    subgraph ING["📥 Ingestion"]
        AD["Adapters<br/>copy activity, HubSpot adapter with webhook nudges, Google Ads adapter"]
        L["🗂️ Landing files<br/>identifiers, kept at most 7 days"]
    end
    subgraph GATE["🔐 Anonymisation gate"]
        AG{{"Classify, scan, tokenise<br/>inside the Bronze loader"}}
        V[("🗝️ Token vault<br/>Azure SQL, CMK, PIM")]
    end
    subgraph BZ["🥉 Bronze"]
        B[("lh_restricted.bronze<br/>append-only, tokens only, provenance")]
    end
    subgraph SV["🥈 Silver"]
        S[("lh_restricted.silver<br/>typed, conformed, MERGE and SCD2")]
        C[("🧭 control schema<br/>ledger, watermarks, reconciliation")]
    end
    subgraph GD["🥇 Gold"]
        G[("lh_gold.gold<br/>star schema, allow-listed columns")]
        BE[("🔔 business_event<br/>CDF on")]
    end
    subgraph OUT["Consumption"]
        SM["📊 Semantic models<br/>Direct Lake, Power BI"]
        RP["📄 Report publication<br/>versioned, signed off, delivered"]
        EV["📨 Business events<br/>Service Bus to webhooks, SSE, Teams"]
    end
    SF --> AD
    HS --> AD
    GA --> AD
    AD --> L
    L -- "Bronze loader" --> AG
    AG -- "lookup-or-create" --> V
    AG -- "tokenised rows" --> B
    B -- "Silver jobs" --> S
    S -- "Gold jobs" --> G
    S -- "event job" --> BE
    G --> SM
    G --> RP
    BE -- "relay" --> EV
    classDef ext fill:#eef0f3,stroke:#8d939b,color:#1b1f24
    classDef bronze fill:#cd7f32,stroke:#8a5a1f,color:#ffffff
    classDef silver fill:#c9ccd1,stroke:#7d8288,color:#1b1f24
    classDef gold fill:#f2c230,stroke:#a98300,color:#1b1f24
    class SF,HS,GA ext
    class B bronze
    class S,C silver
    class G,BE gold

Layers

Layer Where it runs Holds Personal data Written by
☁️ 🧲 📣 Sources Salesforce, HubSpot, Google Ads (SaaS) The systems of record for CRM, marketing automation and paid media Identifiers The source owners
📥 Ingestion Restricted workspace: Fabric pipeline for the Salesforce copy activity; coded adapters whose runtime the WP0b PoCs decide (ADR 8, Proposed); webhook receiver on Azure Functions (ADR 3) Landing files, one manifest per extraction window Identifiers, for at most 7 days Adapters
🔐 Anonymisation gate Inside the Bronze loader; the vault is an Azure SQL Database under a customer-managed key, Entra-only, PIM access (ADR 6) Token vault: the identifier-to-token mapping, the only durable store of identifiers The mapping itself Bronze loader, lookup-or-create
🥉 Bronze lh_restricted.bronze schema What each source said, when: append-only, provenance columns on every row Tokens only Bronze loader
🥈 Silver lh_restricted.silver schema; the control schema sits next to it with the ledger, watermarks and reconciliation counts shared by every job Typed, conformed current state (MERGE) and history (SCD2) per entity Tokens only Silver jobs
🥇 Gold lh_gold.gold schema in the analytics workspace Star schema with allow-listed columns (gold-star-schema.md); business_event with Change Data Feed on Tokens only Gold jobs: event job every 15 minutes, star build hourly or nightly
Consumption Analytics workspace for semantic models and the report generator; Azure Service Bus and its consumers for business events Direct Lake semantic models, published reports with sign-off and lineage (ADR 11), business events to webhooks, the push gateway and Teams (ADR 7) Tokens only Relay, report generator, delivery adapter

Layer rules, write patterns, retention and Delta settings per layer: data architecture and ADR 2. The same flow with the push and poll paths, the reconciler and the downstream fan-out drawn in full: data-flow-medallion.md.

Icons

Icon Meaning
☁️ 🧲 📣 Salesforce, HubSpot, Google Ads
📥 🗂️ Ingestion, landing files
🔐 🗝️ Anonymisation gate, token vault
🥉 🥈 🥇 Bronze, Silver, Gold
🧭 🔔 Control schema, business events
📊 📄 📨 Semantic models, report publication, event delivery

Icons are Unicode characters, so the diagram renders the same on GitHub, in VS Code, in Obsidian and on the Pages site without an icon pack or web font. Abbreviations: CMK = customer-managed key; PIM = Privileged Identity Management; SCD2 = slowly changing dimension type 2; CDF = Delta Change Data Feed; SSE = Server-Sent Events.