doctrine.yaml 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. doctrine:
  2. dbal:
  3. url: '%env(resolve:DATABASE_URL)%'
  4. # IMPORTANT: You MUST configure your server version,
  5. # either here or in the DATABASE_URL env var (see .env file)
  6. #server_version: '16'
  7. profiling_collect_backtrace: '%kernel.debug%'
  8. orm:
  9. auto_generate_proxy_classes: true
  10. enable_lazy_ghost_objects: true
  11. enable_native_lazy_objects: true
  12. validate_xml_mapping: true
  13. naming_strategy: doctrine.orm.naming_strategy.underscore_number_aware
  14. identity_generation_preferences:
  15. Doctrine\DBAL\Platforms\PostgreSQLPlatform: identity
  16. auto_mapping: true
  17. mappings:
  18. App:
  19. type: attribute
  20. is_bundle: false
  21. dir: '%kernel.project_dir%/src/Entity'
  22. prefix: 'App\Entity'
  23. alias: App
  24. controller_resolver:
  25. auto_mapping: false
  26. dql:
  27. datetime_functions:
  28. DATE_FORMAT: DoctrineExtensions\Query\Mysql\DateFormat
  29. when@test:
  30. doctrine:
  31. dbal:
  32. # "TEST_TOKEN" is typically set by ParaTest
  33. dbname_suffix: '_test%env(default::TEST_TOKEN)%'
  34. when@prod:
  35. doctrine:
  36. orm:
  37. auto_generate_proxy_classes: false
  38. query_cache_driver:
  39. type: pool
  40. pool: doctrine.system_cache_pool
  41. result_cache_driver:
  42. type: pool
  43. pool: doctrine.result_cache_pool
  44. framework:
  45. cache:
  46. pools:
  47. doctrine.result_cache_pool:
  48. adapter: cache.app
  49. doctrine.system_cache_pool:
  50. adapter: cache.system