My requirement is to get the value of 'discovery.zen.ping.unicast.hosts'. Is there any other API which gives me this information?
So if we can't read the default settings, then is it a good idea to write a plugin which will read elasticsearch.yml and create an index for storing all the values? And from the created index, I can read the settings?
Now I have 1 Master Node (1), 1 Master/Data Node (2) and 1 Data Node (3). All nodes 'discovery.zen.ping.unicast.hosts' setting points to (1). Now I would like to programmatically set another master node (2). Before I set I need to know what is the existing value and then I need to update the elasticsearch.yml file and restart all the nodes.
Fine, thanks for the clarification. I was under assumption that it's a Cluster Settings. As you said, I need to update elasticsearch.yml file, that I already thought of.
Again coming back to same question, how can I read the settings specified in elasticsearch.yml file through ES Java API? Is the only way to implement through a Custom Plugin, which will read the file when ES Nodes starts and put it in one Index?
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.