The ByMyCTO.com blog has a recent post that makes the suggestion that the Doctrine ORM isn't suited for PHP...or to put it another way why they think it's not a good option for database integration.
I know, this title sounds like a troll. But it’s not, it’s a fact. I’m not saying Doctrine is a bad technology or shouldn’t be used. I’m just saying it’s not suited for PHP and this can lead to critical problems if misused.
He covers a few different topics including:
- Differences between Java and PHP (and the fact that Doctrine's inspiration was Hibernate)
- The "session problem" (entity serialization)
- Identity Map, useless in a stateless environment
- UnitOfWork, far too complex
- EntityManager, too magical
Despite all of these points, he does remind the reader that Doctrine isn't useless or inherently bad, it's just that he sees it as reinforcing bad behaviors and suggests using something else.