Skip to content
Merged
Show file tree
Hide file tree
Changes from 15 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
41 changes: 41 additions & 0 deletions docs/reference/api-conventions.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -264,6 +264,47 @@ GET _cluster/state/metadata?filter_path=metadata.indices.*.system
WARNING: When overwriting current cluster state, system indices should be restored
as part of their {ref}/snapshot-restore.html#feature-state[feature state].

[discrete]
[[node-spec-convention]]
==== Node specification

Some cluster-level APIs may operate on a subset of the nodes which can be specified with node filters. For example, task management, node stats, and node info APIs can all report results from a filtered set of nodes rather than from all nodes. <<cluster-nodes,Learn more>>.

[discrete]
[[component-selectors]]
==== Component selectors

A data stream component is a logical grouping of indices that help organize data inside a data stream. All data streams contain a `data` component by default. The `data` component comprises the data stream's backing indices. When searching, managing, or indexing into a data stream, the data component is what you are interacting with by default.

Some data stream features are exposed as additional components alongside its `data` component. These other components are comprised of separate sets of backing indices. These additional components store supplemental data independent of the data stream's regular backing indices. An example of another component is the `failures` component exposed by the data stream <<failure-store, failure store>> feature, which captures documents that fail to be ingested in a separate set of backing indices on the data stream.

Some APIs that accept a `<data-stream>`, `<index>`, or `<target>` request path parameter also support selector syntax which defines which component on a data stream the API should operate on. To use a selector, it is appended to the index or data stream name. Selectors can be combined with other index pattern syntax like <<api-date-math-index-names,date math>> and wildcards.

There are two selector suffixes supported by Elasticsearch APIs:

`::data`::
Refers to a data stream's backing indices containing regular data. Data streams always contain a data component.
`::failures`::
This component refers to the internal indices used for a data stream's <<failure-store, failure store>>.

As an example, <<search>>, <<search-field-caps,field capabilities>>, and <<indices-stats,index stats>> APIs can all report results from a different component rather than from the default data.

[source,console]
----
# Search a data stream normally
GET my-data-stream/_search

# Search a data stream's failure data if present
GET my-data-stream::failures/_search

# Syntax can be combined with other index pattern syntax (wildcards, multi-target, date math, cross cluster search, etc)
GET logs-*::failures/_search
GET logs-*::data,logs-*::failures/_count
GET remote-cluster:logs-*-*::failures/_search
GET *::data,*::failures,-logs-rdbms-*::failures/_stats
GET <logs-{now/d}>::failures/_search
----

[discrete]
[[api-conventions-parameters]]
=== Parameters
Expand Down
1 change: 1 addition & 0 deletions docs/reference/data-streams/data-streams.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -159,3 +159,4 @@ include::change-mappings-and-settings.asciidoc[]
include::tsds.asciidoc[]
include::logs.asciidoc[]
include::lifecycle/index.asciidoc[]
include::failure-store.asciidoc[]
Loading