Moving old system to ORM, what do you suggest? [closed]
What do I have:
- MySQL
- PHP 5.2
- stupid handmade ORM
- Code is in classes
- old-type mysql connection (without PDO, without mysqli)
- Master DB and multiple slave DBs
- slave DBs have a subset of tables from main DB
- User authorises through master DB and, depends on settings, can keep using main DB or can be switched to slave DB (but even on slave DB some queries are to the main DB)
- Load average is high enough
- tables are big
- we frequently change our table structure
When project was small, it was simple to support system, but now project grows very fast and it's not easy task to update the code.
So, wha开发者_StackOverflowt would you suggest?
Which ORM would best fit my needs knowing that project is big and it's nearly impossible to move all parts to the new base at once? (I was thinking about Doctrine, Propel, or something from that side)
I strongly suggest Doctrine ORM. But it might require you to move on to php 5.3 to leverage all the features. But it is a great ORM and i have the same situation and now i'm updating my code part by part. Right now some of my code is powered by Doctrine and some direct mysql and it works fine.
精彩评论