materio_sapi: ranking cached for the next pages (H9)
Each page of 15 results ran every query again (0.7 s for words, 1 s for a phrase, up to 4 s). Base::rankedSearch() caches the ranking 10 min in the materio_sapi bin, per user (results depend on node grants), invalidated by node_list. Pages 2+ now take 1 ms, page 1 unchanged. The OR query is not limited yet: tied to the tail cut of H6. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01ShDspHaZGwHoRZCsPBJzsM
This commit is contained in:
@@ -0,0 +1,8 @@
|
||||
services:
|
||||
# Rankings of the searches, reused by the next pages (H9).
|
||||
cache.materio_sapi:
|
||||
class: Drupal\Core\Cache\CacheBackendInterface
|
||||
tags:
|
||||
- { name: cache.bin }
|
||||
factory: ['@cache_factory', 'get']
|
||||
arguments: [materio_sapi]
|
||||
Reference in New Issue
Block a user