Skip to content

Commit

Permalink
BUMP 1.0; minor doc / example fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
banker committed Apr 29, 2010
1 parent 60f7293 commit 159903e
Show file tree
Hide file tree
Showing 9 changed files with 30 additions and 9 deletions.
7 changes: 6 additions & 1 deletion 0.20_UPGRADE → 1.0_UPGRADE
Original file line number Diff line number Diff line change
@@ -1,4 +1,9 @@
0.20 will require some minor code upgrades.
You can upgrade freely from v0.20 to v1.0.

However, if you're running a version < 0.20, upgrade to 0.20
before upgrading to 1.0.

The upgrade to 0.20 requires some minor code upgrades.

1. Note the exception changes in HISTORY. Certain exceptions are now scoped under the BSON
module; if you're catching these, you will need to modify your code.
Expand Down
4 changes: 4 additions & 0 deletions CREDITS
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ Adrian Madrid, [email protected]

Aman Gupta, [email protected]
* Collection#save
* Noted bug in returning query batch size.

Jon Crosby, [email protected]
* Some code clean-up
Expand Down Expand Up @@ -74,3 +75,6 @@ Chuck Remes

Dmitrii Golub (Houdini) and Jacques Crocker (railsjedi)
* Support open to exclude fields on query

dfitzgibbon
* patch for ensuring bson_ext compatibility with early release of Ruby 1.8.5
12 changes: 12 additions & 0 deletions HISTORY
Original file line number Diff line number Diff line change
@@ -1,3 +1,15 @@
1.0 2010-4-29
Note: if upgrading from versions prior to 0.20, be sure to upgrade
to 0.20 before upgrading to 1.0.

* Inspected ObjectID is represented in MongoDB extended json format.
* Support for tailable cursors.
* Configurable query response batch size (thx. to Aman Gupta)

* bson_ext installs on early release of Ruby 1.8.5 (dfitzgibbon)
* Deprecated DB#create_index. Use Collection#create_index index.
* Removed deprecated Grid#put syntax; no longer requires a filename.

0.20.1 2010-4-7
* Added bson gem dependency.

Expand Down
1 change: 0 additions & 1 deletion README.rdoc
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ The driver also requires the BSON gem:
$ gem install bson

And for a significant performance boost, you'll want to install the C extensions:
extensions:

$ gem install bson_ext

Expand Down
7 changes: 4 additions & 3 deletions examples/admin.rb
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,14 @@
port = ENV['MONGO_RUBY_DRIVER_PORT'] || Connection::DEFAULT_PORT

puts "Connecting to #{host}:#{port}"
db = Mongo::Connection.new(host, port).db('ruby-mongo-examples')
con = Mongo::Connection.new(host, port)
db = con.db('ruby-mongo-examples')
coll = db.create_collection('test')

# Erase all records from collection, if any
coll.remove

admin = db.admin
admin = con['admin']

# Profiling level set/get
puts "Profiling level: #{admin.profiling_level}"
Expand All @@ -34,7 +35,7 @@

# Validate returns a hash if all is well and
# raises an exception if there is a problem.
info = admin.validate_collection(coll.name)
info = db.validate_collection(coll.name)
puts "valid = #{info['ok']}"
puts info['result']

Expand Down
2 changes: 1 addition & 1 deletion examples/info.rb
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
p db.collections_info

# Index information
db.create_index('test', 'a')
coll.create_index('a')
p db.index_information('test')

# Destroy the collection
Expand Down
2 changes: 1 addition & 1 deletion ext/cbson/version.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@
* limitations under the License.
*/

#define VERSION "0.20.2"
#define VERSION "1.0"
2 changes: 1 addition & 1 deletion lib/bson.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
$:.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))

module BSON
VERSION = "0.20.2"
VERSION = "1.0"
def self.serialize(obj, check_keys=false, move_id=false)
BSON_CODER.serialize(obj, check_keys, move_id)
end
Expand Down
2 changes: 1 addition & 1 deletion lib/mongo.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
$:.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))

module Mongo
VERSION = "0.20.2"
VERSION = "1.0"
end

module Mongo
Expand Down

0 comments on commit 159903e

Please sign in to comment.