matteodem / meteor-easy-search

Easy-to-use search for Meteor with Blaze Components
MIT License
436 stars 68 forks source link

Grounddb V2 #527

Closed ilan-schemoul closed 7 years ago

ilan-schemoul commented 8 years ago

Ground db is a very popular package to access offline to database. I think grounddb is close as minimongo (find, findOne etc.) but I can't use it as if I use minimongo engine EasySearch complains about the fact that he expects a particular constructor. So I would need an engine with grounddb, obviously I should have create one instead of asking you that but I'm not really sure how to do it even after reading the source code of your engine.

matteodem commented 8 years ago

You could try creating a new engine, see source code for MongoDB engine as an example https://github.com/matteodem/meteor-easy-search/blob/master/packages/easysearch:core/lib/engines/mongo-db.js

ilan-schemoul commented 8 years ago

Yes I will give another try. It's not impossible, if I succeed you want me to : post the code here, create a repo, create a PR or create a package ?

matteodem commented 8 years ago

create a fork and a PR subsequently

ilan-schemoul commented 8 years ago

the problem is that since V2 grounddb is not based anymore on Meteor.collection (I think), not really based on Meteor by the way as the author doesn't want to use any Meteor features (but this is another story). Whatever, config.collection, Meteor.Collection); of https://github.com/matteodem/meteor-easy-search/blob/master/packages/easysearch:core/lib/core/index.js#L17 is the trouble-maker Can I change the expected constructor or at least disable the checking with engines functionality ?

ilan-schemoul commented 8 years ago

So finally I added an option to change the checked constructor of the collection. I made a pull request. Thanks for support.

matteodem commented 8 years ago

Awesome, gonna have a look at it tomorrow

matteodem commented 7 years ago

Introduced ignoreCollectionCheck config param in v2.1.8 https://github.com/matteodem/meteor-easy-search/blob/master/packages/easysearch:core/lib/core/index.js#L21.

guillim commented 6 years ago

I am having the exact same issue with GroundDB + EasySearch. For those who can't upgrade to newer versions of GroundDB: use Minimongo Engine. it works