Skip to content

Commit

Permalink
Spring '24 Release (API v60.0) - v4.13.0 (#631)
Browse files Browse the repository at this point in the history
* Bumped all metadata to API v60.0 (Spring '24 release)

* Switched to using the new standard class System.UUID, instead of my custom UUID class. The new system class is soooo much faster.

* Worked with @jamessimone on logger LWC to simplify & fix the approach used for loading user settings, which helps streamline everything else. This one will surely... _resolve_ the issues! I.... Promise! ☜(゚ヮ゚☜)

* Updated logger.js-meta.xml to change isExposed to true so the logger LWC is available in the managed package

* Fixed an issue in LoggerDataStore where not all string fields were truncated for platform events (introduced in v4.12.6). Also optimized how the code looks for string fields to truncate to reduce some unnecessary looping.

* Fixed LogManagementDataSelector so it always returns null in getCachedRecentLogWithApiReleaseDetails() when LoggerParameter.CALL_STATUS_API is null. When the callout is disabled, this query will never find a match (because the relevant fields haven't been populated by the callout) - and in orgs with large data volume (LDV) of logging data, the condition 'ApiReleaseNumber__c != NULL' is a very expensive database operation

* Fixed #624 by commenting out a flappy test in RelatedLogEntriesController_Tests that's been frequently failing due to ongoing platform issues with SOSL. "Fixed" ¯\\_(ツ)_/¯

---------

Co-authored-by: james simone <[email protected]>
  • Loading branch information
jongpie and jamessimone authored Feb 12, 2024
1 parent f602f90 commit ad5c177
Show file tree
Hide file tree
Showing 231 changed files with 709 additions and 777 deletions.
5 changes: 5 additions & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,12 @@
"tabWidth": 4,
"printWidth": 160,
"arrowParens": "avoid",
"plugins": ["prettier-plugin-apex", "@prettier/plugin-xml"],
"overrides": [
{
"files": "*.{cls, apex}",
"options": { "parser": "apex" }
},
{
"files": "**/lwc/**/*.html",
"options": { "parser": "lwc" }
Expand Down
18 changes: 9 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,27 +5,27 @@

The most robust logger for Salesforce. Works with Apex, Lightning Components, Flow, Process Builder & Integrations. Designed for Salesforce admins, developers & architects.

## Unlocked Package - v4.12.9
## Unlocked Package - v4.13.0

[![Install Unlocked Package in a Sandbox](./images/btn-install-unlocked-package-sandbox.png)](https://test.salesforce.com/packaging/installPackage.apexp?p0=04t5Y000001Mk7BQAS)
[![Install Unlocked Package in Production](./images/btn-install-unlocked-package-production.png)](https://login.salesforce.com/packaging/installPackage.apexp?p0=04t5Y000001Mk7BQAS)
[![Install Unlocked Package in a Sandbox](./images/btn-install-unlocked-package-sandbox.png)](https://test.salesforce.com/packaging/installPackage.apexp?p0=04t5Y000001Mk8dQAC)
[![Install Unlocked Package in Production](./images/btn-install-unlocked-package-production.png)](https://login.salesforce.com/packaging/installPackage.apexp?p0=04t5Y000001Mk8dQAC)
[![View Documentation](./images/btn-view-documentation.png)](https://jongpie.github.io/NebulaLogger/)

`sf package install --wait 20 --security-type AdminsOnly --package 04t5Y000001Mk7BQAS`
`sf package install --wait 20 --security-type AdminsOnly --package 04t5Y000001Mk8dQAC`

`sfdx force:package:install --wait 20 --securitytype AdminsOnly --package 04t5Y000001Mk7BQAS`
`sfdx force:package:install --wait 20 --securitytype AdminsOnly --package 04t5Y000001Mk8dQAC`

---

## Managed Package - v4.12.0

[![Install Managed Package in a Sandbox](./images/btn-install-managed-package-sandbox.png)](https://test.salesforce.com/packaging/installPackage.apexp?mgd=true&p0=04t5Y000001Mk21QAC)
[![Install Managed Package in Production](./images/btn-install-managed-package-production.png)](https://login.salesforce.com/packaging/installPackage.apexp?mgd=true&p0=04t5Y000001Mk21QAC)
[![Install Managed Package in a Sandbox](./images/btn-install-managed-package-sandbox.png)](https://test.salesforce.com/packaging/installPackage.apexp?mgd=true&p0=04t5Y000001Mk8YQAS)
[![Install Managed Package in Production](./images/btn-install-managed-package-production.png)](https://login.salesforce.com/packaging/installPackage.apexp?mgd=true&p0=04t5Y000001Mk8YQAS)
[![View Milestone](./images/btn-view-managed-package-milestone.png)](https://github.com/jongpie/NebulaLogger/milestone/12?closed=1)

`sf package install --wait 30 --security-type AdminsOnly --package 04t5Y000001Mk21QAC`
`sf package install --wait 30 --security-type AdminsOnly --package 04t5Y000001Mk8YQAS`

`sfdx force:package:install --wait 30 --securitytype AdminsOnly --package 04t5Y000001Mk21QAC`
`sfdx force:package:install --wait 30 --securitytype AdminsOnly --package 04t5Y000001Mk8YQAS`

---

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<status>Active</status>
</ApexClass>
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<status>Active</status>
</ApexClass>
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<status>Active</status>
</ApexClass>
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<status>Active</status>
</ApexClass>
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<status>Active</status>
</ApexClass>
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<status>Active</status>
</ApexClass>
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<status>Active</status>
</ApexClass>
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<status>Active</status>
</ApexClass>
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<status>Active</status>
</ApexClass>
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<status>Active</status>
</ApexClass>
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<status>Active</status>
</ApexClass>
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<status>Active</status>
</ApexClass>
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexPage xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<availableInTouch>false</availableInTouch>
<confirmationTokenRequired>false</confirmationTokenRequired>
<description>Página predeterminada de límite superado de Plataforma Lightning</description>
Expand Down
2 changes: 1 addition & 1 deletion config/experience-cloud/pages/ChangePassword.page-meta.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexPage xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<availableInTouch>false</availableInTouch>
<confirmationTokenRequired>false</confirmationTokenRequired>
<description>Página de cambio de contraseña predeterminada de Sitios de Salesforce</description>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexPage xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<availableInTouch>false</availableInTouch>
<confirmationTokenRequired>false</confirmationTokenRequired>
<description>Página de inicio de experiencias predeterminadas</description>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexPage xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<availableInTouch>false</availableInTouch>
<confirmationTokenRequired>false</confirmationTokenRequired>
<description>Página de inicio de sesión para experiencias predeterminadas</description>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexPage xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<availableInTouch>false</availableInTouch>
<confirmationTokenRequired>false</confirmationTokenRequired>
<description>Página de inscripción automática de experiencias predeterminadas</description>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexPage xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<availableInTouch>false</availableInTouch>
<confirmationTokenRequired>false</confirmationTokenRequired>
<description>Página de confirmación de registro de experiencias predeterminadas</description>
Expand Down
2 changes: 1 addition & 1 deletion config/experience-cloud/pages/Exception.page-meta.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexPage xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<availableInTouch>false</availableInTouch>
<confirmationTokenRequired>false</confirmationTokenRequired>
<description>Página predeterminada de Plataforma Lightning para errores post-autenticación</description>
Expand Down
2 changes: 1 addition & 1 deletion config/experience-cloud/pages/FileNotFound.page-meta.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexPage xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<availableInTouch>false</availableInTouch>
<confirmationTokenRequired>false</confirmationTokenRequired>
<description>Página predeterminada de página/datos no encontrados de Plataforma Lightning</description>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexPage xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<availableInTouch>false</availableInTouch>
<confirmationTokenRequired>false</confirmationTokenRequired>
<description>Página Contraseña olvidada predeterminada de Sitios de Salesforce</description>
Expand Down
2 changes: 1 addition & 1 deletion config/experience-cloud/pages/InMaintenance.page-meta.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexPage xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<availableInTouch>false</availableInTouch>
<confirmationTokenRequired>false</confirmationTokenRequired>
<description>Página predeterminada de Plataforma Lightning en mantenimiento</description>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexPage xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<availableInTouch>false</availableInTouch>
<confirmationTokenRequired>false</confirmationTokenRequired>
<description>Página Confirmación de registro de usuario predeterminada de Sitios de Salesforce</description>
Expand Down
45 changes: 21 additions & 24 deletions docs/lightning-components/Logger.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,17 @@
## Constants

<dl>
<dt><a href="#createLogger">createLogger</a> <code>Promise.&lt;LoggerService&gt;</code></dt>
<dd></dd>
</dl>

## Functions

<dl>
<dt><a href="#getUserSettings">getUserSettings(parameters)</a> <code>Promise.&lt;ComponentLogger.ComponentLoggerSettings&gt;</code></dt>
<dt><a href="#getUserSettings">getUserSettings()</a> <code>ComponentLogger.ComponentLoggerSettings</code></dt>
<dd><p>Returns <strong>read-only</strong> information about the current user&#39;s settings, stored in <code>LoggerSettings__c</code></p>
</dd>
<dt><a href="#setScenario">setScenario(scenario)</a> <code>Array.&lt;Promise&gt;</code></dt>
<dt><a href="#setScenario">setScenario(scenario)</a></dt>
<dd><p>Sets the scenario name for the current transaction - this is stored in <code>LogEntryEvent__e.Scenario__c</code>
and <code>Log__c.Scenario__c</code>, and can be used to filter &amp; group logs</p>
</dd>
Expand Down Expand Up @@ -32,39 +39,37 @@
<dt><a href="#getBufferSize">getBufferSize()</a> <code>Integer</code></dt>
<dd><p>Returns the number of entries that have been generated but not yet saved</p>
</dd>
<dt><a href="#flushBuffer">flushBuffer()</a> <code>Promise.&lt;void&gt;</code></dt>
<dt><a href="#flushBuffer">flushBuffer()</a></dt>
<dd><p>Discards any entries that have been generated but not yet saved</p>
</dd>
<dt><a href="#saveLog">saveLog(saveMethod)</a></dt>
<dd><p>Saves any entries in Logger&#39;s buffer, using the specified save method for only this call
All subsequent calls to saveLog() will use the transaction save method</p>
</dd>
<dt><a href="#createLogger">createLogger()</a> <code>LoggerService</code></dt>
<dd></dd>
</dl>

<a name="createLogger"></a>

## createLogger <code>Promise.&lt;LoggerService&gt;</code>

**Kind**: global constant
**Returns**: <code>Promise.&lt;LoggerService&gt;</code> - a LoggerService instance
<a name="getUserSettings"></a>

## getUserSettings(parameters) <code>Promise.&lt;ComponentLogger.ComponentLoggerSettings&gt;</code>
## getUserSettings() <code>ComponentLogger.ComponentLoggerSettings</code>

Returns **read-only** information about the current user's settings, stored in `LoggerSettings__c`

**Kind**: global function
**Returns**: <code>Promise.&lt;ComponentLogger.ComponentLoggerSettings&gt;</code> - The current user's instance of the Apex class `ComponentLogger.ComponentLoggerSettings`

| Param | Type | Description |
| ---------- | ------------------- | ------------------------------------------------------------------------------------------------------------------------ |
| parameters | <code>Object</code> | Object used to provide control over how user settings are retrieved. Currently, only the property `forceReload` is used. |

**Returns**: <code>ComponentLogger.ComponentLoggerSettings</code> - The current user's instance of the Apex class `ComponentLogger.ComponentLoggerSettings`
<a name="setScenario"></a>

## setScenario(scenario) <code>Array.&lt;Promise&gt;</code>
## setScenario(scenario)

Sets the scenario name for the current transaction - this is stored in `LogEntryEvent__e.Scenario__c`
and `Log__c.Scenario__c`, and can be used to filter & group logs

**Kind**: global function
**Returns**: <code>Array.&lt;Promise&gt;</code> - A list of promises that be resolved before all scenarios are set
**Kind**: global function

| Param | Type | Description |
| -------- | ------------------- | ------------------------------------------------------ |
Expand Down Expand Up @@ -171,12 +176,11 @@ Returns the number of entries that have been generated but not yet saved
**Returns**: <code>Integer</code> - The buffer's current size
<a name="flushBuffer"></a>

## flushBuffer() <code>Promise.&lt;void&gt;</code>
## flushBuffer()

Discards any entries that have been generated but not yet saved

**Kind**: global function
**Returns**: <code>Promise.&lt;void&gt;</code> - A promise to clear the entries
<a name="saveLog"></a>

## saveLog(saveMethod)
Expand All @@ -189,10 +193,3 @@ All subsequent calls to saveLog() will use the transaction save method
| Param | Type | Description |
| ---------- | ------------------- | ------------------------------------------------------------------------ |
| saveMethod | <code>String</code> | The enum value of Logger.SaveMethod to use for this specific save action |

<a name="createLogger"></a>

## createLogger() <code>LoggerService</code>

**Kind**: global function
**Returns**: <code>LoggerService</code> - a LoggerService instance
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<status>Active</status>
</ApexClass>
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<status>Active</status>
</ApexClass>
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<status>Active</status>
</ApexClass>
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<status>Active</status>
</ApexClass>
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<status>Active</status>
</ApexClass>
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<status>Active</status>
</ApexClass>
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<status>Active</status>
</ApexClass>
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<status>Active</status>
</ApexClass>
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<status>Active</status>
</ApexClass>
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<status>Active</status>
</ApexClass>
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>59.0</apiVersion>
<apiVersion>60.0</apiVersion>
<status>Active</status>
</ApexClass>
Loading

0 comments on commit ad5c177

Please sign in to comment.