Architecture
Built for Salesforce. Engineered for Scale.
Delivery Hub is a Salesforce-native managed package with zero external dependencies. The entire stack -- custom objects, Apex services, LWCs, Custom Metadata, and platform events -- runs on the Salesforce platform. An external portal at cloudnimbusllc.com provides authenticated client access without requiring Salesforce licenses.
Platform Stack
Seven layers, zero external dependencies. Click any layer to explore.
Key Services
Core Apex services that power Delivery Hub's engine.
DeliveryWorkflowConfigService
Dynamic Workflow Engine
Resolves workflow types, stages, transitions, and persona views from Custom Metadata at runtime. 5 methods that power every stage gate, board column, and transition rule in the system.
DeliveryVelocityService
Velocity & Capacity Metrics
Team and developer velocity, capacity utilization, projected completion dates, and what-if scenario analysis. Powers the Velocity Dashboard with per-developer weekly capacity from DeveloperCapacity__mdt.
DeliveryInvoiceGenerationService
Automated Billing
Scheduled auto-invoice generation on Daily, Weekly, Monthly, or Quarterly cadences. Creates draft invoices per billing-enabled NetworkEntity with overdue detection and immutable JSON snapshots.
DeliveryETACalculatorService
Projected Completion
Calculates estimated delivery dates using historical velocity, current capacity, dependency chains, and work item complexity. Feeds the Timeline and Gantt views with projected end dates.
DeliveryScoreService
Health Grading (A-F)
Composite scoring algorithm that grades work items and projects on a letter scale. Factors in SLA adherence, velocity trends, dependency risk, comment activity, and time-to-resolution.
DeliverySyncReconcilerService
External Sync & Drift Detection
Scheduled reconciliation comparing record states between connected orgs. Detects drift from missed updates, failed retries, and field-level mismatches. Queues self-healing corrections automatically.
DeliveryPortalAccessService
Self-Service Auth
One-click entity onboarding that auto-creates PortalAccess__c records with 128-bit access tokens. Supports passkey, password, and magic-link authentication for the external client portal.
DeliveryTemplateManagerController
Workflow Templates
CRUD operations for reusable work item templates. Create, edit, and apply templates that pre-fill fields, stages, and assignees for repeatable delivery patterns.
DeliveryHubTriggerHandler
Unified Trigger Framework
Single-handler pattern routing all DML events through one dispatcher. Ensures consistent ordering, prevents recursion, and centralizes cross-cutting concerns like activity logging and sync publishing.
SyncItemProcessor
Sync Engine Pipeline
Core sync pipeline with SyncItemProcessor and DeliverySyncItemIngestor. Inbound items are validated, transformed, and upserted with echo suppression and GlobalSourceId kill-switch to prevent infinite loops between connected orgs.
JiraWebhookHandler
Jira Integration
Webhook receiver processing 9 Jira event types: issue created/updated/deleted, comment created/updated/deleted, attachment created/updated/deleted. Bidirectional sync with AttachmentSyncService for file replication and conflict resolution.
AiSettingsService
AI Settings Management
Per-org OpenAI configuration via OpenAIConfiguration__mdt. API keys, model selection, temperature, and token limits configurable at the org level. Powers AI estimation, auto-descriptions, weekly digest, and narrative generation.
UserActivityLogService
Audit Logging
User_Activity_Log__c captures every significant action for compliance. Field-level change tracking with old/new values, user identity, timestamps, and component context. Configurable retention policies via Activity Log Retention Days setting.
Data Model
35 custom objects, metadata types, and platform events with WorkItem__c at the center. All namespaced under delivery__.
WorkItem__c
Central work unit
Child Objects
WorkLog__c
Time entries
WorkItemComment__c
Discussions
WorkItemDependency__c
Blocking chains
SyncItem__c
Sync audit log
ActivityLog__c
Change history
BountyClaim__c
Bounty claims
Entity Cluster
NetworkEntity__c
Client / vendor org
DeliveryDocument__c
Invoices, agreements
DeliveryTransaction__c
Payments, credits
PortalAccess__c
Portal auth tokens
WorkRequest__c
Sync bridge
Configuration
DeliveryHubSettings__c
Org-level config
DeliverySavedFilter__c
Board filter presets
NotificationPreference__c
User notifications
Custom Metadata
DeveloperCapacity__mdt
Capacity planning
WorkflowStageRequirement__mdt
Stage gates
WorkflowType__mdt
Workflow definitions
WorkflowStage__mdt
Stage definitions
SLARule__mdt
SLA thresholds
DocumentTemplate__mdt
Doc templates
Platform Events Flow
Real-time event-driven architecture. Four platform events fire on every meaningful change.
Work Item Change
Stage, priority, assignee
Platform Event
DeliveryWorkItemChange__e
Webhook
REST callout
External System
Connected org, portal
DeliveryWorkItemChange__e
Stage, priority, assignee changes
DeliveryEscalation__e
SLA breaches, stuck items
DeliverySync__e
Sync completions and failures
DeliveryDocEvent__e
Invoice status transitions
CI/CD Pipeline
Every change flows through automated quality gates before reaching production.
GitHub PR
PMD Scanner
Test Runner
Package Build
Install Link
Static Analysis
PMD scanner runs on every PR. Custom ruleset catches security issues, SOQL in loops, and unused variables before review.
Automated Testing
73 test classes maintaining 89%+ code coverage. Tests validate every service, trigger, and API endpoint with positive and negative scenarios.
Package Versioning
Managed package with semantic versioning. Each release gets a unique install URL. 477+ pull requests shipped and counting.
By the Numbers
183
Apex Classes
93 prod + 90 test
66
LWC Components
Full Lightning UI
11
Custom Metadata
Declarative config
89%+
Test Coverage
CI/CD enforced
477+
Pull Requests
Shipped to date
0
Dependencies
Pure Salesforce