Sync Topology
Delivery Hub runs across four Salesforce orgs in production. This page is the architecture map — what each node owns, what crosses each hop, what intentionally doesn't, and how a new customer plugs into the chain. Same content for two audiences: the customer who wants to understand the backend they're sitting on, and the prospect deciding whether this is what they want to run.
Most multi-org Salesforce architectures pick one tradeoff — single-tenant per customer (clean privacy, painful releases) or single-tenant for the vendor (clean releases, leaky privacy). Delivery Hub does neither. Each node owns the facts it's authoritative for, and the sync layer enforces a strict source-of-truth-per-fact invariant: a billing rate set on the vendor mothership cannot accidentally replicate into a customer org because the trigger handler excludes it before the payload is built.
The result: customer-facing surfaces edit work items, the vendor keeps commercial terms private, releases ship to a staging org that runs against real (sanitized) data before any customer sees them, and non-Salesforce stakeholders get a public portal view that's always reading the same data the internal teams are.
Four nodes, two directions, one source of truth per fact
Each node owns something the others can't replicate. The chain carries work forward; privacy constraints stop specific facts at specific hops.
- · WorkItem__c
- · WorkLog__c
- · NetworkEntity__c
- · WorkItem__c
- · WorkLog__c
- · NetworkEntity__c
- · SyncItem__c
- · WorkItem__c
- · WorkLog__c
- · NetworkEntity__c
- · DeliveryDocument__c (invoices)
- · Mothership REST reads
- · /push-to-dh writes
- · WorkItem__c
- · WorkLog__c
- · NetworkEntity__c
- · WorkItem__c
- · WorkLog__c
- · NetworkEntity__c
- · SyncItem__c
- · WorkItem__c
- · WorkLog__c
- · NetworkEntity__c
- · DeliveryDocument__c
- · Mothership REST reads
- · /push-to-dh writes
Vendor billing data lives ONLY on the mothership.
Vendor commercial terms (labor rate, invoice dollar amounts, vendor margin) live ONLY on the mothership. The relay sandbox — which the customer's integration team has access to — intentionally has these fields null / zero / excluded from sync payloads. The data that engineers see on the relay is the customer's own work, not the billing metadata. Invoices (DeliveryDocument__c where TemplatePk__c = 'Invoice') never replicate back into the customer's Salesforce org or the relay. The sync code excludes these fields by design.
What flows, what doesn't, and which direction
Each row is one SObject. Columns show the 3 hops in the chain. Privacy-sensitive objects stop at the right edges.
| Object | Customer ↔ Relay | Relay ↔ Mothership | Mothership ↔ Portal |
|---|---|---|---|
WorkItem__c | Bi-directional | Outbound only bi-directional rolling out | Portal push (one-way) portal reads via REST; writes via /push-to-dh |
WorkLog__c | Bi-directional | Outbound only bi-directional rolling out | Portal read-only |
NetworkEntity__c secrets NOT synced | Bi-directional | Bi-directional | Portal read-only |
DeliveryDocument__c split rule: invoices vs. other docs | Split rule Project docs: bi-directional (proposed) · Invoices: never | Split rule Project docs: bi-directional (proposed) · Invoices: never | Split rule Portal read-only for invoices; docs pull for display |
SyncItem__c sync ledger | Internal | Internal | N/A |
Dependency__c gap — should sync | Gap — should sync bi-directional Gap — should be bi-directional across all 3 hops. On roadmap. | Gap — should sync bi-directional Gap — should be bi-directional. On roadmap. | Gap — should sync bi-directional Gap — portal should surface dependency graph. On roadmap. |
Comment__c gap — should sync | Gap — should sync bi-directional Gap — comments should thread across orgs. | Gap — should sync bi-directional Gap — same rationale. | Gap — should sync bi-directional Gap — threaded comments should surface in portal. |
Invoices stay on the mothership. Other documents should flow.
Today: nothing in DeliveryDocument__c syncs across hops. Future rule: distinguish by TemplatePk__c.
TemplatePk__c = 'Invoice'. Privacy invariant holds — never replicate to relay or customer.WorkItem__c: what crosses, what stays
Source of truth is the trigger handler in the DH managed package. Anything not in this list does not propagate.
Three moving parts, zero shared secrets across the chain
Each pairwise hop has its own credential set stored on the NetworkEntity record. Loop prevention is stamped at the origin and checked at every receiver.
- ApiKeyTxt__c
- HmacSecretTxt__c
- IntegrationEndpointUrlTxt__c
- X-Signature: HMAC(secret, payloadJson)
- X-Global-Source-Id
- SyncItem.GlobalSourceIdTxt__c
What we're actively fixing
Every gap is tracked with a concrete mitigation path. Nothing is mystery-state.
WorkLog race on receiver
No portal write-back for UI edits
Dependency__c not bi-directional
Comment__c not bi-directional
Five steps to join the chain
Install the managed package, exchange credentials, verify round-trip. The first-sync test is the gate — if a WorkItem round-trips, the chain is live.
- 1
Install the DH managed package
Owner: Customer SF adminCustomer installs the Delivery Hub managed package in their production Salesforce org. Brings over WorkItem__c, WorkLog__c, NetworkEntity__c, SyncItem__c, plus the trigger handlers that power sync. - 2
Provision NetworkEntity records
Owner: VendorVendor creates paired NetworkEntity__c records in both orgs (customer + relay). Each points at the other's integration endpoint. One key per pairwise direction. - 3
API key + HMAC secret exchange
Owner: VendorGenerate and populate ApiKeyTxt__c and HmacSecretTxt__c on both NetworkEntity records. Keys exchanged via secure channel — not in source control or chat. - 4
Remote Site Settings on both sides
Owner: Customer SF adminEach org adds the counterpart's integration domain to Remote Site Settings. Without this, outbound callouts fail before auth. One of the top onboarding miss-steps. - 5
First sync test
Owner: Vendor + customer adminCreate one WorkItem__c in the customer org. Verify it lands in the relay within ~15 seconds, then in the mothership. Edit it in the relay and confirm the edit flows back. Round-trip confirms the chain is live.
What fully bi-directional looks like
The chain is healthy end-to-end on the customer-to-relay hop. Completing bi-directional behavior on the remaining hops unlocks true multi-surface editing.
Relay ↔ Mothership: full bi-directional
Next minorPortal edits round-trip
Future arcMulti-customer chain scaling
ProductizationDependency__c + Comment__c sync
PlannedInstalling Delivery Hub plugs your Salesforce org into the chain. Your team works inside your own org; work items flow to the relay for triage, then to the mothership for billing. Your production data stays yours — nothing vendor-side replicates back.
This is what you're evaluating. Free managed package, no per-seat fees, explicit privacy invariants enforced at the trigger handler. Install into a sandbox, run the round-trip test, decide.
Source of truth for field-level sync is the trigger handler in the DH managed package. Privacy excludes are enforced at the trigger handler, not downstream. If a field is listed, it syncs. If not, it doesn't.