hardening 2.3: 2meet-data-optimizer-hivepress-addon 0.4.0 (listing indexes, transient TTLs, site attributes) #4

Merged
wpdev merged 8 commits from hardening/2.3 into main 2026-09-27 18:37:52 +08:00
Owner

Release 2.3 (0.4.0): listing indexes, transient TTLs, site attributes.

Commits:

  • docs(2meet-data-optimizer-hivepress-addon): add PR-115 to the 0.4.0 release notes
  • fix(2meet-data-optimizer-hivepress-addon): let transient timeouts outlive their values; register site attributes once themes load
  • docs(2meet-data-optimizer-hivepress-addon): add PR-109 to the 0.4.0 release notes
  • feat(2meet-data-optimizer-hivepress-addon): flatten a site's own listing attributes on opt-in
  • docs(2meet-data-optimizer-hivepress-addon): 0.4.0 release notes
  • fix(2meet-data-optimizer-hivepress-addon): declare the listing indexes only on a core that adds them outside web requests
  • perf(2meet-data-optimizer-hivepress-addon): expire object-cache transients
  • perf(2meet-data-optimizer-hivepress-addon): index the numeric listing columns HivePress filters and sorts on

Acceptance: notes/tmdo-acceptance-2.3-2026-09-27.md (dev36, 902k listings).

🤖 Generated with Claude Code

Release 2.3 (0.4.0): listing indexes, transient TTLs, site attributes. Commits: - docs(2meet-data-optimizer-hivepress-addon): add PR-115 to the 0.4.0 release notes - fix(2meet-data-optimizer-hivepress-addon): let transient timeouts outlive their values; register site attributes once themes load - docs(2meet-data-optimizer-hivepress-addon): add PR-109 to the 0.4.0 release notes - feat(2meet-data-optimizer-hivepress-addon): flatten a site's own listing attributes on opt-in - docs(2meet-data-optimizer-hivepress-addon): 0.4.0 release notes - fix(2meet-data-optimizer-hivepress-addon): declare the listing indexes only on a core that adds them outside web requests - perf(2meet-data-optimizer-hivepress-addon): expire object-cache transients - perf(2meet-data-optimizer-hivepress-addon): index the numeric listing columns HivePress filters and sorts on Acceptance: notes/tmdo-acceptance-2.3-2026-09-27.md (dev36, 902k listings). 🤖 Generated with [Claude Code](https://claude.com/claude-code)
wpdev added 8 commits 2026-09-27 18:03:36 +08:00
- hp_listing_core declares indexes on hp_hourly_rate and hp_rating_count; core
  adds them in place (WP-CLI / WP-Cron), the pinned schema hash is unchanged
- Verify: unit 145, integration 52, phpcs; dev36 902k listings (SHOW INDEX, EXPLAIN)
- PR: PR-090
- with an external object cache, a HivePress timeout entry expires when it
  records; the value (written before its timeout) after at most a week — a
  miss only makes HivePress rebuild it. Entries of deleted posts no longer
  accumulate without end
- Verify: HivepressTransientFilterTest TTL test, integration 53, unit 145;
  dev36 Redis TTL on tmdo_hp_transient keys
- PR: PR-099
- the hp_listing_core indexes are declared only when TMDO_Schema_Manager has
  ddl_allowed() (core 1.3.0+); core 1.2.0 would run the ALTER on 900k rows
  inside the first request after deploy, a visitor's included, if this AddOn
  were deployed first
- Verify: unit 145, integration 53, phpcs
- PR: PR-090b (found while writing the 0.4.0 notes)
- version 0.4.0; CHANGELOG for PR-090, 090b and 099 with dev36 numbers
- Upgrading: deploy with core 1.3.0; give 0.3.0 Redis entries a TTL with
  redis-cli --scan | EXPIRE ... NX | --pipe (tested on dev36: 3.0 M keys,
  45 s, latency max 2 ms), never flush-group
- Verify: composer test (145)
- PR: PR-102
- the tmdo_hp_listing_attribute_fields filter (hp_ key => type) registers a
  site's HivePress listing attributes, such as a "Warranty" number attribute
  (hp_warranty, 901k rows on dev36), in their own hp_listing_attrs group: a
  new table with each column indexed at creation; hp_listing_core and its
  pinned hash are unchanged
- keys another group manages, keys without the hp_ prefix and unknown types
  are ignored
- Verify: HivePressEntityGroupsTest (opt-in, filtering, pinned hashes), unit
  147, integration 53, phpcs; dev36 hp_warranty backfill and queries
- PR: PR-109
- Added: site listing attributes through tmdo_hp_listing_attribute_fields
- PR: PR-102 (follow-up)
- review F5: a timeout entry expired before its value (a day vs a week), and
  HivePress reads a missing timeout as "never expires", serving the stale
  value for up to six more days. The timeout now expires a minute after the
  later of MAX_CACHE_TTL and its own time, so HivePress sees it expire first
- review F7: site attributes accept only types with a plain index (json and
  binary would fail the CREATE TABLE)
- review F8: the hp_listing_attrs group is registered on the run after
  after_setup_theme (init:1), so a filter added in a theme counts and the
  group has one definition per request; only keys of other groups are skipped
- Verify: TTL test, attribute group tests, unit 148, integration 53, phpcs
- PR: PR-115 (2.3 acceptance correctness review)
docs(2meet-data-optimizer-hivepress-addon): add PR-115 to the 0.4.0 release notes
Tests / PHP Lint (pull_request) Successful in 7s
Tests / Unit Tests (pull_request) Successful in 1m21s
Tests / Integration Tests (pull_request) Successful in 1m12s
df62edd0f5
- timeout TTL order, attribute types and registration timing; Redis upgrade
  procedure gains the timeout pass
- PR: PR-102 (follow-up)
wpdev closed this pull request 2026-09-27 18:19:23 +08:00
wpdev reopened this pull request 2026-09-27 18:19:24 +08:00
wpdev closed this pull request 2026-09-27 18:35:08 +08:00
wpdev reopened this pull request 2026-09-27 18:35:09 +08:00
wpdev merged commit d802bf0145 into main 2026-09-27 18:37:52 +08:00
Sign in to join this conversation.
No Reviewers
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: wpdev/2meet-data-optimizer-hivepress-addon#4