Friday, July 14, 2023

Salesforce Governor Limits

SOQL Queries: SOQL (Salesforce Object Query Language) is the language used to query Salesforce data. A single Apex transaction can execute a maximum of 100 SOQL queries. This limit is in place to prevent Apex code from making too many database calls and impacting the performance of other users. 

DML Statements: DML (Data Manipulation Language) statements are used to insert, update, or delete Salesforce data. A single Apex transaction can execute a maximum of 150 DML statements. This limit is in place to prevent Apex code from making too many database changes and impacting the performance of other users. 

CPU Time: CPU time is the amount of time that a process can use the CPU. A single Apex transaction can consume a maximum of 5 minutes of CPU time. This limit is in place to prevent Apex code from monopolizing the CPU and impacting the performance of other users. 

Memory Usage: Memory usage is the amount of memory that a process can use. A single Apex transaction can use a maximum of 100MB of memory. This limit is in place to prevent Apex code from using too much memory and impacting the performance of other users. 

Concurrent Apex Executions: A concurrent Apex execution is an Apex transaction that is currently running. A single user can have a maximum of 10 concurrent Apex executions. This limit is in place to prevent a single user from monopolizing the Apex runtime and impacting the performance of other users. 

API Callouts: API callout is a method of calling an external web service from within an Apex transaction. A single Apex transaction can make a maximum of 100 callouts to an HTTP request or an API call. This limit is in place to prevent Apex code from making too many external calls and impacting the performance of other users. 

Asynchronous Apex Executions: Asynchronous Apex executions are Apex transactions that run in the background. A single user can have a maximum of 100 asynchronous Apex executions in progress. This limit is in place to prevent a single user from monopolizing the asynchronous Apex runtime and impacting the performance of other users. 

These limits are enforced by Salesforce to ensure that Apex code does not monopolize system resources and impact the performance of other users. If an Apex transaction exceeds a governor limit, an exception will be thrown and the transaction will be terminated. 

There are a few things that you can do to avoid hitting governor limits:

Use SOQL queries sparingly and only when necessary. 
Use bulk API calls to insert, update, or delete large amounts of data. 
Optimize your Apex code to minimize the amount of CPU time and memory that it uses. 
Use asynchronous Apex executions to run long-running tasks in the background.


Monday, January 9, 2023

Salesforce Summer '23 Release Highlights

Salesforce Summer '23 Release Highlights

  • Enhanced automation and productivity with the new Flow Designer, which allows users to build flows with a more intuitive, drag-and-drop interface.
  • Improved data management and security with the new Data Mask feature, which allows users to mask sensitive data in non-production environments.
  • Enhanced mobile capabilities with the new Mobile Enhancements feature, which allows users to access new features and capabilities from their mobile devices.
  • Improved collaboration and communication with the new Salesforce Inbox integration, which allows users to connect their email accounts and access Salesforce data directly from their email inbox.
  • Enhanced analytics and reporting with the new Einstein Discovery feature, which allows users to quickly and easily build predictive models and gain insights from their data.
  • Improved integration and customization with the new Custom Metadata Types feature, which allows users to create custom metadata and use it in their applications.
  • Enhanced customer service and support with the new Omni-Channel routing enhancements, which allow users to route customer service requests to the most appropriate agents based on skills and availability.