The PEG_SYS package aims primarily at generating various Org monitoring data to be used either locally (via standard reports and dashboards) or within CRM Analytics (e.g. for long history retention or in case of multi-Org connections).
Via a set of schedulable Apex tools, it enables to take periodic snapshots of
- Org limits via the standard OrgLimit Apex class
- Org Storage via the standard Storage Usage Setup page (accessible from the System Overview setup page)
- Org Licenses via the standard UserLicense and PermissionSetLicense objects (via SOQL queries)
It stores snapshot data in custom object records (CreationDate
corresponding to the snapshot timestamp) and
automatically purges old ones based on configurable durations (per object).
It also addresses issues specific to CRM Analytics (or even Marketing Cloud), such as:
- Picklist Values extraction for code-to-label picklist value mapping in DataFlows/Recipes (only the current situation of the configured picklist fields being stored, i.e. no history)
- System Permissions extraction for Profiles, Permission Set Groups and Permission Sets (only the current situation being stored, i.e. no history)
- SObject extraction from System metadata (only the current situation being stored, i.e. no history)
A CRM Analytics application is also provided to monitor the snapshots on a larger scale, with all the recipes required to initiate and update the underlying datasets.
A standard SYS Monitoring Application is provided to access the custom objects storing the snapshots generated by Apex schedulable classes.
see main Apex package description.
A standard CRM Analytics Application is provided as an add-on for the Orgs having such licenses and offers various Dashboards and Lenses leveraging snapshot data.
see CRM Analytics add-on package description.
- You need to have properly activated
CRM Analytics
on your target Org and granted your user theCRM Analytics Admin
rights before deploying the full package (not necessary if you deploy only the Apex package). - When deploying a new version of the package, you need to first unschedule the Apex class executions (and re-schedule them afterwards), see Apex package for details.
To retrieve the SFDX project, you may simply execute a git clone from the GitHub repository.
git clone git@github.com:pegros/PEG_SYS.git
Via SFDX you may then deploy it on you Org
sfdx force:source:deploy -u <yourOrgAlias> -w 10 --verbose -p force-app
ℹ️ You may also deploy only the main package (i.e. without the CRM Analytics) by targeting only the default
folder
sfdx force:source:deploy -u <yourOrgAlias> -w 10 --verbose -p force-app/main/default
For a quick and easy deployment, you may alternatively use the following deploy buttons leveraging the GitHub Salesforce Deploy Tool implemented by Andrew Fawcett.
Whole package (Apex + CRM-Analytics) |
Apex only package. |
---|---|