Skip to content

Stock Sync & Logs

How the scheduled sync works

With Enable Auto Sync on, the plugin registers a WordPress cron event that runs on your configured interval. Each run:

  1. Checks that auto sync is still enabled — if you turn it off, the run exits immediately
  2. Reads your selected platform
  3. Fetches current quantities from the JDS API for every previously synced product
  4. Writes the new quantities to your store
  5. Appends the result to the Sync Log
  6. Emails the admin if there were errors and notifications are on

Only stock quantities are updated. Prices, titles, descriptions, and images are left alone — to change prices use Update All Product Pricing, and to refresh product details re-import the SKU.

Interval

Set Sync Interval (hours) in Settings. Minimum 1, maximum 168 (one week), default 24.

Changing the interval reschedules the cron event, so the new timing takes effect from the next run.

WordPress cron needs traffic

WordPress cron fires on page visits, not on a real system clock. A quiet site can run its "hourly" sync considerably late. If timing matters, disable WP_CRON and drive wp-cron.php from a real server cron — most hosts, including xCloud, can do this.

Error notifications

With Error Notifications enabled, a run that produces errors sends an email to the address in Settings → General → Administration Email Address.

Successful runs don't send mail, so no news is good news.

The Sync Log

JDS Sync → Sync Log shows the history of automatic runs — each entry recording when it ran and what happened, including counts and any errors.

The log keeps the last 50 runs

Older entries are dropped automatically. At a 24-hour interval that's roughly seven weeks of history; at hourly, about two days. If you need a longer record, lengthen the interval or export what you need before it rolls off.

Clear Log empties it entirely. That only removes history — it doesn't affect products or scheduling.

Manual stock syncs report their results on screen and are not written to this log, which covers scheduled runs.

Verifying the schedule is registered

The cron hook is jds_sync_stock_update. With WP-CLI:

bash
wp cron event list

You should see jds_sync_stock_update with a next-run time. If it's missing, toggle Enable Auto Sync off, save, then on and save again to re-register it.

For developers

HookTypeFires
jds_sync_stock_updateActionEach scheduled stock sync run

The plugin also registers a jds_sync_custom_interval schedule through cron_schedules, built from your configured interval.

Built by Code Wattz.