2018-09-28 14:48:11 -04:00
|
|
|
--
|
|
|
|
:api: get-settings
|
|
|
|
:request: ClusterGetSettingsRequest
|
|
|
|
:response: ClusterGetSettingsResponse
|
|
|
|
--
|
|
|
|
|
|
|
|
[id="{upid}-{api}"]
|
2018-07-02 13:25:17 -04:00
|
|
|
=== Cluster Get Settings API
|
|
|
|
|
|
|
|
The Cluster Get Settings API allows to get the cluster wide settings.
|
|
|
|
|
2018-09-28 14:48:11 -04:00
|
|
|
[id="{upid}-{api}-request"]
|
2018-07-02 13:25:17 -04:00
|
|
|
==== Cluster Get Settings Request
|
|
|
|
|
2018-09-28 14:48:11 -04:00
|
|
|
A +{request}+:
|
2018-07-02 13:25:17 -04:00
|
|
|
|
|
|
|
["source","java",subs="attributes,callouts,macros"]
|
|
|
|
--------------------------------------------------
|
2018-09-28 14:48:11 -04:00
|
|
|
include-tagged::{doc-tests-file}[{api}-request]
|
2018-07-02 13:25:17 -04:00
|
|
|
--------------------------------------------------
|
|
|
|
|
|
|
|
==== Optional arguments
|
|
|
|
The following arguments can optionally be provided:
|
|
|
|
|
|
|
|
["source","java",subs="attributes,callouts,macros"]
|
|
|
|
--------------------------------------------------
|
2018-09-28 14:48:11 -04:00
|
|
|
include-tagged::{doc-tests-file}[{api}-request-includeDefaults]
|
2018-07-02 13:25:17 -04:00
|
|
|
--------------------------------------------------
|
|
|
|
<1> By default only those settings that were explicitly set are returned. Setting this to true also returns
|
|
|
|
the default settings.
|
|
|
|
|
|
|
|
["source","java",subs="attributes,callouts,macros"]
|
|
|
|
--------------------------------------------------
|
2018-09-28 14:48:11 -04:00
|
|
|
include-tagged::{doc-tests-file}[{api}-request-local]
|
2018-07-02 13:25:17 -04:00
|
|
|
--------------------------------------------------
|
|
|
|
<1> By default the request goes to the master of the cluster to get the latest results. If local is specified it gets
|
|
|
|
the results from whichever node the request goes to.
|
|
|
|
|
|
|
|
["source","java",subs="attributes,callouts,macros"]
|
|
|
|
--------------------------------------------------
|
2018-09-28 14:48:11 -04:00
|
|
|
include-tagged::{doc-tests-file}[{api}-request-masterTimeout]
|
2018-07-02 13:25:17 -04:00
|
|
|
--------------------------------------------------
|
|
|
|
<1> Timeout to connect to the master node as a `TimeValue`
|
|
|
|
<2> Timeout to connect to the master node as a `String`
|
|
|
|
|
2018-09-28 14:48:11 -04:00
|
|
|
include::../execution.asciidoc[]
|
2018-07-02 13:25:17 -04:00
|
|
|
|
2018-09-28 14:48:11 -04:00
|
|
|
[id="{upid}-{api}-response"]
|
2018-07-02 13:25:17 -04:00
|
|
|
==== Cluster Get Settings Response
|
|
|
|
|
2018-09-28 14:48:11 -04:00
|
|
|
The returned +{response}+ allows to retrieve information about the
|
2018-07-02 13:25:17 -04:00
|
|
|
executed operation as follows:
|
|
|
|
|
|
|
|
["source","java",subs="attributes,callouts,macros"]
|
|
|
|
--------------------------------------------------
|
2018-09-28 14:48:11 -04:00
|
|
|
include-tagged::{doc-tests-file}[{api}-response]
|
2018-07-02 13:25:17 -04:00
|
|
|
--------------------------------------------------
|
|
|
|
<1> Get the persistent settings.
|
|
|
|
<2> Get the transient settings.
|
|
|
|
<3> Get the default settings (returns empty settings if `includeDefaults` was not set to `true`).
|
|
|
|
<4> Get the value as a `String` for a particular setting. The order of searching is first in `persistentSettings` then in
|
|
|
|
`transientSettings` and finally, if not found in either, in `defaultSettings`.
|
2018-09-28 14:48:11 -04:00
|
|
|
|