Architecture
Delivery Hub is a 100% Salesforce-native managed package. No external servers, no middleware, no third-party databases. Everything runs on the Salesforce platform using standard objects, custom objects, Apex, and Lightning Web Components.
Data Model
Delivery Hub uses 7 core custom objects. All objects are namespaced under the managed package prefix.
| Object | Purpose | Key Relationships |
|---|---|---|
| WorkItem__c | The core unit of work. Represents a task, feature, or bug fix that moves through the delivery pipeline. | Parent of TimeLog, Comment, File attachments |
| WorkRequest__c | Inbound requests from clients or stakeholders before they become scoped work items. | Converts to WorkItem__c |
| SyncItem__c | Tracks cross-org synchronization state. Stores remote org IDs, sync timestamps, and conflict resolution data. | Lookup to WorkItem__c |
| TimeLog__c | Tracks developer time against work items. Supports manual entry and Ghost Recorder auto-capture. | Child of WorkItem__c |
| Dependency__c | Defines blocking relationships between work items (e.g., "Task B cannot start until Task A is done"). | Junction: WorkItem to WorkItem |
| ConnectedOrg__c | Stores connection metadata for linked Salesforce orgs (OAuth tokens, org ID, sync preferences). | Referenced by SyncItem__c |
| DeliveryConfig__c | Org-level configuration: default stage mappings, AI settings, working hours, sprint length. | Singleton (Custom Setting or Custom Metadata) |
Sync Engine
The cross-org sync engine enables two Salesforce orgs to share work items bidirectionally. It operates on a push/pull model:
1. Outbound Push
When a work item is updated in the source org, a Platform Event fires. An Apex trigger serializes the change and sends it to the remote org via a REST callout to /delivery/sync.
2. Inbound Pull
The receiving org processes the payload, creates or updates the matching SyncItem__c and WorkItem__c, and sends an acknowledgment back.
3. Echo Suppression
Each sync payload carries a unique transaction ID. The receiving org stores this ID so that when the inbound update triggers its own outbound push, the echo is detected and suppressed, preventing infinite loops.
Namespace Handling
Delivery Hub is distributed as a managed package with a registered namespace. All custom objects, fields, Apex classes, and LWC components are namespaced. When referencing Delivery Hub objects in your own code:
- •In Apex, use the fully qualified name:
dlhub__WorkItem__c - •In SOQL, the namespace prefix is required in cross-namespace queries
- •In LWC, import with the namespace:
import WorkItem from '@salesforce/schema/dlhub__WorkItem__c'
Lightning Web Components
The UI is built entirely with Lightning Web Components. Key components include:
- •Kanban Board — Drag-and-drop board with 40+ configurable stage columns
- •Work Item Detail — Full record view with tabs for comments, files, time logs, and dependencies
- •System Pulse — Dashboard showing work items by status, priority, assignee, and ETA
- •Ghost Recorder — Background time tracker that auto-logs developer activity
- •Sync Monitor — Real-time view of cross-org sync status and error logs
Continue Reading
- Features — full feature reference
- API Reference — REST sync endpoints and payloads