Trigger Architecture Without a 40-Class Framework
Most Apex trigger logic needs one entry point, thin routing, bulk-safe services, and change-aware guards. It does not automatically need a metadata-driven framework.
18 posts in this channel.
Most Apex trigger logic needs one entry point, thin routing, bulk-safe services, and change-aware guards. It does not automatically need a metadata-driven framework.
Database methods can let valid records succeed while invalid records fail, but partial DML is only useful when every input receives an explicit, inspectable outcome.
User mode closes important CRUD, field-security, and record-access gaps, but secure Apex still needs authorised operations, untrusted-input handling, safe errors, and reviewed privilege boundaries.
Queueable Apex becomes reliable when jobs are treated as at-least-once work: use idempotency keys, durable checkpoints, bounded retries, and outcomes you can inspect.
Errors become much easier to handle when LWC, Apex, and Flow agree on a small contract: stable codes for automation, safe messages for people, and correlation details for support.
An invocable method receives a list for a reason. Treat every request as independent, query and write in collections, and return one useful outcome for every input.
Flow and Apex overlap, but they are not interchangeable. I use Flow for visible orchestration and Apex when data structures, transaction control, scale, or reuse become the real problem.
LDS, GraphQL, and Apex can all put Salesforce data into an LWC. The useful question is not which one is best, but which is the smallest honest fit for the operation.
Summer '26 makes Apex actions easier to configure in Flow Builder. The opportunity is bigger than nicer inputs: build actions admins can use safely without reading the source.
Summer '26 gives Apex readable multiline strings and String.template() interpolation. They improve payloads, emails and tests, but do not make dynamic SOQL safe.
Summer '26 adds elastic async limits for Queueable and future jobs. The real opportunity is to shed low-priority work before the extra headroom runs out.
Blob.toPdf() keeps the same Apex API, but Summer '26 moves rendering to the Visualforce PDF service, which can change fonts, wrapping and page breaks.
A focused migration guide for replacing WITH SECURITY_ENFORCED with WITH USER_MODE before moving Apex classes to API 67.0.
Summer '26 changes Apex defaults in API 67.0: database operations move to user mode, classes enforce sharing by default and elevated access becomes explicit.
GraphQL mutations in API 66.0+ let LWCs create, update and delete UI API-supported records without Apex for standard CRUD paths.
Apex can now fetch all picklist values for a record type directly with ConnectApi.RecordUi.getPicklistValuesByRecordType in API 66.0.
RunRelevantTests reduces Apex deployment time by running only tests that are relevant to the components in your deployment payload.
I have been using Apex cursors since they became generally available, and this is where they help in day-to-day Salesforce work.