Scheduled order operations

Use Cron jobs to schedule the following order processing tasks:

w-700 modal-image
Orders grid

Set pending payment order lifetime

The lifetime of orders with pending payments is determined by the Orders Cron Settings configuration. The default value is set to 480 minutes, which is eight hours.

  1. On the Admin sidebar, go to Stores > Settings > Configuration.

  2. In the left panel, expand the Sales section and choose Sales underneath.

  3. Expand Expansion selector the Orders Cron Settings section.

    img-md
    w-600 modal-image
    Orders Cron Settings
  4. For Pending Payment Order Lifetime (minutes), enter the number of minutes before a pending payment expires.

  5. Click Save Config.

Enable scheduled grid updates and reindexing

The Grid Settings configuration schedules updates to the following order management grids, and reindexes the data as scheduled by Cron:

By scheduling these tasks, you can avoid the locks that occur when data is saved and reduce processing time. When enabled, any updates take place only during the scheduled cron job. For best results, Cron should be configured to run once every minute.

To enable the updates and reindexing:

When Production mode (the default mode used in Adobe Commerce on cloud infrastructure) is enabled, run the following command:

bin/magento config:set dev/grid/async_indexing 1

When Default mode is enabled, complete the following steps:

  1. On the Admin sidebar, go to Stores > Settings > Configuration.

  2. In the left panel, expand the Advanced section and choose Developer.

  3. Expand Expansion selector the Grid Settings section.

  4. Set Asynchronous Indexing to Enable.

    img-md
    w-600 modal-image
    Grid Settings
  5. Click Save Config.

recommendation-more-help
dacea746-44a9-4368-b3fb-3bcff64c6be1