Top 5 Features for Salesforce Platform Developer in Spring’21 Release #BeReleaseReady

Swayam Chouksey
4 min readFeb 2, 2021


#Salesforce #Release #Spring21 #LightningDevelopers

1. Create a Lightning Web Component Action (Pilot) #lwc

Create a Lightning web component (LWC) and use it as a quick action. Lightning web component actions work side by side on your pages along with Lightning component and Visualforce actions. LWC actions offer advantages such as the ability to easily customize headers and footers, and to create actions that have no UI representation.

Where: This change applies to Lightning Experience desktop in Group, Essentials, Professional, Enterprise, Performance, Unlimited, and Developer editions.

When: This pilot feature is available in the Spring ’21 release.

Who: Available to orgs that enable the pilot feature.

How: Create a Lightning web component, then create an object-specific quick action that references the Lightning web component.

Then, add the action to the object’s record page using the page layout or the Lightning App Builder.

2. Flag Invocable Apex Methods That Make Callouts #apex

With this information, a flow calling the action knows how to manage the transaction at run time.

Where: This change applies to Lightning Experience and Salesforce Classic.

How: To flag callouts in Apex methods annotated with @InvocableMethod, add the callout attribute to the annotation and set it to true.

@InvocableMethod(callout=true, label=”My Action Label”)

If your action makes a callout, set the callout attribute to true. If the action is executed by a flow, at run time the flow determines how to successfully execute the action, in a new transaction or in the currently running transaction.

If the callout attribute is set to false, the action is flagged to safely perform in the transaction regardless of whether the transaction has uncommitted work.

3. Attach Actions to Asynchronous Apex Jobs Using Transaction Finalizers (Beta) #apex

With Spring ’21, the Transaction Finalizers feature is in beta. A new limit establishes that a Queueable job that failed due to an unhandled exception can only be successively re-enqueued five times by a Transaction Finalizer. This limit applies to a series of consecutive Queueable job failures. The counter is reset when the Queueable job completes without an unhandled exception. Finalizers can be implemented as an inner class. Also, you can implement both Queueable and Finalizer interfaces with the same class.

Where: This change applies to Lightning Experience and Salesforce Classic. To use this beta feature, it isn’t necessary to enable the ‘Transaction Finalizers’ feature in scratch orgs. The Transaction Finalizers feature isn’t restricted to scratch orgs, can be used in production orgs and sandboxes, and can be included in managed packages.

How: The System.FinalizerContext interface contains four methods.

  • getAsyncApexJobId method: Returns the ID of the Queueable job for which this finalizer is defined.
  • getRequestId method: Returns the request ID shared by both the finalizer execution and the Queueable job to which the finalizer is attached. This shared ID helps in filtering logs of a Queueable job and its attached finalizer.
  • getResult method: Returns the System.ParentJobResult enum, which represents the result of the parent asynchronous Apex Queueable job to which the finalizer is attached. Valid values for the enum are SUCCESS, and UNHANDLED_EXCEPTION.
  • getException method: Returns the exception with which the Queueable job failed when getResult is UNHANDLED_EXCEPTION, null otherwise.

To attach actions to your Queueable jobs, you must implement the FinalizerContext interface. Only one finalizer instance can be attached to any Queueable job. You can enqueue a single asynchronous Apex job (Queueable, future, or batch) in the finalizer’s implementation of the execute method. Callouts are allowed in finalizer implementations.

For more information on implementing Transaction Finalizers, including examples, see Transaction Finalizers (Beta) in Apex Developer Guide.

4. Aura Components in the ui Namespace Are Being Deprecated #aura

Salesforce plans to end support for the deprecated components on May 1, 2021.

Where: This change applies to orgs with Lightning components in Lightning Experience, Salesforce Classic, and all versions of the Salesforce mobile app.

When: Salesforce plans to end support for Aura components in the ui namespace on May 1, 2021. You can continue to use these components beyond May 1, 2021, but we won’t accept support cases for them after that date. We first announced this deprecation plan in Winter ’20.

Why: Retiring our legacy components enables us to focus on components that match the latest web standards in performance, accessibility, user experience, and internationalization.

How: Replace the deprecated components with their counterparts in the lightning namespace. These components are faster, more efficient, and they implement Lightning Design System styling out-of-the-box.

5. Convert Leads to a Person Account and a Business Account at the Same Time with New LeadConvert Methods #apex

If your customers include individuals and groups, your sales teams can associate converted leads with a person account and a business account simultaneously. For example, a bank can create person accounts for each member of a family and group the family into a business account.

Where: This change applies to Lightning Experience in Enterprise, Performance, and Unlimited editions.

How: For Salesforce orgs that use APEX Lead Convert, Person Accounts, and Contacts to Multiple Accounts, new methods are available on the LeadConvert class. The getRelatedPersonAccountId(), setRelatedPersonAccountId(), getRelatedPersonAccountRecord(), and setRelatedPersonAccountRecord() methods allow converting leads into a business account and a person account instead of a contact.

The new getRelatedPersonAccountId() method in the LeadConvertResult class returns the ID of the new or existing related person account.

There are many other features as well, Official release notes are available HTML format as well as PDF file.

Say Hello To Me On Twitter | Facebook | Linkedin | Medium Blog | Blogger

#HappyLearning #LightningDeveloper #Spring21 #BeReleaseReady #Salesforceguy



Swayam Chouksey

Accomplished Salesforce Technical Architect | Technology Advisor @ mindZcloud Enterprise | Co-Founder @ SFDCMINDZ 🇮🇳 🇺🇸