mongo 1.10.0.rc0 → 1.10.0.rc1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +0 -0
- data.tar.gz.sig +0 -0
- data/VERSION +1 -1
- data/lib/mongo/bulk_write_collection_view.rb +31 -3
- data/lib/mongo/collection.rb +69 -25
- data/lib/mongo/collection_writer.rb +3 -2
- data/lib/mongo/connection/node.rb +5 -0
- data/lib/mongo/cursor.rb +4 -1
- data/lib/mongo/db.rb +23 -41
- data/lib/mongo/functional.rb +2 -0
- data/lib/mongo/functional/authentication.rb +18 -3
- data/lib/mongo/functional/sasl_java.rb +48 -0
- data/lib/mongo/functional/uri_parser.rb +62 -50
- data/lib/mongo/mongo_client.rb +24 -9
- data/lib/mongo/mongo_replica_set_client.rb +16 -5
- data/lib/mongo/networking.rb +3 -3
- data/lib/mongo/utils/conversions.rb +2 -1
- data/test/functional/authentication_test.rb +6 -1
- data/test/functional/bulk_api_stress_test.rb +133 -0
- data/test/functional/bulk_write_collection_view_test.rb +573 -226
- data/test/functional/client_test.rb +3 -1
- data/test/functional/collection_test.rb +336 -17
- data/test/functional/conversions_test.rb +32 -0
- data/test/functional/cursor_test.rb +3 -3
- data/test/functional/db_api_test.rb +2 -2
- data/test/functional/db_test.rb +24 -0
- data/test/functional/uri_test.rb +49 -32
- data/test/helpers/test_unit.rb +8 -0
- data/test/replica_set/authentication_test.rb +5 -1
- data/test/replica_set/client_test.rb +5 -4
- data/test/replica_set/max_values_test.rb +6 -0
- data/test/shared/authentication/basic_auth_shared.rb +101 -30
- data/test/shared/authentication/bulk_api_auth_shared.rb +259 -0
- data/test/shared/authentication/gssapi_shared.rb +164 -0
- data/test/shared/ssl_shared.rb +49 -27
- data/test/unit/client_test.rb +4 -2
- data/test/unit/connection_test.rb +4 -2
- data/test/unit/cursor_test.rb +12 -0
- data/test/unit/db_test.rb +6 -0
- metadata +27 -20
- metadata.gz.sig +0 -0
data/test/unit/client_test.rb
CHANGED
@@ -156,7 +156,8 @@ class ClientUnitTest < Test::Unit::TestCase
|
|
156
156
|
:username => 'hyphen-user_name',
|
157
157
|
:password => 'p-s_s',
|
158
158
|
:source => 'db',
|
159
|
-
:mechanism => Authentication::DEFAULT_MECHANISM
|
159
|
+
:mechanism => Authentication::DEFAULT_MECHANISM,
|
160
|
+
:extra => {}
|
160
161
|
}
|
161
162
|
assert_equal auth_hash, @client.auths.first
|
162
163
|
end
|
@@ -274,7 +275,8 @@ class ClientUnitTest < Test::Unit::TestCase
|
|
274
275
|
:username => 'hyphen-user_name',
|
275
276
|
:password => 'p-s_s',
|
276
277
|
:source => 'db',
|
277
|
-
:mechanism => Authentication::DEFAULT_MECHANISM
|
278
|
+
:mechanism => Authentication::DEFAULT_MECHANISM,
|
279
|
+
:extra => {}
|
278
280
|
}
|
279
281
|
assert_equal auth_hash, @client.auths.first
|
280
282
|
end
|
@@ -134,7 +134,8 @@ class ConnectionUnitTest < Test::Unit::TestCase
|
|
134
134
|
:username => 'hyphen-user_name',
|
135
135
|
:password => 'p-s_s',
|
136
136
|
:source => 'db',
|
137
|
-
:mechanism => Authentication::DEFAULT_MECHANISM
|
137
|
+
:mechanism => Authentication::DEFAULT_MECHANISM,
|
138
|
+
:extra => {}
|
138
139
|
}
|
139
140
|
assert_equal auth_hash, @connection.auths.first
|
140
141
|
end
|
@@ -252,7 +253,8 @@ class ConnectionUnitTest < Test::Unit::TestCase
|
|
252
253
|
:username => 'hyphen-user_name',
|
253
254
|
:password => 'p-s_s',
|
254
255
|
:source => 'db',
|
255
|
-
:mechanism => Authentication::DEFAULT_MECHANISM
|
256
|
+
:mechanism => Authentication::DEFAULT_MECHANISM,
|
257
|
+
:extra => {}
|
256
258
|
}
|
257
259
|
assert_equal auth_hash, @connection.auths.first
|
258
260
|
end
|
data/test/unit/cursor_test.rb
CHANGED
@@ -55,6 +55,18 @@ class CursorUnitTest < Test::Unit::TestCase
|
|
55
55
|
assert_equal({:name => 1, :date => 1}, @cursor.query_options_hash[:fields])
|
56
56
|
end
|
57
57
|
|
58
|
+
should "allow $meta projection operator" do
|
59
|
+
assert_nil @cursor.fields
|
60
|
+
|
61
|
+
@cursor = Cursor.new(@collection, :fields => [{ :score => { :$meta => 'textScore' } }])
|
62
|
+
assert_equal({ :score => { :$meta => 'textScore' } }, @cursor.fields)
|
63
|
+
assert_equal({ :score => { :$meta => 'textScore' } }, @cursor.query_options_hash[:fields])
|
64
|
+
|
65
|
+
@cursor = Cursor.new(@collection, :fields => [:name, { :score => { :$meta => 'textScore' } }])
|
66
|
+
assert_equal({ :name => 1, :score => { :$meta => 'textScore' } }, @cursor.fields)
|
67
|
+
assert_equal({ :name => 1, :score => { :$meta => 'textScore' } }, @cursor.query_options_hash[:fields])
|
68
|
+
end
|
69
|
+
|
58
70
|
should "set mix fields 0 and 1" do
|
59
71
|
assert_nil @cursor.fields
|
60
72
|
|
data/test/unit/db_test.rb
CHANGED
@@ -125,6 +125,12 @@ class DBUnitTest < Test::Unit::TestCase
|
|
125
125
|
assert @db.expects(:warn).with(regexp_matches(/\[DEPRECATED\] Disabling the 'save_auth' option/))
|
126
126
|
@db.authenticate('foo', 'bar', false)
|
127
127
|
end
|
128
|
+
|
129
|
+
should "allow extra authentication options" do
|
130
|
+
extra_opts = { :gssapiservicename => 'example', :canonicalizehostname => true }
|
131
|
+
assert @client.expects(:add_auth).with(@db.name, 'emily', nil, nil, 'GSSAPI', extra_opts)
|
132
|
+
@db.authenticate('emily', nil, nil, nil, 'GSSAPI', extra_opts)
|
133
|
+
end
|
128
134
|
end
|
129
135
|
end
|
130
136
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mongo
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.10.0.
|
4
|
+
version: 1.10.0.rc1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Tyler Brock
|
@@ -16,25 +16,25 @@ cert_chain:
|
|
16
16
|
-----BEGIN C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
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
30
|
+
KoZIhvcNAQEFBQADggEBALGvdxHF+CnH6QO4PeIce3S8EHuHsYiGLk4sWgNGZkjD
|
31
|
+
V3C4XjlI8rQZxalwQwcauacOGj9x94flWUXruEF7+rjUtig7OIrQK2+uVg86vl8r
|
32
|
+
xy1n2s1d31KsuazEVExe5o19tnVbI9+30P9qPkS+NgaellXpj5c5qnJUGn5BJtzo
|
33
|
+
3D001zXpVnuZvCcE/A4fQ+BEM0zm0oOmA/gWIAFrufOL9oYg1881dRZ+kQytF/9c
|
34
|
+
JrZM8w8wGbIOeLtoQqa7HB/jOYbTahH7KMNh2LHAbOR93hNIJxVRa4iwxiMQ75tN
|
35
|
+
9WUIAJ4AEtjwRg1Bz0OwDo3aucPCBpx77+/FWhv7JYY=
|
36
36
|
-----END CERTIFICATE-----
|
37
|
-
date: 2014-
|
37
|
+
date: 2014-03-17 00:00:00.000000000 Z
|
38
38
|
dependencies:
|
39
39
|
- !ruby/object:Gem::Dependency
|
40
40
|
name: bson
|
@@ -42,14 +42,14 @@ dependencies:
|
|
42
42
|
requirements:
|
43
43
|
- - "~>"
|
44
44
|
- !ruby/object:Gem::Version
|
45
|
-
version: 1.10.0.
|
45
|
+
version: 1.10.0.rc1
|
46
46
|
type: :runtime
|
47
47
|
prerelease: false
|
48
48
|
version_requirements: !ruby/object:Gem::Requirement
|
49
49
|
requirements:
|
50
50
|
- - "~>"
|
51
51
|
- !ruby/object:Gem::Version
|
52
|
-
version: 1.10.0.
|
52
|
+
version: 1.10.0.rc1
|
53
53
|
description: A Ruby driver for MongoDB. For more information about Mongo, see http://www.mongodb.org.
|
54
54
|
email: mongodb-dev@googlegroups.com
|
55
55
|
executables:
|
@@ -83,6 +83,7 @@ files:
|
|
83
83
|
- lib/mongo/functional/authentication.rb
|
84
84
|
- lib/mongo/functional/logging.rb
|
85
85
|
- lib/mongo/functional/read_preference.rb
|
86
|
+
- lib/mongo/functional/sasl_java.rb
|
86
87
|
- lib/mongo/functional/uri_parser.rb
|
87
88
|
- lib/mongo/functional/write_concern.rb
|
88
89
|
- lib/mongo/gridfs.rb
|
@@ -103,6 +104,7 @@ files:
|
|
103
104
|
- lib/mongo/utils/thread_local_variable_manager.rb
|
104
105
|
- mongo.gemspec
|
105
106
|
- test/functional/authentication_test.rb
|
107
|
+
- test/functional/bulk_api_stress_test.rb
|
106
108
|
- test/functional/bulk_write_collection_view_test.rb
|
107
109
|
- test/functional/client_test.rb
|
108
110
|
- test/functional/collection_test.rb
|
@@ -143,6 +145,8 @@ files:
|
|
143
145
|
- test/replica_set/ssl_test.rb
|
144
146
|
- test/sharded_cluster/basic_test.rb
|
145
147
|
- test/shared/authentication/basic_auth_shared.rb
|
148
|
+
- test/shared/authentication/bulk_api_auth_shared.rb
|
149
|
+
- test/shared/authentication/gssapi_shared.rb
|
146
150
|
- test/shared/authentication/sasl_plain_shared.rb
|
147
151
|
- test/shared/ssl_shared.rb
|
148
152
|
- test/test_helper.rb
|
@@ -183,12 +187,13 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
183
187
|
version: 1.3.1
|
184
188
|
requirements: []
|
185
189
|
rubyforge_project: mongo
|
186
|
-
rubygems_version: 2.2.
|
190
|
+
rubygems_version: 2.2.2
|
187
191
|
signing_key:
|
188
192
|
specification_version: 4
|
189
193
|
summary: Ruby driver for MongoDB
|
190
194
|
test_files:
|
191
195
|
- test/functional/authentication_test.rb
|
196
|
+
- test/functional/bulk_api_stress_test.rb
|
192
197
|
- test/functional/bulk_write_collection_view_test.rb
|
193
198
|
- test/functional/client_test.rb
|
194
199
|
- test/functional/collection_test.rb
|
@@ -229,6 +234,8 @@ test_files:
|
|
229
234
|
- test/replica_set/ssl_test.rb
|
230
235
|
- test/sharded_cluster/basic_test.rb
|
231
236
|
- test/shared/authentication/basic_auth_shared.rb
|
237
|
+
- test/shared/authentication/bulk_api_auth_shared.rb
|
238
|
+
- test/shared/authentication/gssapi_shared.rb
|
232
239
|
- test/shared/authentication/sasl_plain_shared.rb
|
233
240
|
- test/shared/ssl_shared.rb
|
234
241
|
- test/test_helper.rb
|
metadata.gz.sig
CHANGED
Binary file
|