Batch processing and update hooks in Drupal 8 and 9
Performing operations in an update hook that you know will take a lot of time or require a lot of processing power should be done in a batch job.
Performing operations in an update hook that you know will take a lot of time or require a lot of processing power should be done in a batch job.