microwave
Introduction
Microwave helps you to warm your website pages (node/taxonomy term/custom
pages/commerce product). It is sometimes useful to generate page cache after a release delivery
on production in order to prevent heavy loading for a real user (human).
Requirements
- Drush 10.x
composer require drush/drush - Drupal console 1.9.x
composer require drupal/console
Installation
Install as you would normally install a contributed Drupal module. Visit
https://www.drupal.org/node/1897420 for further information.
Additional module
- Microwave commerce
Include commerce product page warming. Same process as nodes or vocabularies,
it allows you to select product bundle and additional parameters in order to
warm product page.
Configuration
Go to /admin/config/system/microwave and configure which entities and/or custom urls you want to warm.
Drush commands
After you filled the settings form, you can use the following commands to add
the urls to the warmer queue.
- Custom urls
drush microwave:process_custom_urlsor its aliasdrush mpcu - Nodes
drush microwave:process_nodes_urlsor its aliasdrush mpnu - Taxonomy terms
drush microwave:process_terms_urlsor its aliasdrush mptu - Commerce products
drush microwave:process_commerce_product_urlsor its aliasdrush mpcpu
Those commands can be called from a CI.
Drupal command
You can call those commands if you want to warm your pages right now or add it
to the crontab:
- Custom urls
drupal queue:run microwave_custom_cronor its aliasdrupal qr microwave_custom_cron - Nodes
drupal queue:run microwave_node_cronor its aliasdrupal qr microwave_node_cron - Taxonomy terms
drupal queue:run microwave_term_cronor its aliasdrupal qr microwave_term_cron - Commerce products
drupal queue:run microwave_commerce_product_cronor its aliasdrupal qr microwave_commerce_product_cron
Similar project and how they are different
Warmer is slightly different since microwave is a bit more granular: you can choose not to warm every nodes of a content type by setting a date field and a period.