Files
e-ticket/config/packages/cache.yaml
Serreau Jovann 83583e0d3d Enable Doctrine L2 cache and add Redis cache pools
Doctrine Second Level Cache (NONSTRICT_READ_WRITE) on:
- Event, User, Category, Billet, BilletDesign
- Default region: 1h TTL, short_lived region: 5min TTL

Redis cache pools added:
- app.cache.events (30min) — for event listings
- app.cache.homepage (5min) — for homepage data
- doctrine.result_cache_pool — DQL result cache via Redis
- doctrine.system_cache_pool — metadata/query cache

All pools backed by Redis DB 2. Reduces DB queries significantly
for read-heavy pages (event listings, user profiles, categories).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-26 12:50:13 +01:00

30 lines
870 B
YAML

framework:
cache:
app: cache.adapter.redis
default_redis_provider: '%env(REDIS_CACHE_DSN)%'
pools:
siret.cache:
adapter: cache.app
default_lifetime: 86400
meilisearch.cache:
adapter: cache.app
default_lifetime: 300
stats.cache:
adapter: cache.app
default_lifetime: 600
app.cache.events:
adapter: cache.app
default_lifetime: 1800
app.cache.homepage:
adapter: cache.app
default_lifetime: 300
doctrine.result_cache_pool:
adapter: cache.app
doctrine.system_cache_pool:
adapter: cache.system
when@test:
framework:
cache:
app: cache.adapter.array