Questions tagged [mongomapper]

Mongomapper is a Ruby gem allowing you to map ruby objects to MongoDB documents.

Mongomapper is a Ruby gem allowing you to map ruby objects to MongoDB documents. It allows you to search, use the caching layer, have callbacks, etc. It also lets you create simple plugins for it, in case it's missing some functionality for you.

Take a look at MongoMapper.com for more information.

513 questions
94
votes
5 answers

Mongodb: What to know before using?

I'm starting a hobby (non-revenue) project using Ruby on Rails. I've done a fair amount of development in Rails using Postgresql, and I can make a pretty good imitation of normalized schema. However, Mongrodb looks shiny and new. What better for…
Wayne Conrad
  • 103,207
  • 26
  • 155
  • 191
83
votes
14 answers

Mongoid or MongoMapper?

I have tried MongoMapper and it is feature complete (offering almost all AR functionality) but i was not very happy with the performance when using large datasets. Has anyone compared with Mongoid? Any performance gains ?
PanosJee
  • 3,866
  • 6
  • 36
  • 49
23
votes
9 answers

MongoMapper and migrations

I'm building a Rails application using MongoDB as the back-end and MongoMapper as the ORM tool. Suppose in version 1, I define the following model: class SomeModel include MongoMapper::Document key :some_key, String end Later in version 2, I…
Clint Miller
  • 15,173
  • 4
  • 37
  • 39
20
votes
3 answers

ERROR Errno::ECONNRESET: Connection reset by peer

gem 'rails', '3.0.0' gem 'devise' gem 'bson_ext', '>= 1.0.7' gem 'bson', '>= 1.0.7' gem 'mongo_mapper', :branch => 'rails3', :git => 'http://github.com/jnunemaker/mongomapper.git' gem 'devise-mongo_mapper', :git =>…
randomguy
  • 12,042
  • 16
  • 71
  • 101
20
votes
3 answers

How to mix mongodb and a traditional db in Rails?

I am considering using MongoDB (mongo-mapper) for a portion of my rails application. I am not ready to go whole hog MongoDB because there are too many useful gems that depend on a traditional DB. That being said there are parts of my application…
Jonathan
  • 16,077
  • 12
  • 67
  • 106
16
votes
3 answers

Rails: Store JSON in MongoDB

I am getting multiple similar JSON object from a remote site and looking to store them in a local MongoDB. What would be the best way to do this ? (Preferably via Mongoid or Mongo-mapper gems) Thanks
Boris
  • 3,163
  • 5
  • 37
  • 46
15
votes
8 answers

What is your preferred ODM in Ruby? MongoMapper, MongoID or MongoDoc?

In Ruby, there are currently 3 ODM (object data mappers) maintained: MongoMapper Mongoid MongoDoc Which is your preferred and why?
shingara
  • 46,608
  • 11
  • 99
  • 105
13
votes
2 answers

How to write a Devise extension (to use a custom datastore)

I'd like to write an extension for Devise that allows you to use parse_resource as the datastore (as opposed to ActiveRecord). parse_resource is a Ruby wrapper for Parse.com's REST api. It's interface is pretty much the same as ActiveRecord's and is…
user94154
  • 16,176
  • 20
  • 77
  • 116
13
votes
8 answers

N+1 problem in mongoid

I'm using Mongoid to work with MongoDB in Rails. What I'm looking for is something like active record include. Currently I failed to find such method in mongoid orm. Anybody know how to solve this problem in mongoid or perhaps in mongomapper, which…
Alexey Zakharov
  • 24,694
  • 42
  • 126
  • 197
13
votes
2 answers

Understanding MongoDB (and NoSQL in general) and how to make the best use of it

I am beginning to think that my next project I am wanting to do would work better with a NoSQL solution. The project would either involve a ton of 2-column tables or a ton of dynamic queries with dynamically generated columns in a traditional SQL…
Earlz
  • 62,085
  • 98
  • 303
  • 499
11
votes
1 answer

Understanding MongoMappers many relationship

Ok, so firstly Im not very in the know when it comes to Ruby, Rails, Mongo or even ActiveRecord so I apologise if these questions are fairly basic. Firstly, I have an "Event" model and I have added a many relationship to my "Comment" model. Now it…
Owen
  • 6,992
  • 7
  • 44
  • 77
10
votes
1 answer

mongo_mapper or mongoid with rails4

The ORM mongo_mapper and mongoid both support ruby on rails. However, after reading their documents I still cannot make a decision which one to use to develop a new application with rails4. Any suggestion?
canoe
  • 1,273
  • 13
  • 29
9
votes
6 answers

MongoMapper and bson_ext problem

I can't get MongoMapper to work with my Rails app. I get this error message: **Notice: C extension not loaded. This is required for optimum MongoDB Ruby driver performance. You can install the extension as follows: gem install bson_ext If you…
Fossmo
  • 2,862
  • 4
  • 25
  • 47
9
votes
2 answers

Rails + MongoMapper + EmbeddedDocument form help

I am working on a pretty simple web application (famous last words) and am working with Rails 2.3.5 + MongoMapper 0.7.2 and using embedded documents. I have two questions to ask: First, are there any example applications out there using Rails +…
Bob Martens
  • 13,542
  • 3
  • 17
  • 9
9
votes
1 answer

Advice on migrating from MongoMapper to Mongoid?

It seems like Mongoid is now the superior ORM for Mongo based on performance and development activity. Unfortunately, we're on MongoMapper and need to migrate. Are there any concerns or stumbling blocks we should be aware of? We have found a few…
Crashalot
  • 33,605
  • 61
  • 269
  • 439
1
2 3
34 35