docs(2meet-data-optimizer): add PR-057b and PR-062c to the 1.1.0 notes
Anti-EAV Lint + Quality Gate / anti-eav-lint (pull_request) Successful in 18s
Tests / PHP Lint (pull_request) Successful in 59s
Tests / PHPCS (pull_request) Successful in 30s
Tests / PHPStan (pull_request) Successful in 1m12s
Tests / Unit Tests (pull_request) Successful in 47s
Tests / Integration Tests (pull_request) Successful in 57s
Anti-EAV Lint + Quality Gate / anti-eav-lint (pull_request) Successful in 18s
Tests / PHP Lint (pull_request) Successful in 59s
Tests / PHPCS (pull_request) Successful in 30s
Tests / PHPStan (pull_request) Successful in 1m12s
Tests / Unit Tests (pull_request) Successful in 47s
Tests / Integration Tests (pull_request) Successful in 57s
- CHANGELOG / readme 1.1.0: flat-first routing for flat-sorted searches (tmdo_router_flat_first) and the all-NULL flat row left after deleting an entity - ADR-004: NULL sync never inserts a row; flat-first rule; front-end p50 from the R-2.1 acceptance run - BENCHMARK-SCALE: front-end table from the acceptance run (flat tables backfilled) and the join-order finding behind PR-062c - Verify: composer phpcs (0) - PR: PR-064b
This commit is contained in:
+10
-7
@@ -71,16 +71,19 @@ SQL 的形狀與實際程式一致:原生是 WP_Query 的 meta_query(每個
|
||||
|
||||
| URL | 原生 ms | 1.0.x ms | 2.1 routed ms | ids 與原生相同 |
|
||||
|---|---:|---:|---:|---|
|
||||
| listing 價格區間 | 606 | 496 | **311** | 是(found 差 1 為扁平漂移) |
|
||||
| listing 價格區間 + `_sort=price__asc` | 949 | 1,062 | **428** | 是 |
|
||||
| listing 時薪區間 + `_sort=hourly_rate__desc` | 843 | — | 873 | 是 |
|
||||
| listing `_sort=rating__desc` | 1,717 | 1,720 | **870** | 是 |
|
||||
| listing 關鍵字 + 價格區間 | 748 | — | 743 | 是 |
|
||||
| vendor 時薪區間 | 102 | — | 86 | 是(found 差 21 為扁平漂移) |
|
||||
| WC 商店價格篩選 / 價格排序 | 90 / 107 | 88–94 | 102 / 118 | 是(WC 用 lookup 表,不經 router) |
|
||||
| listing 價格區間 | 614 | 496 | **323** | 是 |
|
||||
| listing 價格區間 + `_sort=price__asc` | 975 | 1,062 | **435** | 是 |
|
||||
| listing 時薪區間 + `_sort=hourly_rate__desc` | 850 | — | **367** | 是 |
|
||||
| listing `_sort=rating__desc` | 1,697 | 1,720 | **866** | 是 |
|
||||
| listing 關鍵字 + 價格區間 | 754 | — | 764 | 是 |
|
||||
| vendor 時薪區間 | 102 | — | 97 | 是 |
|
||||
| WC 商店價格篩選 / 價格排序 | 94 / 111 | 88–94 | 109 / 88 | 是(WC 用 lookup 表,不經 router) |
|
||||
|
||||
(R-2.1 驗收,扁平表已從原生回填、含 PR-062c;兩輪量測見 `notes/tmdo-acceptance-2.1-2026-09-26.md`。)
|
||||
|
||||
- HivePress 搜尋仍帶 tax_query(排除一個 term),WordPress 因此加上 `GROUP BY posts.ID`,排序需要 temporary + filesort;這是目前 311–428 ms 的主要成本,尚未達到 R-2.1 的 300 ms 目標。
|
||||
- PR-062b 之前,routed 搜尋因 `posts_request` 改寫而失去 WordPress 的 split query,改撈整列 `posts.*`:同一條 SQL 撈 `*` 要 590 ms,只撈 ID 為 312 ms。
|
||||
- PR-062c 之前,依扁平欄位排序的 routed 查詢由 `wp_posts`(type / status 索引,約 56k 列)驅動、逐筆查扁平表再以 temporary table 排序;拿掉 GROUP BY 或只換 tie-break 都無效(約 300 ms),改由扁平表驅動並把 tie-break 改讀 `post_id` 後只剩單表 filesort:`meta_value_num` 263→147 ms、具名排序 250→142 ms、HP 時薪篩選 + 排序 300→36 ms(只計 SQL)。依日期排序的搜尋由扁平表驅動反而變慢(74→137 ms),所以 flat-first 只用在扁平欄位排序。
|
||||
- 量測 gotcha:symlink 切換(`plugins/` → `plugins-dev`)後,PHP-FPM 的 opcache(`revalidate_path=0`)仍執行舊目標的程式,WP-CLI 不受影響;前台數字要先確認實際載入的檔案。
|
||||
|
||||
**WP_Query**(`tests/live/tools/qbench.php`,`fields=ids`,20 筆一頁):價格區間 296→76 ms、價格 + verified 360→53 ms、rating ≥ 4.5 248→33 ms、rate + `_thumbnail_id` EXISTS 24→9 ms;OR、多 post type、無 type 數值比較等維持原生,結果與原生相同。
|
||||
|
||||
Reference in New Issue
Block a user