HOPPER-EDW ISSUE #183 Business Vault SCD2 Architecture

Identity, Cutover & Survivorship

"Three contracts, three homes, wired only by name." Zero regression; decoupled grains, time windows, and attribute ranks.

Decoupled
3 Objects
Fallback
SortedMerge
1. Identity Resolution Physical Table

BvIdentityMap

Clusters raw hub hashes (hk_raw) into a single durable surrogate key (hk_durable).

Canvas Grain: Shared by Concept
SCD2 Pointer: identityMapName
Golden Rule: Frozen on First Assignment
2. Source Cutover Metadata Only

BvSourceCalendar

Declares temporal eligibility windows for source systems. Compiled directly into SQL WHERE bounds.

Canvas Grain: Shared Dates / Systems
SCD2 Pointer: sourceCalendarName
Interval Type: [effectiveFrom, effectiveTo)
3. Survivorship Pipeline Merge

SurvivorshipMerge

Field-level rank arbitration (Rank 1 > Rank 2) across multi-satellite timeline histories.

Canvas Grain: Per SCD2 Target Column
SCD2 Pointer: field_mapping.rank
Null Policy: inherit vs. apply + flags

End-to-End Pipeline Data Flow

How raw Data Vault assets pass through the three stages to materialize a consolidated BV SCD2 table

Click any stage box below to inspect its mechanics
Raw Storage
DV Satellites & Links
sat_person_oracle
sat_person_kafka
lnk_person_same_as
➔
Gate 1: SQL Filter
Source Calendar
WHERE ts >= from AND ts < to
Half-Open Bounds
➔
Gate 2: Lookup
Identity Lookup
hk_raw ➔ hk_durable
As-Of Temporal Match
➔
Gate 3: Arbitration
SurvivorshipMerge
Rank 1 > Rank 2
inherit / apply nulls
➔
Functional Result
BV SCD2 Timeline
valid_from / valid_to
Durable Key Grain
Decoupled Entity Clustering

Identity Map: Freezing the Durable Hash

An identity map resolves duplicate raw keys (hk_raw) across disparate source systems into a unified durable surrogate key (hk_durable).

Object: BvIdentityMap
Table: Physical table (upsert, not truncate)
Hop Transform: IdentityLookup
1

Freeze on First Assignment

When a cluster forms, hk_durable is created from MDM ID or the initial master raw hash. Once created, it is frozen forever.

2

Master Flip Resiliency

If CRM flips the preferred master from O100 to K100, hk_master and rule_version update, but hk_durable never changes. Downstream marts never break!

3

Preferred BK is Payload

The human-readable preferred_bk is carried as payload. It can be corrected in place without driving a spurious new SCD2 version row.

Durable Key Stability Mechanism

Load 1 (Initial Assignment) rule_version = 1
Same-as Link: O100 (Master) ➔ K100 (Dup)
hk_durable(O100) = HASH("O100")
hk_durable(K100) = HASH("O100") (Inherited)

Durable key is minted and snapshotted into map_person table.

Load 2 (Master Flips to K100) rule_version = 2
Same-as Link: K100 (Master) ➔ O100 (Dup)
hk_durable(O100) = HASH("O100") [FROZEN!]
hk_durable(K100) = HASH("O100") [FROZEN!]

Master pointer updates to K100, but the durable key remains immutable!

Unmapped Key Policies (unmappedPolicy)

Policy Action When No Map Interval Found Timeline Impact
self (default) Substitutes hk_durable = hk_raw. Entity passes through with its own raw identity until mapped.
quarantine Suppresses the row from main SCD2 stream and routes to quarantine. Only explicitly resolved business keys enter the Business Vault.
drop Silently discards the unmapped raw satellite row. Strict whitelist: unmapped history is ignored.