Understand Logging
While log messages originate from all parts of Work.com, most of them come from these operations or background jobs:
- Sending a wellness check survey to one or more employees in one or more locations.
- Processing survey responses.
- Generating wellness counts based on the current wellness status of people associated with a particular location.
Work.com captures errors and exceptions asynchronously. It uses a custom platform event (wkcc__CmdCtrLogEvent__e) and an Apex trigger (LogEventTrigger) to capture the error even if the operation that caused it is rolled back. The error from a rolled back operation is useful because you can use it to troubleshoot potential problems and problems that actually happened.
Logging is enabled by default for Work.com. To disable logging, or configure other properties like how long to keep log messages, update the Command Center Log Settings custom metadata type in Setup. View log messages by creating a list view on the Command Center Logs object, which is visible by default in the App Launcher. As with other Salesforce objects, you can also create reports and Flows on Command Center Logs.