Files
Coltura/config/packages/doctrine.yaml
tristan 6cf5ef4cfc
All checks were successful
Auto Tag Develop / tag (push) Successful in 6s
Module sites (#8)
| Numéro du ticket | Titre du ticket |
|------------------|-----------------|
|                  |                 |

## Description de la PR

## Modification du .env

## Check list

- [x] Pas de régression
- [x] TU/TI/TF rédigée
- [x] TU/TI/TF OK
- [ ] CHANGELOG modifié

Co-authored-by: Matthieu <mtholot19@gmail.com>
Reviewed-on: #8
Co-authored-by: tristan <tristan@yuno.malio.fr>
Co-committed-by: tristan <tristan@yuno.malio.fr>
2026-04-20 15:31:58 +00:00

67 lines
2.5 KiB
YAML

doctrine:
dbal:
url: '%env(resolve:DATABASE_URL)%'
profiling_collect_backtrace: '%kernel.debug%'
orm:
validate_xml_mapping: true
naming_strategy: doctrine.orm.naming_strategy.underscore_number_aware
identity_generation_preferences:
Doctrine\DBAL\Platforms\PostgreSQLPlatform: identity
auto_mapping: true
mappings:
Core:
type: attribute
is_bundle: false
dir: '%kernel.project_dir%/src/Module/Core/Domain/Entity'
prefix: 'App\Module\Core\Domain\Entity'
alias: Core
# Mapping inconditionnelle du module Sites : la structure DB
# existe meme si SitesModule::class est retire de config/modules.php.
# L'activation fonctionnelle (ex: exposition des permissions, futurs
# endpoints API) passe exclusivement par config/modules.php.
Sites:
type: attribute
is_bundle: false
dir: '%kernel.project_dir%/src/Module/Sites/Domain/Entity'
prefix: 'App\Module\Sites\Domain\Entity'
alias: Sites
controller_resolver:
auto_mapping: false
when@test:
doctrine:
dbal:
dbname_suffix: '_test%env(default::TEST_TOKEN)%'
orm:
mappings:
# Entite fictive SiteAware utilisee uniquement en tests du
# module Sites (ticket 4). Le mapping n'est charge qu'en
# environnement test, donc aucun impact sur les schemas
# dev/prod. La table est creee a la volee par les tests
# d'integration (via `SchemaTool::createSchema`) dans le
# setUp de SiteScopedQueryExtensionTest.
TestFixtures:
type: attribute
is_bundle: false
dir: '%kernel.project_dir%/tests/Fixtures/SiteAware'
prefix: 'App\Tests\Fixtures\SiteAware'
alias: TestFixtures
when@prod:
doctrine:
orm:
query_cache_driver:
type: pool
pool: doctrine.system_cache_pool
result_cache_driver:
type: pool
pool: doctrine.result_cache_pool
framework:
cache:
pools:
doctrine.result_cache_pool:
adapter: cache.app
doctrine.system_cache_pool:
adapter: cache.system