Understand Custom Steps in Practice
Understand Custom Steps in Practice
While Breezz provides many out-of-the-box declarative Step types, the true power of the framework lies in Custom Steps. By extending the forvendi.Step class in Apex, you can implement highly complex, optimized business logic that scales perfectly within Salesforce governor limits.
Explore the categorized step-by-step guides below to learn how to create, execute, test, and maintain your Custom Steps.
ℹ️ Note: Before proceeding with this chapter, we strongly recommend familiarizing yourself with the Schedulers and Triggers sections.
Core Execution Guides
- How to Create a Custom Step — Step-by-step guide to writing Apex logic and registering steps in Breezz Setup.
- Basic Trigger Configuration — Complete walkthrough on attaching steps to standard Apex triggers.
- Running Steps from Apex Code — Programmatically execute Step Groups using
forvendi.BreezzApi. - Running Steps from Salesforce Flow — Invoke Breezz Step Groups declaratively from Autolaunched Flows.
- How to Run the Scheduler — Configure scheduled execution intervals for automated background processes.
Event & Data Processing Patterns
- Child Record Creation (Record Present) — Create related child records using parent context data in
ModificationContext. - Child Record Creation (Record Not Present) — Queue child record creation when parent relationships are evaluated asynchronously.
- CDC Trigger Event Handler — Attach step pipelines directly to Change Data Capture event streams.
- Platform Event Trigger Handler — Handle pub/sub Platform Events and map payloads to database SObjects.
- Run Nested Step Group — Execute an entire Step Group inside another pipeline for modular workflows.
Asynchronous Execution Patterns
- Async Step Execution — Offload heavy business logic to background workers using
addAsyncJob(). - Delayed Async Execution — Schedule background processing after specific time delays with
addDelayedAsyncJob(). - Canceling Delayed Async Execution — Revoke queued background jobs dynamically using
cancelAsyncRequest(). - Reprocess Queued Async Job — Reset and retry failed or stuck asynchronous jobs in Salesforce.
Testing & Quality Assurance
- Testing Steps — Write Apex unit tests for synchronous and asynchronous steps using
forvendi.BreezzApi.TESTS.