Salesforce release cycle comes again with winter 19. With every new release Salesforce continue to add new feature to its platform and also keep updating existing feature as well. Now in every release Salesforce keep its main focus on Lightning and this time also it do so. But that does not mean we don’t have anything else, apart from this there are many more feature related to Apex, SFDX, Einstein bot, APIs.
Today I will cover few points which I found useful for Developer/Admins, But there are many more and if you want to read about them in details. You can do that here
- Now we can change the view in LEX with display density settings. Salesforce provide us two mode compact or comfy. Users can also change there default view from user profile without changing page layout. Currently Comfy is the deault behaviour.
- Use the new search bar to search the field data in our list views and find the records we need in record time. We can also use the keyboard shortcut g+f to select the search bar. But Certain fields aren’t searchable. Filter or sort on those fields instead. The search bar works across all applicable fields for all the records in the list, even if specific columns aren’t visible.
- Salesforce will now delete Field History Data after 18 months. We need to purchase the Field Audit Trail add-on to get this data till 10 years.
- Batch Apex classes can now opt in to fire platform events when encountering an error or exception. Event records provide more granular tracking of errors than the Apex Jobs UI because they include the record IDs being processed, exception type, exception message, and stack trace. We can also incorporate custom handling and retry logic for failures.
- We can now specify the inherited sharing keyword on an Apex class, which allows the class to run in the sharing mode of the class that called it. Using inherited sharing enables us to pass security review and ensure that our privileged Apex code is not used in unexpected or insecure ways. An Apex class with inherited sharing runs as with sharing when used as a Visualforce page controller, Apex REST service, or an entry point to an Apex transaction.
- We can now use the new System.Url.getOrgDomainUrl() method to interact with Salesforce REST and SOAP APIs in Apex code.We use getOrgDomainUrl()in orgs with or without My Domain to retrieve canonical URLs. Using this we get endpoints for User Interface API calls, for creating and customizing picklist value sets and custom fields. We can also use the updated System.UserInfo.getSessionId() method to retrieve session IDs, even when our code runs asynchronously.
Http h = new Http();
HttpRequest req = new HttpRequest();
req.setHeader(‘Authorization’, ‘Bearer ‘ + UserInfo.getSessionId());
HttpResponse res = h.send(req);
- Now we can use Visual studio code to Connect to any org to retrieve and deploy source from Visual Studio Code. Previously, we could use Salesforce Extensions for VS Code only with scratch orgs.
To retrieve source from an org without source tracking (from an org that’s not a scratch org), right-click a manifest, a source file, or a directory in the Visual Studio Code explorer. Select SFDX: Retrieve Source from Org. Or, right-click a file that’s open in the editor, and select SFDX: Retrieve This Source File from Org.
To deploy source to an org without source tracking (to an org that’s not a scratch org), right-click a manifest, a source file, or a directory in the Visual Studio Code explorer. Select SFDX: Deploy Source to Org. Or, right-click a file that’s open in the editor, and select SFDX: Deploy This Source File to Org.
- Apex Replay Debugger simulates a live debugging session using a debug log, which is a recording of all interactions in a transaction. We no longer need to parse through thousands of log lines manually. Instead, Apex Replay Debugger presents the logged information similarly to an interactive debugger, so we can debug our Apex code. With this release, we added checkpoints, which provide more information about our variables than debug logs do.
- We can now run the test classes from VS code. When Apex tests fail, we can jump from the test results straight to the line that contains the failed assert statement. When Apex tests succeed and we want to remind ourself what we were testing, we can jump to the method definitions for those tests. We can also see which test methods are in our test classes from the testing sidebar.
- The protected URL parameters used in Visualforce pages—retURL, startURL, cancelURL, and saveURL—are no longer case-sensitive. If we change the parameter value from retURL to returl, the system now recognizes it as a protected parameter.
- We can use the Metadata REST API with all deployments, either via the new deployRequest REST resource or via the Salesforce CLI.
To enable the Metadata REST API for Deploy beta feature:
sfdx force:config:set restDeploy=true
- We can now create scratch org with these new feature as well. ChatBot, Entitlements, Interaction, IOT, Knowledge, LiveAgent, LiveMessage, ProcessBuilder, SiteForceContributor, Workflow.
- Now we can see the references to a custom field, such as in a report or formula, with the click of a button. We can also communicate changes to others who use the field in a formula or other context.
So these are some of the points which I found useful but there are many more. You can also signup for pre-release org here.
Let me know in comments which feature you like most in this release. Happy programming 🙂