Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
QueryDSL MongoDB does not work with an OSGi environment #164
When trying to deploy a bundle that uses querydsl-mongodb on an OSGi environment (with mongo-java-driver-2.7.3.jar), the OSGi platform complains the bundle querydsl-mongodb is missing an import package constraint: com.mongodb;version="2.1"
The exception comes from the fact that the MANIFEST.MF of mongo-java-driver-2.7.3 exports packages without any version declaration. As matter of fact, to fix this issue, the bundle querydsl-mongodb must declare in its MANIFEST.MF the Import-Package as follows
Proposed fix also tested successfully with the same environment.
NB: the issue exists on all the versions 2.3.3 up to 2.6 of querydsl-mongodb, since all the MANIFEST.MF declares an import of "com.mongo" with a version number.