Make Mongo accessor API pluggable
Bug #713025 reported by
Oliver Gierke
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Querydsl |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
The Mongo module currently uses Morphia as underlying Mongo access API. Would be cool if this was hidden behind a tiny abstraction so that one can use alternative Mongo Java APIs.
Changed in querydsl: | |
status: | In Progress → Fix Committed |
To post a comment you must log in.
A basic separation of Morphia and Mongodb parts has now been done. com.mysema. query.mongodb contains the general part and com.mysema. query.mongodb. morphia the Morphia specific part.
For an alternative ORM layer on top of Querydsl Mongodb you would need to
* subclass MongodbQuery like MorphiaQuery to supply transformer etc onProcessor
* subclass MongodbSerializer like MongodbSerializer for annotation based field name extraction
* create an annotation processor like MorphiaAnnotati
Study the Morphia layer to see how it's done. To use the dependency without Morphia just add an exclusion. Using code from the com.mysema. query.mongodb package is without Morphia references.