WooCommerce + Redis Object Cache + stock sync: best LSCWP settings?
-
<span style=”font-size: inherit;”>Hi LiteSpeed team,</span>
I’m looking for best-practice LiteSpeed Cache (LSCWP) settings for a WooCommerce shop with Redis object caching and frequent stock updates (via a stock sync plugin). I cannot share the site URL publicly.
LSCWP Report Number: <strong data-start=”815″ data-end=”827″>DAPRKWEO
Environment (sanitized):
WordPress + WooCommerce (large catalog, several thousand products)
LiteSpeed Cache plugin: <strong data-start=”951″ data-end=”958″>7.7
PHP <strong data-start=”966″ data-end=”973″>8.2
Redis object cache plugin (PhpRedis) is active (Redis server 6.x). LSCWP Object Cache feature is currently <strong data-start=”1084″ data-end=”1091″>OFF (to avoid double object-cache drop-ins).
Additional plugins:
A stock sync plugin updating product stock frequently
WooCommerce Germanized (unit price refresh via wc-ajax)
A plugin that requests a nonce via a GET endpoint like <code data-start=”1336″ data-end=”1360″>/?commercekit-ajax=…
Current LSCWP settings (key ones):
Cache: ON (guest cache), logged-in cache: OFF
Public TTL: <strong data-start=”1461″ data-end=”1472″>604800s (7 days)
Browser cache: ON (static assets get long max-age
Crawler: ON (warms cache using sitemap)
Optimization: HTML minify ON, JS minify ON (no combine), CSS minify ON (no combine)
CSS Async Load: ON
UCSS: ON
CCSS per URL: ON
What I’m seeing in debug logs (sanitized excerpts):
On many frontend pages:
“<strong data-start=”1804″ data-end=”1838″>[CSS] CCSS Queue is full – 500”
“<strong data-start=”1844″ data-end=”1893″>CCSS set to OFF due to CCSS not generated yet”
“Fallback to drop dummy CSS”
This happens frequently, probably because the site is large and crawler/traffic triggers lots of UCSS/CCSS generation.A GET request that returns JSON (nonce) appears to be cached:
Response <code data-start=”2129″ data-end=”2161″>Content-Type: application/json
<code data-start=”2167″ data-end=”2211″>Cache-Control: no-cache, no-store, private is present
But also <code data-start=”2237″ data-end=”2287″>X-LiteSpeed-Cache-Control: public,max-age=604800 and the debug footer comment indicates “Page cached”.
This endpoint is used to fetch a nonce, so caching it for days could break things.
Questions:
For a large WooCommerce store, do you recommend turning OFF <strong data-start=”2503″ data-end=”2538″>CSS Async / UCSS / CCSS per URL, or limiting it to selected pages only? If limiting is recommended, what’s the best approach (exclude product pages, disable crawler, adjust CCSS concurrency, etc.) to avoid “CCSS Queue is full”?
What is the recommended way to ensure endpoints like <code data-start=”2791″ data-end=”2815″>/?commercekit-ajax=… (nonce JSON) are never cached? Should we add a cache-exclude rule by query string (e.g. exclude <code data-start=”2912″ data-end=”2930″>commercekit-ajax) or URI pattern? Any preferred method with LSCWP?
With Redis Object Cache plugin already active (object-cache.php drop-in), should we keep LSCWP Object Cache OFF (recommended), or is there a preferred single approach?
Stock sync: since stock changes frequently, what’s the best practice to avoid stale stock/price info with page cache? Do you recommend tag-based purging on product update hooks, disabling cache for specific elements, or any special WooCommerce settings?
Thanks a lot for guidance. I can paste additional sanitized config values/log lines if needed (without URL/IPs).
You must be logged in to reply to this topic.