[SERVER-1387] cloneCollection should use exhaust mode Created: 09/Jul/10  Updated: 12/Jul/16  Resolved: 16/Jul/10

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: 1.5.5

Type: New Feature Priority: Major - P3
Reporter: Aaron Staple Assignee: Aaron Staple
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Participants:

 Comments   
Comment by auto [ 15/Jul/10 ]

Author:

{'login': 'astaple', 'name': 'Aaron', 'email': 'aaron@10gen.com'}

Message: SERVER-1387 add database clone test
http://github.com/mongodb/mongo/commit/ccb3b9d1c09424899893cf7deb5c97f02290c5ff

Comment by auto [ 15/Jul/10 ]

Author:

{'login': 'astaple', 'name': 'Aaron', 'email': 'aaron@10gen.com'}

Message: SERVER-1387 add exhaust mode to mongo bridge
http://github.com/mongodb/mongo/commit/7e40a057c7521e0da00a81eacd5b561adb09c6d7

Comment by Aaron Staple [ 12/Jul/10 ]

Also, the query() function that triggers QueryOption_Exhaust doesn't support additional flags like QueryOption_CursorTailable

Comment by Aaron Staple [ 12/Jul/10 ]

cloneCollection requires a tailable cursor, but it looks like exhaust mode will loop indefinitely on a tailable cursor because the cursor will never disappear:

while( 1 ) {
while( c->moreInCurrentBatch() )

{ BSONObj o = c->nextSafe(); f(o); n++; }

if( c->getCursorId() == 0 )
break;

c->exhaustReceiveMore();
}

Generated at Thu Feb 08 02:56:52 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.