[0]. http://symfony.com/ [1]. http://silex.sensiolabs.org/ [2]. http://www.doctrine-project.org/
[0]. http://symfony.com/ [1]. http://silex.sensiolabs.org/ [2]. http://www.doctrine-project.org/
I've dabbled in Doctrine before, but the memory usage looked a little too high for the convenience it offered.
It's a rather different beat, but you might checkout Propel (http://propelorm.org) for a different take on a PHP ORM. It has a static build phase unlike Doctrine which turns some people off, but if you can get past that it's a rather nice ORM.
A lot about their active record implementation violates POLA with various gotchas and code generation gets tedious and unwieldy with models that contain many fields or relations.
Say you want to add a product to an existing order in the database...
$orderProduct = new OrderProduct(); $order = OrderPeer::retrieveByPK(1);
$order->addOrderProduct($orderProduct);
Now, if ANYWHERE after this point in the code, something calls $order->getOrderProducts() before you call $order->save() (like a validation routine or something) you will lose that new OrderProduct and it will not be persisted.
It's bit me more than once, especially as you start to spread code around that depends on traversing the relationships - can be a very tricky bug to spot.