Ruby driver for MongoDB
Go to file
Jim Menard efd31a8bc5 Added TODO comments and separate code path for unimplemented types in deserialize 2009-01-07 17:13:21 -05:00
bin Updated console to default ENV parameters 2008-12-29 15:16:35 -07:00
examples end-of-file newlines 2009-01-06 10:47:29 -05:00
lib Added TODO comments and separate code path for unimplemented types in deserialize 2009-01-07 17:13:21 -05:00
tests Completed Admin implementation. 2009-01-07 16:12:01 -05:00
.gitignore Fixed gem info 2008-12-29 16:40:59 -07:00
README.rdoc group_by docs 2009-01-07 16:56:34 -05:00
Rakefile Added executable spec for mongo_console 2009-01-05 14:48:04 -07:00

README.rdoc

= Introduction

This is a Ruby driver for the 10gen Mongo DB. For more information about
Mongo, see http://www.mongodb.org.

Note: this driver is still alpha quality. The API will change, as *may* the
data saved to the database (especially primary key values). Do *_not_* use
this for any production data yet.


= Demo

Mongo must be running, of course.

  $ ruby examples/simple.rb

See also the test code, especially
http://github.com/jimm/mongo-ruby-driver/tree/master/tests/test_db_api.rb


= Testing

  $ rake test

The tests assume that the Mongo database is running on the default port.


= Documentation

  $ rake rdoc

Then open the file doc/index.html. (I need to figure out where to put this on
the Web, or perhaps how to publish this to the Wiki at
http://github.com/jimm/mongo-ruby-driver/wikis automatically. I have applied
for a RubyForge project, so the docs will eventually go there.)


= Release Notes

See the git log comments.


= To Do

* Add :publish Rake task, once we get a RubyForge project.

* Add group_by. Need to figure out how we are going to send functions. The
  current thinking is that Mongo will allow a subset of JavaScript (which we
  would have to send as a string), but this is still under discussion.

* Add explain and hint support.

* Only update message sizes once, not after every write of a value. This will
  require an explicit call to update_message_length in each message subclass.

* Tests for update and repsert.

* Add a way to specify a collection of databases on startup (a simple array of
  IP address/port numbers, perhaps, or a hash or something). The driver would
  then find the master and, on each subsequent command, ask that machine if it
  is the master before proceeding.

* Tests that prove that this driver's ObjectID and Geir's Java version do the
  same thing. (I've done so manually.)

* Support more types: REF, SYMBOL, CODE_W_SCOPE, etc.

* Introduce optional per-database and per-collection PKInjector.

* More tests.

* Study src/main/ed/db/{dbcollection,dbcursor,db}.js and ByteEncoder.java in
  the Babble code. That's what I should be writing to.


= Credits

Adrian Madrid, aemadrid@gmail.com
* bin/mongo_console
* examples/benchmarks.rb
* examples/irb.rb
* Modifications to examples/simple.rb
* Found plenty of bugs and missing features.
* Ruby 1.9 support.
* Gem support.
* Many other code suggestions and improvements.


= License

== Mongo Ruby Driver

Copyright (C) 2008-2009 10gen Inc.

This program is free software: you can redistribute it and/or modify it under
the terms of the GNU Affero General Public License, version 3, as published by
the Free Software Foundation.

This program is distributed in the hope that it will be useful, but WITHOUT
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more
details.

See http://www.gnu.org/licenses for a copy of the GNU Affero General Public
License.