[SERVER-13334] Can't count() from maxTimeMS helper Created: 24/Mar/14  Updated: 11/Jul/16  Resolved: 25/Mar/14

Status: Closed
Project: Core Server
Component/s: Shell
Affects Version/s: 2.6.0-rc2
Fix Version/s: 2.6.0-rc3

Type: Bug Priority: Major - P3
Reporter: Andre de Frere Assignee: Unassigned
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Operating System: ALL
Participants:

 Description   

trying to find().count() with maxTimeMS fails from the shell:

db.test.find( { x: {$gt : 0 } }).maxTimeMS(10).count()
2014-03-25T09:19:20.702+1100 count failed: {
	"ok" : 0,
	"errmsg" : "no such command option $maxTimeMS; use maxTimeMS instead"
} at src/mongo/shell/query.js:191

The same command when run will work as expected:

> db.test.runCommand( "count", {query : {x:{$gt:0}}, maxTimeMS : 10 } )
{ "code" : 50, "ok" : 0, "errmsg" : "50 operation exceeded time limit" }



 Comments   
Comment by Githook User [ 25/Mar/14 ]

Author:

{u'name': u'Dan Pasette', u'email': u'dan@10mongodb.com'}

Message: SERVER-13334 fix maxTimeMS shell helper with count
(cherry picked from commit 5138b611cbb384f87c0437d51f1fe3a72a4bf7b4)
Branch: v2.6
https://github.com/mongodb/mongo/commit/112c32c0fd03b2479f125dcc0f974cf1a682b72c

Comment by Githook User [ 25/Mar/14 ]

Author:

{u'name': u'Dan Pasette', u'email': u'dan@10mongodb.com'}

Message: SERVER-13334 fix maxTimeMS shell helper with count
Branch: master
https://github.com/mongodb/mongo/commit/5138b611cbb384f87c0437d51f1fe3a72a4bf7b4

Generated at Thu Feb 08 03:31:23 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.