Cron Jobs
The module registers two cron jobs in etc/crontab.xml.
WarmCache
Section titled “WarmCache”Cron expression: 0 */4 * * * (every 4 hours)
Class: OrangeCollar\WordPressIntegration\Cron\WarmCache
Pre-warms the post listing cache by fetching the first page of posts from WordPress and saving the result to cache. This ensures a cold cache (after a purge or TTL expiry) is repopulated before the first visitor requests the page.
The cron job fetches page 1 with the configured posts-per-page count. It does not warm every page of the listing - only the most-visited first page.
When it runs: Every 4 hours from midnight (00:00, 04:00, 08:00, 12:00, 16:00, 20:00).
SyncCategories
Section titled “SyncCategories”Cron expression: 0 3 * * * (daily at 3:00 AM)
Class: OrangeCollar\WordPressIntegration\Cron\SyncCategories
Fetches all categories from WordPress and refreshes the category cache. This keeps the category list current even if no content changes trigger a webhook.
When it runs: Once per day at 3:00 AM server time.
Checking Cron Status
Section titled “Checking Cron Status”# List all scheduled cron jobsbin/magento cron:status
# Run cron manually (runs all due jobs)bin/magento cron:run
# Run only the WordPress Integration groupbin/magento cron:run --group=orangecollar_wordpress