Sha256: acce41314dd118376f24afd429ea27c0774035659679181815cee6ed090e3d43
Contents?: true
Size: 1.14 KB
Versions: 2
Compression:
Stored size: 1.14 KB
Contents
# Hikki::Adapters::MongoAdapter A Mongo adapter for Hikki. It uses the `mongo` gem to communicate with Mongo. ## Installation Add this line to your application's Gemfile: gem 'hikki-mongo' And then execute: $ bundle Or install it yourself as: $ gem install hikki-mongo ## Usage By default, the adapter will use `Mongo::MongoClient.new` as it's connection which uses the defaults in that gem. You can pass in your own connection to use instead, useful for specifying a server and other options. ```ruby # Use the default connection adapter = Hikki::Adapters::MongoAdapter.new # Use a specific connection mongo = Mongo::MongoClient.new("db.example.com", 27017) adapter = Hikki::Adapters::MongoAdapter.new(mongo) ``` If you do not specify an `id` when saving, the adapter will generate a `BSON::ObjectId`. ## Contributing 1. Fork it ( http://github.com/originate/hikki/fork ) 2. Create your feature branch (`git checkout -b my-new-feature`) 3. Write your specifications 4. Implement your specifications 5. Commit your changes (`git commit -am 'Add some feature'`) 6. Push to the branch (`git push origin my-new-feature`) 7. Create new Pull Request
Version data entries
2 entries across 2 versions & 2 rubygems
Version | Path |
---|---|
hikki-mongo-0.0.1 | README.md |
hikki-0.0.1 | adapters/hikki-mongo/README.md |