[DOCS-2563] replicaSet parameter for connection string is case sensitive Created: 21/Jan/14 Updated: 29/Jul/14 Resolved: 29/Jul/14 |
|
| Status: | Closed |
| Project: | Documentation |
| Component/s: | manual |
| Affects Version/s: | None |
| Fix Version/s: | v1.3.9 |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Alexander Komyagin | Assignee: | Tim Slavin |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Environment: |
http://docs.mongodb.org/manual/reference/connection-string/#uri.replicaSet |
||
| Issue Links: |
|
||||
| Participants: | |||||
| Days since reply: | 9 years, 29 weeks, 1 day ago | ||||
| Description |
|
In C# replicaSet parameter is case sensitive, while our docs say it should not be: http://docs.mongodb.org/manual/reference/connection-string/#uri.replicaSet Please check with other drivers devs how they expected to behave and update docs to reflect this. |
| Comments |
| Comment by Githook User [ 29/Jul/14 ] |
|
Author: {u'username': u'TimSlavinMongoDB', u'name': u'Tim Slavin (MongoDB)', u'email': u'tim.slavin@10gen.com'}Message: Signed-off-by: kay <kay.kim@10gen.com> |
| Comment by Jeffrey Yemin [ 12/Mar/14 ] |
|
samk Validated. The value of the replicaSet query parameter is case sensitive. |
| Comment by Craig Wilson [ 22/Jan/14 ] |
|
Yeah, sorry, my mistake on what Bernie was saying... I concur, the keys should be case-insensitive, but the values, or at least this value, should be case-sensitive. |
| Comment by Jeffrey Yemin [ 22/Jan/14 ] |
|
IMO the right thing is to be case-sensitive on the value of the replica set option in the connection string. The option names are all case-insensitive. |
| Comment by Bernie Hackett [ 22/Jan/14 ] |
No. The name has to be what is returned from 'ismaster' exactly. We don't modify the values in any way, only lower casing the keys. It doesn't make any sense to me to modify the values that the user passes. I guess I misread this ticket, I thought it was about the keys (e.g. replicaSet, maxPoolSize, connectTimeoutMS, etc.) |
| Comment by Craig Wilson [ 22/Jan/14 ] |
|
behackett, I think the "right" thing is what we are debating here. If a someone was running 2 different replica sets with the same names, only cased differently, then pymongo's implementation might not be the "right" thing. (I hope no one ever does that). So, the real question here is, what is the "right" thing? |
| Comment by Jeffrey Yemin [ 22/Jan/14 ] |
|
This is about passing replicaSet=mYReplicASETnAME |
| Comment by Bernie Hackett [ 21/Jan/14 ] |
|
PyMongo lower cases the keys before doing validation, so they are totally case insensitive. You could pass rEpLiCaSeT and PyMongo would do the right thing. Looks like Ruby does the same. |
| Comment by Jeffrey Yemin [ 21/Jan/14 ] |
|
behackett, what does pymongo and ruby do here? |
| Comment by Jeffrey Yemin [ 21/Jan/14 ] |
|
The documentation says: "The options are not case-sensitive", but I don't believe that we guarantee that the values are all case-insensitive, just the keys. The Java driver lower-cases some of the values (true, false, read preference names), but not all. The currently released Java driver does not support the replicaSet option, but in the 3.0 driver code base, the value of the replicaSet option is case-sensitive |