mongo 2.1.2 → 2.2.0.rc0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (140) hide show
  1. checksums.yaml +4 -4
  2. checksums.yaml.gz.sig +0 -0
  3. data.tar.gz.sig +0 -0
  4. data/README.md +10 -3
  5. data/Rakefile +1 -7
  6. data/lib/csasl/csasl.bundle +0 -0
  7. data/lib/mongo/auth/user/view.rb +1 -1
  8. data/lib/mongo/bulk_write.rb +7 -1
  9. data/lib/mongo/client.rb +17 -15
  10. data/lib/mongo/cluster.rb +4 -2
  11. data/lib/mongo/collection.rb +36 -2
  12. data/lib/mongo/collection/view.rb +24 -21
  13. data/lib/mongo/collection/view/aggregation.rb +5 -42
  14. data/lib/mongo/collection/view/builder.rb +20 -0
  15. data/lib/mongo/collection/view/builder/aggregation.rb +98 -0
  16. data/lib/mongo/collection/view/builder/find_command.rb +111 -0
  17. data/lib/mongo/collection/view/builder/flags.rb +62 -0
  18. data/lib/mongo/collection/view/builder/map_reduce.rb +134 -0
  19. data/lib/mongo/collection/view/builder/modifiers.rb +80 -0
  20. data/lib/mongo/collection/view/builder/op_query.rb +83 -0
  21. data/lib/mongo/collection/view/explainable.rb +15 -0
  22. data/lib/mongo/collection/view/immutable.rb +5 -12
  23. data/lib/mongo/collection/view/iterable.rb +24 -2
  24. data/lib/mongo/collection/view/map_reduce.rb +18 -27
  25. data/lib/mongo/collection/view/readable.rb +70 -112
  26. data/lib/mongo/collection/view/writable.rb +23 -7
  27. data/lib/mongo/cursor.rb +76 -25
  28. data/lib/mongo/cursor/builder.rb +18 -0
  29. data/lib/mongo/cursor/builder/get_more_command.rb +71 -0
  30. data/lib/mongo/cursor/builder/kill_cursors_command.rb +62 -0
  31. data/lib/mongo/cursor/builder/op_get_more.rb +61 -0
  32. data/lib/mongo/cursor/builder/op_kill_cursors.rb +56 -0
  33. data/lib/mongo/database.rb +2 -2
  34. data/lib/mongo/database/view.rb +9 -5
  35. data/lib/mongo/dbref.rb +3 -3
  36. data/lib/mongo/error.rb +1 -0
  37. data/lib/mongo/error/invalid_write_concern.rb +35 -0
  38. data/lib/mongo/grid/file/chunk.rb +2 -2
  39. data/lib/mongo/index/view.rb +5 -2
  40. data/lib/mongo/operation.rb +1 -0
  41. data/lib/mongo/operation/commands.rb +2 -0
  42. data/lib/mongo/operation/commands/aggregate.rb +39 -45
  43. data/lib/mongo/operation/commands/aggregate/result.rb +54 -68
  44. data/lib/mongo/operation/commands/collections_info.rb +38 -36
  45. data/lib/mongo/operation/commands/collections_info/result.rb +17 -15
  46. data/lib/mongo/operation/commands/command.rb +24 -22
  47. data/lib/mongo/operation/commands/find.rb +27 -0
  48. data/lib/mongo/operation/commands/find/result.rb +62 -0
  49. data/lib/mongo/operation/commands/get_more.rb +27 -0
  50. data/lib/mongo/operation/commands/get_more/result.rb +62 -0
  51. data/lib/mongo/operation/commands/indexes.rb +41 -39
  52. data/lib/mongo/operation/commands/list_collections.rb +25 -31
  53. data/lib/mongo/operation/commands/list_collections/result.rb +63 -81
  54. data/lib/mongo/operation/commands/list_indexes.rb +27 -35
  55. data/lib/mongo/operation/commands/list_indexes/result.rb +67 -85
  56. data/lib/mongo/operation/commands/map_reduce.rb +29 -37
  57. data/lib/mongo/operation/commands/map_reduce/result.rb +85 -88
  58. data/lib/mongo/operation/commands/parallel_scan.rb +29 -33
  59. data/lib/mongo/operation/commands/parallel_scan/result.rb +34 -42
  60. data/lib/mongo/operation/commands/user_query.rb +40 -38
  61. data/lib/mongo/operation/commands/users_info.rb +24 -29
  62. data/lib/mongo/operation/commands/users_info/result.rb +13 -11
  63. data/lib/mongo/operation/object_id_generator.rb +36 -0
  64. data/lib/mongo/operation/result.rb +30 -0
  65. data/lib/mongo/operation/specifiable.rb +35 -1
  66. data/lib/mongo/operation/write/bulk/bulkable.rb +4 -3
  67. data/lib/mongo/operation/write/bulk/delete/result.rb +18 -25
  68. data/lib/mongo/operation/write/bulk/legacy_mergable.rb +2 -2
  69. data/lib/mongo/operation/write/command/delete.rb +3 -2
  70. data/lib/mongo/operation/write/command/insert.rb +4 -2
  71. data/lib/mongo/operation/write/command/update.rb +6 -3
  72. data/lib/mongo/operation/write/gle.rb +2 -1
  73. data/lib/mongo/operation/write/idable.rb +19 -2
  74. data/lib/mongo/options/mapper.rb +22 -0
  75. data/lib/mongo/protocol/bit_vector.rb +3 -3
  76. data/lib/mongo/protocol/delete.rb +15 -5
  77. data/lib/mongo/protocol/get_more.rb +10 -5
  78. data/lib/mongo/protocol/insert.rb +1 -6
  79. data/lib/mongo/protocol/kill_cursors.rb +14 -1
  80. data/lib/mongo/protocol/message.rb +32 -8
  81. data/lib/mongo/protocol/serializers.rb +15 -16
  82. data/lib/mongo/protocol/update.rb +35 -12
  83. data/lib/mongo/server/connectable.rb +3 -1
  84. data/lib/mongo/server/connection.rb +5 -5
  85. data/lib/mongo/server/description.rb +8 -2
  86. data/lib/mongo/server/description/features.rb +2 -1
  87. data/lib/mongo/server/monitor.rb +1 -12
  88. data/lib/mongo/server/monitor/connection.rb +30 -26
  89. data/lib/mongo/server_selector/selectable.rb +21 -4
  90. data/lib/mongo/uri.rb +2 -0
  91. data/lib/mongo/version.rb +1 -1
  92. data/lib/mongo/write_concern.rb +21 -6
  93. data/mongo.gemspec +1 -2
  94. data/spec/mongo/bulk_write/ordered_combiner_spec.rb +13 -0
  95. data/spec/mongo/bulk_write_spec.rb +58 -0
  96. data/spec/mongo/client_spec.rb +6 -4
  97. data/spec/mongo/collection/view/builder/find_command_spec.rb +167 -0
  98. data/spec/mongo/collection/view/builder/flags_spec.rb +106 -0
  99. data/spec/mongo/collection/view/builder/modifiers_spec.rb +210 -0
  100. data/spec/mongo/collection/view/builder/op_query_spec.rb +154 -0
  101. data/spec/mongo/collection/view/explainable_spec.rb +1 -2
  102. data/spec/mongo/collection/view/immutable_spec.rb +3 -52
  103. data/spec/mongo/collection/view/map_reduce_spec.rb +12 -12
  104. data/spec/mongo/collection/view/readable_spec.rb +86 -80
  105. data/spec/mongo/collection/view_spec.rb +109 -703
  106. data/spec/mongo/collection_spec.rb +594 -11
  107. data/spec/mongo/command_monitoring_spec.rb +40 -27
  108. data/spec/mongo/cursor/builder/get_more_command_spec.rb +160 -0
  109. data/spec/mongo/cursor/builder/op_get_more_spec.rb +52 -0
  110. data/spec/mongo/cursor_spec.rb +10 -60
  111. data/spec/mongo/database_spec.rb +24 -3
  112. data/spec/mongo/dbref_spec.rb +4 -4
  113. data/spec/mongo/grid/file/chunk_spec.rb +1 -1
  114. data/spec/mongo/grid/fs_bucket_spec.rb +3 -3
  115. data/spec/mongo/index/view_spec.rb +41 -0
  116. data/spec/mongo/operation/{aggregate → commands/aggregate}/result_spec.rb +1 -1
  117. data/spec/mongo/operation/commands/aggregate_spec.rb +1 -1
  118. data/spec/mongo/operation/commands/collections_info_spec.rb +1 -1
  119. data/spec/mongo/operation/commands/command_spec.rb +1 -1
  120. data/spec/mongo/operation/commands/indexes_spec.rb +1 -1
  121. data/spec/mongo/operation/commands/map_reduce_spec.rb +1 -1
  122. data/spec/mongo/operation/write/command/delete_spec.rb +25 -0
  123. data/spec/mongo/operation/write/command/insert_spec.rb +25 -0
  124. data/spec/mongo/operation/write/command/update_spec.rb +25 -0
  125. data/spec/mongo/protocol/delete_spec.rb +4 -4
  126. data/spec/mongo/protocol/get_more_spec.rb +4 -4
  127. data/spec/mongo/protocol/insert_spec.rb +3 -3
  128. data/spec/mongo/protocol/kill_cursors_spec.rb +3 -3
  129. data/spec/mongo/protocol/query_spec.rb +7 -7
  130. data/spec/mongo/protocol/update_spec.rb +5 -5
  131. data/spec/mongo/server/description/features_spec.rb +25 -0
  132. data/spec/mongo/write_concern_spec.rb +126 -0
  133. data/spec/spec_helper.rb +9 -19
  134. data/spec/support/command_monitoring.rb +8 -0
  135. data/spec/support/command_monitoring/find.yml +53 -4
  136. data/spec/support/matchers.rb +1 -1
  137. data/spec/support/shared/protocol.rb +5 -5
  138. data/spec/support/travis.rb +1 -1
  139. metadata +43 -10
  140. metadata.gz.sig +0 -0
@@ -56,6 +56,31 @@ describe Mongo::Server::Description::Features do
56
56
  end
57
57
  end
58
58
 
59
+ describe '#find_command_enabled?' do
60
+
61
+ context 'when the wire range includes 4' do
62
+
63
+ let(:features) do
64
+ described_class.new(0..4)
65
+ end
66
+
67
+ it 'returns true' do
68
+ expect(features).to be_find_command_enabled
69
+ end
70
+ end
71
+
72
+ context 'when the wire range does not include 4' do
73
+
74
+ let(:features) do
75
+ described_class.new(0..2)
76
+ end
77
+
78
+ it 'returns false' do
79
+ expect(features).to_not be_find_command_enabled
80
+ end
81
+ end
82
+ end
83
+
59
84
  describe '#list_collections_enabled?' do
60
85
 
61
86
  context 'when the wire range includes 3' do
@@ -0,0 +1,126 @@
1
+ require 'spec_helper'
2
+
3
+ describe Mongo::WriteConcern do
4
+
5
+ describe '#get' do
6
+
7
+ context 'when no options are set' do
8
+
9
+ let(:options) do
10
+ { }
11
+ end
12
+
13
+ it 'returns an Acknowledged write concern object' do
14
+ expect(Mongo::WriteConcern.get(options)).to be_a(Mongo::WriteConcern::Acknowledged)
15
+ end
16
+ end
17
+
18
+ context 'when w is 0' do
19
+
20
+ context 'when no other options are provided' do
21
+
22
+ let(:options) do
23
+ { w: 0 }
24
+ end
25
+
26
+ it 'returns an Unacknowledged write concern object' do
27
+ expect(Mongo::WriteConcern.get(options)).to be_a(Mongo::WriteConcern::Unacknowledged)
28
+ end
29
+ end
30
+
31
+ context 'when j is also provided' do
32
+
33
+ context 'when j is false' do
34
+
35
+ let(:options) do
36
+ { w: 0, j: false }
37
+ end
38
+
39
+ it 'returns an Unacknowledged write concern object' do
40
+ expect(Mongo::WriteConcern.get(options)).to be_a(Mongo::WriteConcern::Unacknowledged)
41
+ end
42
+ end
43
+
44
+ context 'when j is true' do
45
+
46
+ let(:options) do
47
+ { w: 0, j: true }
48
+ end
49
+
50
+ it 'raises an exception' do
51
+ expect {
52
+ Mongo::WriteConcern.get(options)
53
+ }.to raise_error(Mongo::Error::InvalidWriteConcern)
54
+ end
55
+ end
56
+
57
+ context 'when fsync is true' do
58
+
59
+ let(:options) do
60
+ { w: 0, fsync: true }
61
+ end
62
+
63
+ it 'raises an exception' do
64
+ expect {
65
+ Mongo::WriteConcern.get(options)
66
+ }.to raise_error(Mongo::Error::InvalidWriteConcern)
67
+ end
68
+ end
69
+ end
70
+
71
+ context 'when wtimeout is also provided' do
72
+
73
+ let(:options) do
74
+ { w: 0, wimteout: 100 }
75
+ end
76
+
77
+ it 'returns an Unacknowledged write concern object' do
78
+ expect(Mongo::WriteConcern.get(options)).to be_a(Mongo::WriteConcern::Unacknowledged)
79
+ end
80
+ end
81
+ end
82
+
83
+ context 'when w is less than 0' do
84
+
85
+ let(:options) do
86
+ { w: -1 }
87
+ end
88
+
89
+ it 'raises an exception' do
90
+ expect {
91
+ Mongo::WriteConcern.get(options)
92
+ }.to raise_error(Mongo::Error::InvalidWriteConcern)
93
+ end
94
+ end
95
+
96
+ context 'when w is greater than 0' do
97
+
98
+ let(:options) do
99
+ { w: 2, journal: true }
100
+ end
101
+
102
+ it 'returns an Acknowledged write concern object' do
103
+ expect(Mongo::WriteConcern.get(options)).to be_a(Mongo::WriteConcern::Acknowledged)
104
+ end
105
+
106
+ it 'sets the options' do
107
+ expect(Mongo::WriteConcern.get(options).options).to eq(options)
108
+ end
109
+ end
110
+
111
+ context 'when w is a string' do
112
+
113
+ let(:options) do
114
+ { w: 'majority', journal: true }
115
+ end
116
+
117
+ it 'returns an Acknowledged write concern object' do
118
+ expect(Mongo::WriteConcern.get(options)).to be_a(Mongo::WriteConcern::Acknowledged)
119
+ end
120
+
121
+ it 'sets the options' do
122
+ expect(Mongo::WriteConcern.get(options).options).to eq(options)
123
+ end
124
+ end
125
+ end
126
+ end
@@ -1,22 +1,3 @@
1
- if RUBY_VERSION > '1.9' && RUBY_VERSION < '2.2'
2
- require 'simplecov'
3
- require 'coveralls'
4
-
5
- SimpleCov.formatter = SimpleCov::Formatter::MultiFormatter[
6
- SimpleCov::Formatter::HTMLFormatter,
7
- Coveralls::SimpleCov::Formatter
8
- ]
9
-
10
- SimpleCov.start do
11
- # report groups
12
- add_group 'Wire Protocol', 'lib/mongo/protocol'
13
- # filters
14
- add_filter 'tasks'
15
- add_filter 'spec'
16
- add_filter 'bin'
17
- end
18
- end
19
-
20
1
  TEST_SET = 'ruby-driver-rs'
21
2
  COVERAGE_MIN = 90
22
3
  CURRENT_PATH = File.expand_path(File.dirname(__FILE__))
@@ -138,6 +119,15 @@ def single_seed?
138
119
  ADDRESSES.size == 1
139
120
  end
140
121
 
122
+ # For instances where behaviour is different on different versions, we need to
123
+ # determine in the specs if we are 3.2 or higher.
124
+ #
125
+ # @since 2.0.0
126
+ def find_command_enabled?
127
+ $mongo_client ||= initialize_scanned_client!
128
+ $find_command_enabled ||= $mongo_client.cluster.servers.first.features.find_command_enabled?
129
+ end
130
+
141
131
  # For instances where behaviour is different on different versions, we need to
142
132
  # determine in the specs if we are 2.6 or higher.
143
133
  #
@@ -227,6 +227,12 @@ module Mongo
227
227
  # @return [ Array<Expectation> ] The expectations.
228
228
  attr_reader :expectations
229
229
 
230
+ # @return [ String ] The server version to ignore if greater.
231
+ attr_reader :ignore_if_server_version_greater_than
232
+
233
+ # @return [ String ] The server version to ignore if lower.
234
+ attr_reader :ignore_if_server_version_less_than
235
+
230
236
  # Create the new test.
231
237
  #
232
238
  # @example Create the test.
@@ -239,6 +245,8 @@ module Mongo
239
245
  def initialize(data, test)
240
246
  @data = data
241
247
  @description = test['description']
248
+ @ignore_if_server_version_greater_than = test['ignore_if_server_version_greater_than']
249
+ @ignore_if_server_version_less_than = test['ignore_if_server_version_less_than']
242
250
  @operation = Mongo::CRUD::Operation.get(test['operation'])
243
251
  @expectations = test['expectations'].map{ |e| Expectation.new(e) }
244
252
  end
@@ -38,10 +38,10 @@ tests:
38
38
  description: "A successful find event with options"
39
39
  operation:
40
40
  name: "find"
41
+ read_preference: { mode: "primaryPreferred" }
41
42
  arguments:
42
43
  filter: { _id: { $gt: 1 } }
43
44
  sort: { _id: 1 }
44
- limit: 2
45
45
  skip: 2
46
46
  modifiers:
47
47
  $comment: "test"
@@ -50,7 +50,6 @@ tests:
50
50
  $maxScan: 5000
51
51
  $maxTimeMS: 6000
52
52
  $min: { _id: 0 }
53
- $readPreference: { mode: "secondaryPreferred" }
54
53
  $returnKey: false
55
54
  $showDiskLoc: false
56
55
  $snapshot: false
@@ -61,7 +60,6 @@ tests:
61
60
  find: *collection_name
62
61
  filter: { _id: { $gt: 1 } }
63
62
  sort: { _id: 1 }
64
- limit: 2
65
63
  skip: 2
66
64
  comment: "test"
67
65
  hint: { _id: 1 }
@@ -69,7 +67,6 @@ tests:
69
67
  maxScan: 5000
70
68
  maxTimeMS: 6000
71
69
  min: { _id: 0 }
72
- readPreference: { mode: "secondaryPreferred" }
73
70
  returnKey: false
74
71
  showRecordId: false
75
72
  snapshot: false
@@ -137,6 +134,7 @@ tests:
137
134
  command_name: "getMore"
138
135
  -
139
136
  description: "A successful find event with a getmore and killcursors"
137
+ ignore_if_server_version_greater_than: "3.0"
140
138
  operation:
141
139
  name: "find"
142
140
  arguments:
@@ -200,6 +198,57 @@ tests:
200
198
  cursorsUnknown:
201
199
  - { $numberLong: "42" }
202
200
  command_name: "killCursors"
201
+ -
202
+ description: "A successful find event with a getmore and the server kills the cursor"
203
+ ignore_if_server_version_less_than: "3.1"
204
+ operation:
205
+ name: "find"
206
+ arguments:
207
+ filter: { _id: { $gte: 1 }}
208
+ sort: { _id: 1 }
209
+ batchSize: 3
210
+ limit: 4
211
+ expectations:
212
+ -
213
+ command_started_event:
214
+ command:
215
+ find: *collection_name
216
+ filter: { _id: { $gte : 1 }}
217
+ sort: { _id: 1 }
218
+ batchSize: 3
219
+ limit: 4
220
+ command_name: "find"
221
+ database_name: *database_name
222
+ -
223
+ command_succeeded_event:
224
+ reply:
225
+ ok: 1.0
226
+ cursor:
227
+ id: { $numberLong: "42" }
228
+ ns: *namespace
229
+ firstBatch:
230
+ - { _id: 1, x: 11 }
231
+ - { _id: 2, x: 22 }
232
+ - { _id: 3, x: 33 }
233
+ command_name: "find"
234
+ -
235
+ command_started_event:
236
+ command:
237
+ getMore: { $numberLong: "42" }
238
+ collection: *collection_name
239
+ batchSize: 3
240
+ command_name: "getMore"
241
+ database_name: *database_name
242
+ -
243
+ command_succeeded_event:
244
+ reply:
245
+ ok: 1.0
246
+ cursor:
247
+ id: { $numberLong: "0" }
248
+ ns: *namespace
249
+ nextBatch:
250
+ - { _id: 4, x: 44 }
251
+ command_name: "getMore"
203
252
  -
204
253
  description: "A failed find event"
205
254
  operation:
@@ -26,7 +26,7 @@ end
26
26
 
27
27
  RSpec::Matchers.define :be_bson do |hash|
28
28
  match do |actual|
29
- actual == hash.to_bson
29
+ actual == hash.to_bson.to_s
30
30
  end
31
31
  end
32
32
 
@@ -1,28 +1,28 @@
1
1
  shared_examples 'message with a header' do
2
2
  describe 'header' do
3
3
  describe 'length' do
4
- let(:field) { bytes[0..3] }
4
+ let(:field) { bytes.to_s[0..3] }
5
5
  it 'serializes the length' do
6
- expect(field).to be_int32(bytes.size)
6
+ expect(field).to be_int32(bytes.length)
7
7
  end
8
8
  end
9
9
 
10
10
  describe 'request id' do
11
- let(:field) { bytes[4..7] }
11
+ let(:field) { bytes.to_s[4..7] }
12
12
  it 'serializes the request id' do
13
13
  expect(field).to be_int32(message.request_id)
14
14
  end
15
15
  end
16
16
 
17
17
  describe 'response to' do
18
- let(:field) { bytes[8..11] }
18
+ let(:field) { bytes.to_s[8..11] }
19
19
  it 'serializes the response to' do
20
20
  expect(field).to be_int32(0)
21
21
  end
22
22
  end
23
23
 
24
24
  describe 'op code' do
25
- let(:field) { bytes[12..15] }
25
+ let(:field) { bytes.to_s[12..15] }
26
26
  it 'serializes the op code' do
27
27
  expect(field).to be_int32(opcode)
28
28
  end
@@ -4,7 +4,7 @@ if (ENV['CI'] == 'travis')
4
4
  client = Mongo::Client.new(['127.0.0.1:27017'])
5
5
  while starting
6
6
  begin
7
- client.command(Mongo::Server::Monitor::STATUS)
7
+ client.command(Mongo::Server::Monitor::Connection::ISMASTER)
8
8
  break
9
9
  rescue Mongo::Error::OperationFailure => e
10
10
  sleep(2)
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: 2.1.2
4
+ version: 2.2.0.rc0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tyler Brock
@@ -32,7 +32,7 @@ cert_chain:
32
32
  o2UXDbWtz5PqoFd8EgNJAn3+BG1pwC9S9pVFG3WPucfAx/bE8iq/vvchHei5Y/Vo
33
33
  aAz5f/hY4zFeYWvGDBHYEXE1rTN2hhMSyJscPcFbmz0=
34
34
  -----END CERTIFICATE-----
35
- date: 2015-10-16 00:00:00.000000000 Z
35
+ date: 2015-11-16 00:00:00.000000000 Z
36
36
  dependencies:
37
37
  - !ruby/object:Gem::Dependency
38
38
  name: bson
@@ -40,14 +40,14 @@ dependencies:
40
40
  requirements:
41
41
  - - "~>"
42
42
  - !ruby/object:Gem::Version
43
- version: '3.0'
43
+ version: 4.0.0.rc0
44
44
  type: :runtime
45
45
  prerelease: false
46
46
  version_requirements: !ruby/object:Gem::Requirement
47
47
  requirements:
48
48
  - - "~>"
49
49
  - !ruby/object:Gem::Version
50
- version: '3.0'
50
+ version: 4.0.0.rc0
51
51
  description: A Ruby driver for MongoDB
52
52
  email: mongodb-dev@googlegroups.com
53
53
  executables: []
@@ -59,6 +59,7 @@ files:
59
59
  - README.md
60
60
  - Rakefile
61
61
  - bin/mongo_console
62
+ - lib/csasl/csasl.bundle
62
63
  - lib/mongo.rb
63
64
  - lib/mongo/address.rb
64
65
  - lib/mongo/address/ipv4.rb
@@ -94,6 +95,13 @@ files:
94
95
  - lib/mongo/collection.rb
95
96
  - lib/mongo/collection/view.rb
96
97
  - lib/mongo/collection/view/aggregation.rb
98
+ - lib/mongo/collection/view/builder.rb
99
+ - lib/mongo/collection/view/builder/aggregation.rb
100
+ - lib/mongo/collection/view/builder/find_command.rb
101
+ - lib/mongo/collection/view/builder/flags.rb
102
+ - lib/mongo/collection/view/builder/map_reduce.rb
103
+ - lib/mongo/collection/view/builder/modifiers.rb
104
+ - lib/mongo/collection/view/builder/op_query.rb
97
105
  - lib/mongo/collection/view/explainable.rb
98
106
  - lib/mongo/collection/view/immutable.rb
99
107
  - lib/mongo/collection/view/iterable.rb
@@ -101,6 +109,11 @@ files:
101
109
  - lib/mongo/collection/view/readable.rb
102
110
  - lib/mongo/collection/view/writable.rb
103
111
  - lib/mongo/cursor.rb
112
+ - lib/mongo/cursor/builder.rb
113
+ - lib/mongo/cursor/builder/get_more_command.rb
114
+ - lib/mongo/cursor/builder/kill_cursors_command.rb
115
+ - lib/mongo/cursor/builder/op_get_more.rb
116
+ - lib/mongo/cursor/builder/op_kill_cursors.rb
104
117
  - lib/mongo/database.rb
105
118
  - lib/mongo/database/view.rb
106
119
  - lib/mongo/dbref.rb
@@ -122,6 +135,7 @@ files:
122
135
  - lib/mongo/error/invalid_signature.rb
123
136
  - lib/mongo/error/invalid_update_document.rb
124
137
  - lib/mongo/error/invalid_uri.rb
138
+ - lib/mongo/error/invalid_write_concern.rb
125
139
  - lib/mongo/error/max_bson_size.rb
126
140
  - lib/mongo/error/max_message_size.rb
127
141
  - lib/mongo/error/missing_file_chunk.rb
@@ -169,6 +183,10 @@ files:
169
183
  - lib/mongo/operation/commands/collections_info.rb
170
184
  - lib/mongo/operation/commands/collections_info/result.rb
171
185
  - lib/mongo/operation/commands/command.rb
186
+ - lib/mongo/operation/commands/find.rb
187
+ - lib/mongo/operation/commands/find/result.rb
188
+ - lib/mongo/operation/commands/get_more.rb
189
+ - lib/mongo/operation/commands/get_more/result.rb
172
190
  - lib/mongo/operation/commands/indexes.rb
173
191
  - lib/mongo/operation/commands/list_collections.rb
174
192
  - lib/mongo/operation/commands/list_collections/result.rb
@@ -184,6 +202,7 @@ files:
184
202
  - lib/mongo/operation/executable.rb
185
203
  - lib/mongo/operation/kill_cursors.rb
186
204
  - lib/mongo/operation/limited.rb
205
+ - lib/mongo/operation/object_id_generator.rb
187
206
  - lib/mongo/operation/read.rb
188
207
  - lib/mongo/operation/read/get_more.rb
189
208
  - lib/mongo/operation/read/query.rb
@@ -297,6 +316,10 @@ files:
297
316
  - spec/mongo/cluster/topology_spec.rb
298
317
  - spec/mongo/cluster_spec.rb
299
318
  - spec/mongo/collection/view/aggregation_spec.rb
319
+ - spec/mongo/collection/view/builder/find_command_spec.rb
320
+ - spec/mongo/collection/view/builder/flags_spec.rb
321
+ - spec/mongo/collection/view/builder/modifiers_spec.rb
322
+ - spec/mongo/collection/view/builder/op_query_spec.rb
300
323
  - spec/mongo/collection/view/explainable_spec.rb
301
324
  - spec/mongo/collection/view/immutable_spec.rb
302
325
  - spec/mongo/collection/view/map_reduce_spec.rb
@@ -307,6 +330,8 @@ files:
307
330
  - spec/mongo/command_monitoring_spec.rb
308
331
  - spec/mongo/connection_string_spec.rb
309
332
  - spec/mongo/crud_spec.rb
333
+ - spec/mongo/cursor/builder/get_more_command_spec.rb
334
+ - spec/mongo/cursor/builder/op_get_more_spec.rb
310
335
  - spec/mongo/cursor_spec.rb
311
336
  - spec/mongo/database_spec.rb
312
337
  - spec/mongo/dbref_spec.rb
@@ -328,7 +353,7 @@ files:
328
353
  - spec/mongo/monitoring/event/command_succeeded_spec.rb
329
354
  - spec/mongo/monitoring/event/secure_spec.rb
330
355
  - spec/mongo/monitoring_spec.rb
331
- - spec/mongo/operation/aggregate/result_spec.rb
356
+ - spec/mongo/operation/commands/aggregate/result_spec.rb
332
357
  - spec/mongo/operation/commands/aggregate_spec.rb
333
358
  - spec/mongo/operation/commands/collections_info_spec.rb
334
359
  - spec/mongo/operation/commands/command_spec.rb
@@ -388,6 +413,7 @@ files:
388
413
  - spec/mongo/uri_spec.rb
389
414
  - spec/mongo/write_concern/acknowledged_spec.rb
390
415
  - spec/mongo/write_concern/unacknowledged_spec.rb
416
+ - spec/mongo/write_concern_spec.rb
391
417
  - spec/spec_helper.rb
392
418
  - spec/support/authorization.rb
393
419
  - spec/support/certificates/ca.pem
@@ -537,12 +563,12 @@ required_ruby_version: !ruby/object:Gem::Requirement
537
563
  version: '0'
538
564
  required_rubygems_version: !ruby/object:Gem::Requirement
539
565
  requirements:
540
- - - ">="
566
+ - - ">"
541
567
  - !ruby/object:Gem::Version
542
- version: '0'
568
+ version: 1.3.1
543
569
  requirements: []
544
- rubyforge_project: mongo
545
- rubygems_version: 2.4.8
570
+ rubyforge_project:
571
+ rubygems_version: 2.4.6
546
572
  signing_key:
547
573
  specification_version: 4
548
574
  summary: Ruby driver for MongoDB
@@ -571,6 +597,10 @@ test_files:
571
597
  - spec/mongo/cluster/topology_spec.rb
572
598
  - spec/mongo/cluster_spec.rb
573
599
  - spec/mongo/collection/view/aggregation_spec.rb
600
+ - spec/mongo/collection/view/builder/find_command_spec.rb
601
+ - spec/mongo/collection/view/builder/flags_spec.rb
602
+ - spec/mongo/collection/view/builder/modifiers_spec.rb
603
+ - spec/mongo/collection/view/builder/op_query_spec.rb
574
604
  - spec/mongo/collection/view/explainable_spec.rb
575
605
  - spec/mongo/collection/view/immutable_spec.rb
576
606
  - spec/mongo/collection/view/map_reduce_spec.rb
@@ -581,6 +611,8 @@ test_files:
581
611
  - spec/mongo/command_monitoring_spec.rb
582
612
  - spec/mongo/connection_string_spec.rb
583
613
  - spec/mongo/crud_spec.rb
614
+ - spec/mongo/cursor/builder/get_more_command_spec.rb
615
+ - spec/mongo/cursor/builder/op_get_more_spec.rb
584
616
  - spec/mongo/cursor_spec.rb
585
617
  - spec/mongo/database_spec.rb
586
618
  - spec/mongo/dbref_spec.rb
@@ -602,7 +634,7 @@ test_files:
602
634
  - spec/mongo/monitoring/event/command_succeeded_spec.rb
603
635
  - spec/mongo/monitoring/event/secure_spec.rb
604
636
  - spec/mongo/monitoring_spec.rb
605
- - spec/mongo/operation/aggregate/result_spec.rb
637
+ - spec/mongo/operation/commands/aggregate/result_spec.rb
606
638
  - spec/mongo/operation/commands/aggregate_spec.rb
607
639
  - spec/mongo/operation/commands/collections_info_spec.rb
608
640
  - spec/mongo/operation/commands/command_spec.rb
@@ -662,6 +694,7 @@ test_files:
662
694
  - spec/mongo/uri_spec.rb
663
695
  - spec/mongo/write_concern/acknowledged_spec.rb
664
696
  - spec/mongo/write_concern/unacknowledged_spec.rb
697
+ - spec/mongo/write_concern_spec.rb
665
698
  - spec/spec_helper.rb
666
699
  - spec/support/authorization.rb
667
700
  - spec/support/certificates/ca.pem