Skip to content

Update ESQL CCS docs for new allow_partial_results handling #126258

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Apr 28, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 5 additions & 8 deletions docs/reference/esql/esql-across-clusters.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ Once the security model is configured, you can add remote clusters.
include::{es-ref-dir}/search/search-your-data/search-across-clusters.asciidoc[tag=ccs-remote-cluster-setup]

<1> Since `skip_unavailable` was not set on `cluster_three`, it uses
the default of `false`. See the <<ccq-skip-unavailable-clusters>>
the default of `true`. See the <<ccq-skip-unavailable-clusters>>
section for details.

[discrete]
Expand Down Expand Up @@ -283,7 +283,7 @@ searches are currently in that state. The clusters can have one of the following
*successful* (searches on all shards were successful), *skipped* (the search
failed on a cluster marked with `skip_unavailable`=`true`), *failed* (the search
failed on a cluster marked with `skip_unavailable`=`false`) or **partial** (the search was
<<esql-async-query-stop-api, interrupted>> before finishing).
<<esql-async-query-stop-api, interrupted>> before finishing or has partially failed).
<3> The `_clusters/details` section shows metadata about the search on each cluster.
<4> If you included indices from the local cluster you sent the request to in your {ccs},
it is identified as "(local)".
Expand Down Expand Up @@ -525,12 +525,9 @@ FROM my-index-000001,cluster*:my-index-*,cluster_three:-my-index-000001
[[ccq-skip-unavailable-clusters]]
==== Optional remote clusters

{ccs-cap} for {esql} currently does not respect the `skip_unavailable`
setting. As a result, if a remote cluster specified in the request is
unavailable or failed, {ccs} for {esql} queries will fail regardless of the setting.

We are actively working to align the behavior of {ccs} for {esql} with other
{ccs} APIs.
{ccs-cap} for {esql} will set the remote cluster which is disconnected from the querying cluster to `skipped`
and continue the query with other clusters, unless the cluster's `skip_unavailable` setting is set to `false`,
in which case the query will fail.

[discrete]
[[ccq-during-upgrade]]
Expand Down
5 changes: 3 additions & 2 deletions docs/reference/esql/esql-query-api.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,9 @@ precedence.

`allow_partial_results`::
(Optional, boolean) If `true`, partial results will be returned if there are shard failures, but
the query can continue to execute on other clusters and shards. This defaults to the value of
the cluster setting `esql.query.allow_partial_results`.
the query can continue to execute on other clusters and shards. This defaults to `true`, unless
the cluster setting `esql.query.allow_partial_results` is set to `false`, in which case it also
defaults to `false`.

[discrete]
[role="child_attributes"]
Expand Down