doJoinCluster vs addNode

What is the difference between doJoinCluster and addNode REST APIs?

From the documentation:

addNode

Nodes are added to clusters with the POST /controller/addNode HTTP method and URI.

doJoinCluster

Nodes can be added to clusters with the POST /node/controller/doJoinCluster HTTP method and URI.

1 Like

‘addNode’ is a cluster (or a node in that cluster) reaching out to pull in a node, and ‘doJoinCluster’ is asking a node to join an existing cluster.

Thank you.

Lets say I have a 2 node cluster. I want to add a third node to this cluster

  1. do I use doJoinCluster or addNode cluster?
  2. Say, I want to do graceful failover in maintenance mode - do I invoke addJoin or doJoinCluster to make the recently restarted nodes to join the cluster?
1 Like

@ingenthr Please answer @abhijat.upadhyay’s question about when to use one over the other. Thanks.

FYI When I used the Web UI to initialize and configure a new node and choose the “Join Existing Cluster” option. It is sending a request to the /node/controller/doJoinCluster endpoint.