mirror of
https://github.com/elastic/elasticsearch.git
synced 2025-06-28 17:34:17 -04:00
Interpret ?timeout=-1
as infinite ack timeout (#107675)
APIs which perform cluster state updates typically accept the `?master_timeout=` and `?timeout=` parameters to respectively set the pending task queue timeout and the acking timeout for the cluster state update. Both of these parameters accept the value `-1`, but `?master_timeout=-1` means to wait indefinitely whereas `?timeout=-1` means the same thing as `?timeout=0`, namely that acking times out immediately on commit. There are some situations where it makes sense to wait for as long as possible for nodes to ack a cluster state update. In practice this wait is bounded by other mechanisms (e.g. the lag detector will remove the node from the cluster after a couple of minutes of failing to apply cluster state updates) but these are not really the concern of clients. Therefore with this commit we change the meaning of `?timeout=-1` to mean that the acking timeout is infinite.
This commit is contained in:
parent
b0f58ab388
commit
fc287bde8b
6 changed files with 136 additions and 8 deletions
|
@ -1223,12 +1223,13 @@ the timeout expires, the request fails and returns an error. Defaults to `30s`.
|
|||
Can also be set to `-1` to indicate that the request should never timeout.
|
||||
end::master-timeout[]
|
||||
|
||||
tag::timeout[]
|
||||
`timeout`::
|
||||
(Optional, <<time-units, time units>>)
|
||||
Period to wait for a response. If no response is received before the timeout
|
||||
expires, the request fails and returns an error. Defaults to `30s`.
|
||||
end::timeout[]
|
||||
Period to wait for a response from all relevant nodes in the cluster after
|
||||
updating the cluster metadata. If no response is received before the timeout
|
||||
expires, the cluster metadata update still applies but the response will
|
||||
indicate that it was not completely acknowledged. Defaults to `30s`.
|
||||
Can also be set to `-1` to indicate that the request should never timeout.
|
||||
end::timeoutparms[]
|
||||
|
||||
tag::transform-id[]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue