[SERVER-2260] ismaster is slightly inconsistent with mongos and mongod Created: 20/Dec/10  Updated: 12/Jul/16  Resolved: 21/Dec/10

Status: Closed
Project: Core Server
Component/s: Sharding
Affects Version/s: 1.7.4
Fix Version/s: 1.7.4

Type: Bug Priority: Major - P3
Reporter: Gustavo Niemeyer 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   

In a mongod:

> db.runCommand("ismaster")

{ "ismaster" : true, "maxBsonObjectSize" : 16777216, "ok" : 1 }

In a mongos:

> db.runCommand("ismaster")
{
"ismaster" : 1,
"msg" : "isdbgrid",
"maxBsonObjectSize" : 16777216,
"ok" : 1
}

Note the value of "ismaster": 1 vs. true.

Should be trivial to fix, and not a big deal, but it may easily lead to broken code which inadvertently does a normal "== true" or similar.



 Comments   
Comment by Gustavo Niemeyer [ 21/Dec/10 ]

That was fast. Thank you.

Comment by auto [ 21/Dec/10 ]

Author:

{u'login': u'erh', u'name': u'Eliot Horowitz', u'email': u'eliot@10gen.com'}

Message: make isMaster in mongos match mongod SERVER-2260
https://github.com/mongodb/mongo/commit/90b4b4abc8659ee130ffb5646cb2c191ae334ef2

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