|
1 | 1 | framework: |
2 | 2 | cache: |
3 | 3 | # Unique name of your app: used to compute stable namespaces for cache keys. |
4 | | - #prefix_seed: your_vendor_name/app_name |
| 4 | + prefix_seed: realtoken_community/api_php |
5 | 5 |
|
6 | 6 | # The "app" cache stores to the filesystem by default. |
7 | | - # The data in this cache should persist between deploys. |
8 | | - # Other options include: |
9 | | - |
10 | 7 | # Redis |
11 | | - #app: cache.adapter.redis |
12 | | - #default_redis_provider: redis://localhost |
13 | | - |
14 | | - # APCu (not recommended with heavy random-write workloads as memory fragmentation can cause perf issues) |
15 | | - #app: cache.adapter.apcu |
| 8 | + app: cache.adapter.redis |
| 9 | + default_redis_provider: '%env(REDIS_URL)%' |
16 | 10 |
|
17 | 11 | # Namespaced pools use the above "app" backend by default |
18 | | - #pools: |
19 | | - #my.dedicated.cache: null |
| 12 | + pools: |
| 13 | + nelmio_api_doc_pool: |
| 14 | + adapter: cache.app |
| 15 | + default_lifetime: "7 days" |
| 16 | +# fallbacks: 'cache.adapter.file_system' |
| 17 | + tokens_cache: |
| 18 | + adapter: cache.app |
| 19 | + default_lifetime: 86400 # 24 hours in seconds |
| 20 | + # TODO : Mettre le cache sur les sessions |
| 21 | +# session: |
| 22 | +# handler_id: Symfony\Component\HttpFoundation\Session\Storage\Handler\RedisSessionHandler |
| 23 | +# cookie_secure: auto |
| 24 | +# cookie_samesite: lax |
| 25 | +# cookie_lifetime: 86400 |
| 26 | +# storage_factory_id: session.storage.factory.native |
| 27 | +# save_path: "%env(REDIS_URL)%" |
| 28 | + |
| 29 | +# config/packages/cache.yaml |
| 30 | +#services: |
| 31 | +# app.cache.adapter.redis: |
| 32 | +# parent: "cache.adapter.redis" |
| 33 | +# arguments: |
| 34 | +# $redis: "@Redis" |
| 35 | +# $defaultLifetime: 604800 # 7 days in seconds |
| 36 | +## - '@Redis' |
| 37 | +## - '%env(APP_CACHE_NAMESPACE)%' # optional namespace prefix for keys, e.g. "app_cache" |
| 38 | +## - '%env(int:APP_CACHE_DEFAULT_LIFETIME)%' # optional default lifetime in seconds, e.g. 3600 (1 hour) |
| 39 | +## pools: |
| 40 | +## app.tokens_cache: |
| 41 | +## adapter: cache.adapter.redis |
| 42 | +## provider: 'redis://redis' |
| 43 | +## cache.rate_limiter: |
| 44 | +## adapter: cache.adapter.redis |
| 45 | +## provider: '%env(REDIS_URL)%' |
0 commit comments