Skip to content
This repository was archived by the owner on May 25, 2021. It is now read-only.

add_node: Don't fail if node name != "couchdb" or "node1"#11

Merged
asfgit merged 1 commit intoapache:masterfrom
adrienverge:COUCHDB-3119
Jun 3, 2017
Merged

add_node: Don't fail if node name != "couchdb" or "node1"#11
asfgit merged 1 commit intoapache:masterfrom
adrienverge:COUCHDB-3119

Conversation

@adrienverge
Copy link
Copy Markdown
Contributor

Adding nodes to a cluster fails if the node names (the name of name@hostname in vm.args) is different from "couchdb". The code currently infers this name from the port: "node1" if 15984, "node2" if 25984, "node3" if 35984, "couchdb" otherwise. No other possibility.

This is not suited for a production set-up, where multiple servers could have different names.

This patch fixes this problem by adding an optional "name" option to the "add_node" command:

  POST /_cluster_setup
  {
    "action": "add_node",
    "username": "root",
    "password": "******",
    "host": "production-server.com",
    "port": 5984,
    "name": "node5"
  }

This fixes: COUCHDB-3119

Adding nodes to a cluster fails if the node names (the `name` of
`name@hostname` in vm.args) is different from "couchdb".
The code currently infers this name from the port: "node1" if 15984,
"node2" if 25984, "node3" if 35984, "couchdb" otherwise. No other
possibility.

This is not suited for a production set-up, where multiple servers could
have different names.

This patch fixes this problem by adding an optional "name" option to the
"add_node" command:

  POST /_cluster_setup
  {
    "action": "add_node",
    "username": "root",
    "password": "******",
    "host": "production-server.com",
    "port": 5984,
    "name": "node5"
  }

This fixes: COUCHDB-3119
@kxepal
Copy link
Copy Markdown
Member

kxepal commented Sep 2, 2016

LGFM

@adrienverge
Copy link
Copy Markdown
Contributor Author

Hey, any news about this?

@adrienverge
Copy link
Copy Markdown
Contributor Author

Please?

@adrienverge
Copy link
Copy Markdown
Contributor Author

Hey @kxepal @danielRomero, do you think this can be merged? It would be great to set-up CouchDB clusters. Thanks!

@janl janl mentioned this pull request Jun 3, 2017
7 tasks
@asfgit asfgit merged commit d75693e into apache:master Jun 3, 2017
@janl
Copy link
Copy Markdown
Member

janl commented Jun 3, 2017

merged, thanks!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants