Skip to content

Monitoring home

Monitor your Salesforce org with sfdx-hardis

This feature worked yesterday in production, but today it crashes, what happened ?

Salesforce provide Audit Trail to trace configuration updates in production or sandbox orgs.

You can know who updated what, but not with details (before / after).

Sfdx-hardis monitoring provides a simple way to know the exact state of your orgs metadatas everyday, or even several times a day, and provides an exact and detailed comparison with the previous metadata configuration (using git commits comparison)

Installation and usage are admin-friendly, and notifications can be sent via Slack or Microsoft Teams.

Example of a monitoring git repository

Example notifications with Slack

Example of visualization in Grafana

See presentation at Wir Sind Ohana conference in Berlin, may 2024

Extra features are also available, like:

You don't need to work in CI/CD to use Monitoring, it is compliant with any API enabled org :)

How does it work ?

Every night (or even more frequently, according to your schedule), a CI job will be triggered.

It will extract all the metadatas of your org, then push a new commit in the monitoring repository in case there are updates since the latest metadata backup.

Example workflow with GitHub actions

Example diff visualization with GitLens

The list of updated metadatas will be sent via notification to a Slack and/or Microsoft Teams channel.

After the metadata backup, other jobs will be triggered (Apex tests, Code Quality, Legacy API checks + your own commands), and their results will be stored in job artifacts and sent via notifications.

Are you ready ? Configure the monitoring on your orgs !

All Monitoring Commands

The following checks are active out of the box.

In order to avoid to overflow channels of notifications, some commands are run everyday whereas less critical ones are run weekly (on saturday).

You can force the daily run of all commands by defining env var MONITORING_IGNORE_FREQUENCY=true.

Check Frequency
Metadata Backup Daily
Detect suspect setup actions in major org Daily
Apex tests Daily
Quality Checks with MegaLinter Daily
Detect limits issues Daily
Detect calls to deprecated API versions Daily
Detect inactive users Weekly
Detect unused licenses Weekly
Detect custom elements with no access rights defined in permission sets Weekly
Detect custom labels and custom permissions that are not in use Weekly
Detect inactive metadata Weekly
Detect missing attributes Weekly