perf(2meet-data-optimizer-hivepress-addon): keep HivePress transients a day in the object cache

- MAX_CACHE_TTL: a week -> a day (HivePress's own default); a timeout still
  outlives its value by a minute
- dev36 (1.3M listings): 4.7M entries / 1 GB in the shared Redis at a week,
  evicting other sites' keys
- Verify: composer test (148), integration (53), phpcs clean on the file
- PR: PR-120
This commit is contained in:
2026-09-27 23:26:08 +08:00
parent 0cd2a9db5b
commit 15bbf335f4
2 changed files with 6 additions and 3 deletions
@@ -80,8 +80,8 @@ final class TMDO_Hivepress_Transient_Filter {
/** Object cache group used instead of wp_options when a persistent cache is present. */
public const CACHE_GROUP = 'tmdo_hp_transient';
/** Longest an object-cache entry lives: a week (HivePress's default is a day). */
public const MAX_CACHE_TTL = 604800;
/** Longest an object-cache entry lives: a day, HivePress's own default (2.4 PR-120). */
public const MAX_CACHE_TTL = DAY_IN_SECONDS;
/**
* Register the four metadata filters on `init`. Idempotent — safe to call