jnunemaker/mongomapper — pull request #368 by balexand (2011-12-20 22:47:55+00:00)
Title: Use MongoDB connection options from yaml config file

The [constructor for `Mongo::Connection`](http://api.mongodb.org/ruby/current/Mongo/Connection.html#initialize-instance_method) takes several options. Currently, there is no way to configure these options in MongoMapper's YAML config file. This simple patch allows the connection options to be configured via the YAML config file like:

defaults: &defaults
host: 127.0.0.1
port: 27017
connection_options:
safe: true
# etc...

As usual, I'm open to feedback so let me know if you'd like anything done differently. Thanks!