Developed with love by KnpLabs Hire us for your project!
794

DoctrineBundle

by doctrine

Symfony Bundle for Doctrine ORM and DBAL

Doctrine Bundle

Doctrine DBAL & ORM Bundle for the Symfony Framework.

Build Status: Build Status

What is Doctrine?

The Doctrine Project is the home of a selected set of PHP libraries primarily focused on providing persistence
services and related functionality. Its prize projects are a Object Relational Mapper and the Database Abstraction
Layer it is built on top of. You can read more about the projects below or view a list of all projects.

Object relational mapper (ORM) for PHP that sits on top of a powerful database abstraction layer (DBAL).
One of its key features is the option to write database queries in a proprietary object oriented SQL dialect
called Doctrine Query Language (DQL), inspired by Hibernates HQL. This provides developers with a powerful
alternative to SQL that maintains flexibility without requiring unnecessary code duplication.

DBAL is a powerful database abstraction layer with many features for database schema introspection,
schema management and PDO abstraction.

Documentation

The documentation is rendered on the symfony.com website.
The source of the documentation is available in the Resources/docs folder.

Copyright (c) 2011 Fabien Potencier, Doctrine Project

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
documentation files (the "Software"), to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software,
and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
doctrine:
dbal:
default_connection: ~
types:

# Prototype
name:
class: ~ # Required
commented: true
connections:

# Prototype
name:

# A URL with connection information; any parameter value parsed from this string will override explicitly set parameters
url: ~
dbname: ~
host: localhost
port: ~
user: root
password: ~
application_name: ~
charset: ~
path: ~
memory: ~

# The unix socket to use for MySQL
unix_socket: ~

# True to use as persistent connection for the ibm_db2 driver
persistent: ~

# The protocol to use for the ibm_db2 driver (default to TCPIP if ommited)
protocol: ~

# True to use SERVICE_NAME as connection parameter instead of SID for Oracle
service: ~

# Overrules dbname parameter if given and used as SERVICE_NAME or SID connection parameter for Oracle depending on the service parameter.
servicename: ~

# The session mode to use for the oci8 driver
sessionMode: ~

# The name of a running database server to connect to for SQL Anywhere.
server: ~

# Determines whether or with what priority a SSL TCP/IP connection will be negotiated with the server for PostgreSQL.
sslmode: ~

# The name of a file containing SSL certificate authority (CA) certificate(s). If the file exists, the server's certificate will be verified to be signed by one of these authorities.
sslrootcert: ~

# True to use a pooled server with the oci8/pdo_oracle driver
pooled: ~

# Configuring MultipleActiveResultSets for the pdo_sqlsrv driver
MultipleActiveResultSets: ~

# Use savepoints for nested transactions
use_savepoints: ~

# Optional parameter, complete whether to add the INSTANCE_NAME parameter in the connection. It is generally used to connect to an Oracle RAC server to select the name of a particular instance.
instancename: ~

# Complete Easy Connect connection descriptor, see https://docs.oracle.com/database/121/NETAG/naming.htm.When using this option, you will still need to provide the user and password parameters, but the other parameters will no longer be used. Note that when using this parameter, the getHost and getPort methods from Doctrine\DBAL\Connection will no longer function as expected.
connectstring: ~
driver: pdo_mysql
platform_service: ~
auto_commit: ~
schema_filter: ~
logging: false
profiling: false
server_version: ~
driver_class: ~
wrapper_class: ~
shard_manager_class: ~
shard_choser: ~
shard_choser_service: ~
keep_slave: ~
options:

# Prototype
key: []
mapping_types:

# Prototype
name: []

# This option is used by the schema-tool and affects generated SQL. Possible keys include 'charset','collate', and 'engine'.
default_table_options:

# Prototype
name: []
slaves:

# Prototype
name:

# A URL with connection information; any parameter value parsed from this string will override explicitly set parameters
url: ~
dbname: ~
host: localhost
port: ~
user: root
password: ~
application_name: ~
charset: ~
path: ~
memory: ~

# The unix socket to use for MySQL
unix_socket: ~

# True to use as persistent connection for the ibm_db2 driver
persistent: ~

# The protocol to use for the ibm_db2 driver (default to TCPIP if ommited)
protocol: ~

# True to use SERVICE_NAME as connection parameter instead of SID for Oracle
service: ~

# Overrules dbname parameter if given and used as SERVICE_NAME or SID connection parameter for Oracle depending on the service parameter.
servicename: ~

# The session mode to use for the oci8 driver
sessionMode: ~

# The name of a running database server to connect to for SQL Anywhere.
server: ~

# Determines whether or with what priority a SSL TCP/IP connection will be negotiated with the server for PostgreSQL.
sslmode: ~

# The name of a file containing SSL certificate authority (CA) certificate(s). If the file exists, the server's certificate will be verified to be signed by one of these authorities.
sslrootcert: ~

# True to use a pooled server with the oci8/pdo_oracle driver
pooled: ~

# Configuring MultipleActiveResultSets for the pdo_sqlsrv driver
MultipleActiveResultSets: ~

# Use savepoints for nested transactions
use_savepoints: ~

# Optional parameter, complete whether to add the INSTANCE_NAME parameter in the connection. It is generally used to connect to an Oracle RAC server to select the name of a particular instance.
instancename: ~

# Complete Easy Connect connection descriptor, see https://docs.oracle.com/database/121/NETAG/naming.htm.When using this option, you will still need to provide the user and password parameters, but the other parameters will no longer be used. Note that when using this parameter, the getHost and getPort methods from Doctrine\DBAL\Connection will no longer function as expected.
connectstring: ~
shards:
id: ~ # Required

# A URL with connection information; any parameter value parsed from this string will override explicitly set parameters
url: ~
dbname: ~
host: localhost
port: ~
user: root
password: ~
application_name: ~
charset: ~
path: ~
memory: ~

# The unix socket to use for MySQL
unix_socket: ~

# True to use as persistent connection for the ibm_db2 driver
persistent: ~

# The protocol to use for the ibm_db2 driver (default to TCPIP if ommited)
protocol: ~

# True to use SERVICE_NAME as connection parameter instead of SID for Oracle
service: ~

# Overrules dbname parameter if given and used as SERVICE_NAME or SID connection parameter for Oracle depending on the service parameter.
servicename: ~

# The session mode to use for the oci8 driver
sessionMode: ~

# The name of a running database server to connect to for SQL Anywhere.
server: ~

# Determines whether or with what priority a SSL TCP/IP connection will be negotiated with the server for PostgreSQL.
sslmode: ~

# The name of a file containing SSL certificate authority (CA) certificate(s). If the file exists, the server's certificate will be verified to be signed by one of these authorities.
sslrootcert: ~

# True to use a pooled server with the oci8/pdo_oracle driver
pooled: ~

# Configuring MultipleActiveResultSets for the pdo_sqlsrv driver
MultipleActiveResultSets: ~

# Use savepoints for nested transactions
use_savepoints: ~

# Optional parameter, complete whether to add the INSTANCE_NAME parameter in the connection. It is generally used to connect to an Oracle RAC server to select the name of a particular instance.
instancename: ~

# Complete Easy Connect connection descriptor, see https://docs.oracle.com/database/121/NETAG/naming.htm.When using this option, you will still need to provide the user and password parameters, but the other parameters will no longer be used. Note that when using this parameter, the getHost and getPort methods from Doctrine\DBAL\Connection will no longer function as expected.
connectstring: ~
orm:
default_entity_manager: ~

# Auto generate mode possible values are: "NEVER", "ALWAYS", "FILE_NOT_EXISTS", "EVAL"
auto_generate_proxy_classes: false
proxy_dir: %kernel.cache_dir%/doctrine/orm/Proxies
proxy_namespace: Proxies
entity_managers:

# Prototype
name:
query_cache_driver:
type: array
host: ~
port: ~
database: ~
instance_class: ~
class: ~
id: ~
namespace: ~
cache_provider: ~
metadata_cache_driver:
type: array
host: ~
port: ~
database: ~
instance_class: ~
class: ~
id: ~
namespace: ~
cache_provider: ~
result_cache_driver:
type: array
host: ~
port: ~
database: ~
instance_class: ~
class: ~
id: ~
namespace: ~
cache_provider: ~
entity_listeners:
entities:

# Prototype
class:
listeners:

# Prototype
class:
events:
type: ~
method: ~
connection: ~
class_metadata_factory_name: Doctrine\ORM\Mapping\ClassMetadataFactory
default_repository_class: Doctrine\ORM\EntityRepository
auto_mapping: false
naming_strategy: doctrine.orm.naming_strategy.default
quote_strategy: doctrine.orm.quote_strategy.default
entity_listener_resolver: ~
repository_factory: doctrine.orm.container_repository_factory
second_level_cache:
region_cache_driver:
type: array
host: ~
port: ~
database: ~
instance_class: ~
class: ~
id: ~
namespace: ~
cache_provider: ~
region_lock_lifetime: 60
log_enabled: false
region_lifetime: 0
enabled: true
factory: ~
regions:

# Prototype
name:
cache_driver:
type: array
host: ~
port: ~
database: ~
instance_class: ~
class: ~
id: ~
namespace: ~
cache_provider: ~
lock_path: %kernel.cache_dir%/doctrine/orm/slc/filelock
lock_lifetime: 60
type: default
lifetime: 0
service: ~
name: ~
loggers:

# Prototype
name:
name: ~
service: ~
hydrators:

# Prototype
name: []
mappings:

# Prototype
name:
mapping: true
type: ~
dir: ~
alias: ~
prefix: ~
is_bundle: ~
dql:
string_functions:

# Prototype
name: []
numeric_functions:

# Prototype
name: []
datetime_functions:

# Prototype
name: []

# Register SQL Filters in the entity manager
filters:

# Prototype
name:
class: ~ # Required
enabled: false
parameters:

# Prototype
name: []
resolve_target_entities:

# Prototype
interface: []
  • Merge pull request #791 from weaverryan/import-mapping-for-bundle-less
    By web-flow, 5 months ago
  • Minor tweaks and fixes
    By weaverryan, 5 months ago
  • Requiring 2.7.22 or higher so we have the symfony/symfony#20442 fix
    By weaverryan, 5 months ago
  • phpcs!
    By weaverryan, 5 months ago
  • Simplifying ImportMappingDoctrineCommand to allow bundle or namespace
    By weaverryan, 5 months ago
  • Merged code with latest version
    By weaverryan, 5 months ago
  • Added new options to doctrine:mapping:import
    By weaverryan, 5 months ago
  • Merge pull request #793 from carusogabriel/doctrine-cs
    By web-flow, 5 months ago
  • Merge pull request #790 from weaverryan/pointing_to_maker
    By web-flow, 5 months ago
  • Apply Doctrine CS v4
    By carusogabriel, 5 months ago
  • Merge pull request #792 from weaverryan/fix-private-services-test
    By web-flow, 5 months ago
  • Fixing ContainerTest where we try to fetch private services
    By weaverryan, 5 months ago
  • Adding details about anemic models and link to Doctrine docs
    By weaverryan, 5 months ago
  • Deprecating doctrine:generate:entities and pointing to MakerBundle
    By weaverryan, 5 months ago
  • Merge pull request #781 from escopecz/remove-outdated-changelog
    By web-flow, 7 months ago
  • Remove Changelog.md since it is duplicated in GH versions and outdated.
    By , 7 months ago
  • Merge pull request #775 from Majkl578/revert-throwable
    By web-flow, 7 months ago
  • Revert Exception -> Throwable due to PHP 5.x support
    By , 7 months ago
  • Merge pull request #772 from Majkl578/cs
    By web-flow, 7 months ago
  • Apply Doctrine CS 2.1
    By Majkl578, 7 months ago
  • Merge pull request #771 from Majkl578/build-stages
    By web-flow, 7 months ago
  • Build Stages
    By Majkl578, 7 months ago
  • Merge pull request #770 from kimhemsoe/remove_mysql_dep_from_tests
    By web-flow, 7 months ago
  • Changed pdo_mysql dependency to pdo_sqlite
    By kimhemsoe, 7 months ago
  • Removing more headers (#751)
    By web-flow, 9 months ago
  • Merge pull request #750 from doctrine/license-cleaning
    By web-flow, 9 months ago
  • Removing the copyright header that duplicate the license file
    By mikeSimonson, 9 months ago
  • Merge pull request #740 from alcaeus/remove-invalid-aliases
    By web-flow, 9 months ago
  • Remove aliases for common interfaces
    By alcaeus, 9 months ago
  • Fix #730 compatibility with web profiler 4 (#735)
    By mikeSimonson, 9 months ago