How does elasticsearch deal with node failure

I have many question, but I cannot find answer in the guide.
if a node failure, how elasticsearch do it balance and deal with the data?

the shard is chosen by hashing the routing value, but how it is
Correspondence with the node?

what is the rule of shard?

and more...

anyone could tell me the answer or have document about that?

thanks

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.