Skip to content

Instantly share code, notes, and snippets.

@bakura10
Created July 9, 2012 21:42
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bakura10/3079195 to your computer and use it in GitHub Desktop.
Save bakura10/3079195 to your computer and use it in GitHub Desktop.
<?php
<?php
/**
* Doctrine ORM Configuration
*/
return array(
'doctrine' => array(
'driver' => array(
'application_driver' => array(
'class' => 'Doctrine\ORM\Mapping\Driver\AnnotationDriver',
'cache' => 'array',
'paths' => array('module/Application/src/Application/Entity')
),
'member_driver' => array(
'class' => 'Doctrine\ORM\Mapping\Driver\AnnotationDriver',
'cache' => 'array',
'paths' => array('module/Member/src/Member/Entity')
),
'messaging_driver' => array(
'class' => 'Doctrine\ORM\Mapping\Driver\AnnotationDriver',
'cache' => 'array',
'paths' => array('module/Messaging/src/Messaging/Entity')
),
'mission_driver' => array(
'class' => 'Doctrine\ORM\Mapping\Driver\AnnotationDriver',
'cache' => 'array',
'paths' => array('module/Mission/src/Mission/Entity')
),
'orm_default' => array(
'drivers' => array(
'Application\Entity' => 'application_driver',
'Member\Entity' => 'member_driver',
'Messaging\Entity' => 'messaging_driver',
'Mission\Entity' => 'mission_driver'
)
)
),
'connection' => array(
'orm_default' => array(
'driverClass' => 'Doctrine\DBAL\Driver\PDOMySql\Driver',
'params' => array(
'host' => '..',
'port' => '..',
'user' => '..',
'password' => '..',
'dbname' => '..',
)
)
),
'configuration' => array(
'orm_default' => array(
'types' => array(
'point' => 'Common\Doctrine\Types\PointType'
),
//'sql_logger' => new Doctrine\DBAL\Logging\EchoSQLLogger,
'naming_strategy' => 'Doctrine\ORM\Mapping\UnderscoreNamingStrategy'
)
),
'eventmanager' => array(
'orm_default' => array(
'subscribers' => array(
'Doctrine\DBAL\Event\Listeners\MysqlSessionInit'
)
)
)
)
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment