Closed alauper closed 9 years ago
Honestly, I'm not sure what to do about this… It looks like moped and the mongo ruby driver can't co-exist :-/
The mongo driver depends on bson=1.11.1
, and moped depends on bson~>2.2
.
I mean, I could rewrite Genghis to use moped instead of the mongo driver, but then it'd have the inverse problem any time someone tried using it with the native mongo driver.
Maybe @estolfo can help. Emily, am I understanding this correctly? Do you know how we can make the mongo ruby driver play nice with moped?
Hi! Sorry for the delay. Could you possibly do this with different gemsets (assuming you're using rvm)? Would that be possible with the way your environment is setup?
Yes, running two separate gemsets would fix the collision. But I'm not sure how that would be possible based on my issue described above. It's all within the same rails app - the ODM is Mongoid and I'm trying to mount Genghis in my route file.
In that case, unfortunately I don't think there's anything you can do. This issue will be resolved soon though when we release driver 2.0. @bobthecow Moped does not have the full feature set as the ruby driver does and once Mongoid starts using Ruby driver 2.0, you'll see less development on Moped. I wouldn't recommend putting in effort to rewrite Genghis to use Moped.
I didn't think it was worth rewriting. Do you have a sense for how far away ruby driver 2.0 is?
I can't tell you an exact date but it's our top priority after server version 2.8 comes out. So very soon!
@estolfo Sweet. Thanks!
@alauper I'm going to close this issue, since it looks like it won't be resolvable (until Ruby driver 2.0)
I'm running a rails 4 app. The minimum version of mongoid is >= 4. But mongoid 4 depends on bson 2.3 (through moped). Genghisapp depends on mongo <= 1.9.0, which depends on bson 1.8.
So they can't currently coexist - I can't add "mount Genghis::Server.new, at: '/genghis' " to my routes file.