Commerce provides many settings and tools that you can use to improve response time on the pages as well as provide higher throughput.
All asynchronous operations in Commerce are performed using the Linux
cron command. See Configure and run cron to configure it correctly.
An indexer can run in either Update on Save or Update on Schedule mode. The Update on Save mode immediately indexes whenever your catalog or other data changes. This mode assumes a low intensity of update and browsing operations in your store. It can lead to significant delays and data unavailability during high loads. We recommend using Update on Schedule mode in production, because it stores information about data updates and performs indexation by portions in the background through a specific cron job. You can change the mode of each Commerce indexer separately on the System > Tools > Index Management configuration page.
Reindexing on MariaDB 10.4 takes more time compared to other MariaDB or MySQL versions. As a workaround, we suggest modifying the default MariaDB configuration and setting the following parameters:
When you launch your store in production, activate all the caches from the System > Tools > Cache Management page. We highly recommend using Varnish, as it is an efficient production page cache solution.
Enabling the “Asynchronous email notifications” setting moves processes that handle checkout and order processing email notifications to the background. To enable this feature, go to Stores > Settings > Configuration > Sales > Sales Emails > General Settings > Asynchronous Sending. See Sales Emails in the Magento Open Source User Guide for more information.
There can be times when intensive sales on a storefront occur at the same time that Commerce is performing intensive order processing. You can configure Commerce to distinguish these two traffic patterns on the database level to avoid conflicts between read and write operations in the corresponding tables. You can store and index order data asynchronously. Orders are placed in temporary storage and moved in bulk to the Order Management grid without any collisions. You can activate this option from Stores > Settings > Configuration > Advanced > Developer > Grid Settings > Asynchronous indexing. See Scheduled Grid Updates in the Magento Open Source User Guide for more information.
In times of intensive sales, Commerce can defer stock updates related to orders. This minimizes the number of operations and speeds up the order placement process. However, this option is risky and can only be used when Backorders are activated in the store, because this option can lead to negative stock quantities. This option can bring significant performance improvement on Checkout flows for stores that can easily re-fill their stock on demand. To activate deferred stock updates on your site, go to Stores > Settings > Configuration > Catalog > Inventory > Product Stock Options > Use Deferred Stock Update. See Managing Inventory in the Adobe Commerce User Guide for more information.
This option is available only if Backorder with any mode is activated.
To improve the storefront responsiveness of your Commerce instance, go to the Admin in Default or Developer mode and change the following settings:
Stores -> Configuration -> Advanced -> Developer:
|Grid Settings||Asynchronous indexing||Enable|
|CSS Settings||Minify CSS Files||Yes|
|Template Settings||Minify HTML||Yes|
We recommend performing periodic database backups for your Staging and Production instances. Due to the I/O intensive nature of backup operations, you may encounter slower backups and potential issues. Running database processes for multiple environments at the same time may potentially run slower due to contention for available resources.
For better performance, schedule your backups to run in succession, one at a time, at off-peak times. This method avoids I/O contention and reduces time to complete, especially for smaller instances, larger databases, and so on.
For example, we recommend scheduling a backup of your Production database followed up by the Staging database when your stores encounter lower visits.