[SERVER-8263] getLastError returns hosts replicated to in incorrect format Created: 22/Jan/13  Updated: 11/Jul/16  Resolved: 08/Feb/13

Status: Closed
Project: Core Server
Component/s: Replication
Affects Version/s: 2.3.2
Fix Version/s: 2.4.0-rc1

Type: Bug Priority: Major - P3
Reporter: Asya Kamsky Assignee: Kristina Chodorow (Inactive)
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
is related to SERVER-8278 getLastError returns replicatedTo whi... Closed
Operating System: ALL
Participants:

 Description   

After creating a replica set with config where hosts are specified by name:port getLastError replicatedTo field lists only ip addresses and no ports.

rs.conf()
...
members: [
...
{
"_id":1,
"host": "asyasmacbook.local:31001",
etc.

rs.status()
...
members: [
...
"name": "asyasmacbook.local:31001",
etc.

getlasterror returns:
...
"replicatedTo" : [
"127.0.0.1",
"127.0.0.1"
], etc.

Since people may be running multiple servers on the same machine port name seems absolutely necessary. I'm not not sure why hostname isn't returned in the same form it's displayed in config and status but it seems potentially confusing.



 Comments   
Comment by auto [ 01/Feb/13 ]

Author:

{u'date': u'2013-02-01T19:04:51Z', u'email': u'kristina@10gen.com', u'name': u'Kristina'}

Message: SERVER-8263 Use member configs in local.slaves
Branch: master
https://github.com/mongodb/mongo/commit/9b063257b2b061e2a4f013649d16e28e62712d78

Comment by auto [ 28/Jan/13 ]

Author:

{u'date': u'2013-01-28T17:11:59Z', u'email': u'kristina@10gen.com', u'name': u'Kristina'}

Message: Revert "SERVER-8263 Use member configs in local.slaves"

This reverts commit 9b3a4ce065c1aea42473d8b6489f642488ac2b4e.
Branch: master
https://github.com/mongodb/mongo/commit/e4cae266e46566f38659211be16b4948e8ffcec4

Comment by auto [ 28/Jan/13 ]

Author:

{u'date': u'2013-01-22T21:42:02Z', u'email': u'kristina@10gen.com', u'name': u'Kristina'}

Message: SERVER-8263 Use member configs in local.slaves
Branch: master
https://github.com/mongodb/mongo/commit/9b3a4ce065c1aea42473d8b6489f642488ac2b4e

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