CallableLogger Enhancements
Thanks to @aBerean2 for some great feedback on logging in OmniStudio (see discussion #785)!
Core Unlocked Package Changes
Added 3 enhancements to the CallableLogger
class (used for OmniStudio logging & loosely-coupled dependencies)
-
Resolved #788 - It now automatically appends OmniStudio's input data for OmniScript steps as JSON to the
Message__c
fields onLogEntryEvent__e
andLogEntry__c
.-
In the screenshot below, a simple OmniScript has been setup with 2 steps (each of which shows some inputs), with logging actions after each step:
-
It now automatically stores the JSON from each of the steps & appends it to the message. Long-term, it might make sense to create a new field to store this data, but for now, appending it to
Message__c
is a quick & easy way to capture the JSON.
-
-
The
newEntry
action now supports setting the parent log transaction ID, using the optional argumentparentLogTransactionId
. -
Transaction details are now returned in the output for all actions:
transactionId
: The current transaction ID, returned fromLogger.getTransactionId()
parentLogTransactionId
: The parent log transaction ID (ornull
if no parent has been set), returned fromLogger.getParentLogTransactionId()
requestId
: The Salesforce-generated request ID, returned fromSystem.Request.getCurrent().getRequestId()
Installation Info
Core Unlocked Package - no namespace
Full Changelog: v4.14.15...v4.14.16
- SF CLI:
sf package install --wait 20 --security-type AdminsOnly --package 04t5Y0000015ocHQAQ
- SFDX CLI:
sfdx force:package:install --wait 20 --securitytype AdminsOnly --package 04t5Y0000015ocHQAQ
- Sandbox: https://test.salesforce.com/packaging/installPackage.apexp?p0=04t5Y0000015ocHQAQ
- Production: https://login.salesforce.com/packaging/installPackage.apexp?p0=04t5Y0000015ocHQAQ