Which nodes should participate in election?

(Igor Igor) #1

I am not clear about, which type of nodes should participate in election.

As I understand from documentation by default, master eligible and data nodes take part in election, when client node don't.

But I can configure this by params:

So the question, is when I need to configure this, and what does it influence on?

(Mark Walkom) #2

Why do you want to change this, just let ES handle it!

(Igor Igor) #3

I'm not going to change it, but I'd like to understand how and why it works?

(Mark Walkom) #4

If you have node/transport clients, for example in your code, you probably don't want them to take part in elections.

So really, you don't want to set that.

(Igor Igor) #6

I do not understand how can I have nodes in code. As I understand node is an instance of elastic, am I right?

I can't find docs about election process, I understand minimum_master_nodes and split brain, but I can't understand by which principal nodes elect each other.
May be you know, where I can find this information?

(Ivan Brusic) #7

Try reading the zen discovery code:

(Mark Walkom) #8

You raise a good point, I've asked that we document this - https://github.com/elastic/elasticsearch/issues/16463

(Igor Igor) #9

Guys, thanks for your help.
Source code is exactly what I need.

(system) #10