j4mie / idiorm

A lightweight nearly-zero-configuration object-relational mapper and fluent query builder for PHP5.
http://j4mie.github.com/idiormandparis/
2.01k stars 369 forks source link

Considered MongoDB support? #105

Closed spacemonkey closed 11 years ago

spacemonkey commented 11 years ago

Happy to help if that is something you would be interested in. Something like this would be a great fit IMHO.

-- Mitch

treffynnon commented 11 years ago

Hi Mitch,

Thanks for the suggestion.

However Idiorm is built upon PHP's PDO for which there is no upstream support of MongoDB therefore it is not going to be a straight forward technology to add. It would probably require going down a similar route as Doctrine with driver abstractions so that a MongoDB wrapper could be written.

Whilst this might seem like a simple feature to add at first blush it is actually quite complex due to the simple approach Idiorm takes to effectively wrapping PDO with syntactic sugar.

Having said all this I agree that an Idiorm like interface to MongoDB would be a very good thing. Although it would need to be considered as a parallel project like Paris or implemented in a fork of Idiorm rather than being added to the core project. This is for reasons of simplicity outlined in the project philosophy.

Thank you for the suggestion and I would be interested to hear if you do decide to go down the route of a parallel project or fork for this purpose.