Skip to content

Commit 4c69f3d

Browse files
authored
[DOCS] Add Kibana screenshots to data stream docs (#60118)
1 parent d970e64 commit 4c69f3d

File tree

5 files changed

+77
-41
lines changed

5 files changed

+77
-41
lines changed

docs/reference/data-streams/data-streams.asciidoc

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -56,20 +56,19 @@ image::images/data-streams/data-streams-diagram.svg[align="center"]
5656

5757
To create backing indices, each data stream requires a matching
5858
<<indices-templates,index template>>. This template acts as a blueprint for the
59-
stream's backing indices. It contains:
59+
stream's backing indices. It specifies:
6060

61-
* The mappings and settings applied to each backing index when it's created.
61+
* One or more wildcard (`*`) patterns that match the name of the stream.
6262

63-
* A name or wildcard (`*`) pattern that matches the data stream's name.
63+
* The mappings and settings for the stream's backing indices.
6464

65-
* A `data_stream` object with an empty body (`{ }`). This object indicates the
66-
template is used for data streams.
65+
* That the template is used exclusively for data streams.
6766

68-
A `@timestamp` field must be included in every document indexed to the data
69-
stream. This field can be mapped as a <<date,`date`>> or
70-
<<date_nanos,`date_nanos`>> field data type in the stream's matching index
71-
template. If no mapping is specified in the template, the `date` field data type
72-
with default options is used.
67+
Every document indexed to a data stream must have a `@timestamp` field. This
68+
field can be mapped as a <<date,`date`>> or <<date_nanos,`date_nanos`>> field
69+
data type by the stream's index template. If the template does not specify a
70+
mapping, the `@timestamp` field is mapped as a `date` field with default
71+
options.
7372

7473
The same index template can be used to create multiple data streams.
7574

docs/reference/data-streams/set-up-a-data-stream.asciidoc

Lines changed: 54 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -52,10 +52,18 @@ triggers for such actions.
5252
TIP: While optional, we recommend using {ilm-init} to manage the backing indices
5353
associated with a data stream.
5454

55-
The following <<ilm-put-lifecycle,create lifecycle policy API>> request
56-
configures the `logs_policy` lifecycle policy.
55+
You can create the policy through the Kibana UI. In Kibana, open the menu and go
56+
to *Stack Management > Index Lifecycle Policies*. Click *Index Lifecycle
57+
Policies*.
5758

58-
The `logs_policy` policy uses the <<ilm-rollover,`rollover` action>> to create a
59+
[role="screenshot"]
60+
image::images/ilm/create-policy.png[Index Lifecycle Policies page]
61+
62+
You can also create a policy using the <<ilm-put-lifecycle,create lifecycle
63+
policy API>>.
64+
65+
The following request configures the `logs_policy` lifecycle policy. The
66+
`logs_policy` policy uses the <<ilm-rollover,`rollover` action>> to create a
5967
new <<data-stream-write-index,write index>> for the data stream when the current
6068
one reaches 25GB in size. The policy also deletes backing indices 30 days after
6169
their rollover.
@@ -92,19 +100,18 @@ PUT /_ilm/policy/logs_policy
92100
A data stream uses an index template to configure its backing indices. A
93101
template for a data stream must specify:
94102

95-
* An index pattern that matches the name of the stream.
96-
97-
* An empty `data_stream` object that indicates the template is used for data
98-
streams.
103+
* One or more wildcard (`*`) patterns that match the name of the stream.
99104

100105
* The mappings and settings for the stream's backing indices.
101106

107+
* That the template is used exclusively for data streams.
108+
102109
Every document indexed to a data stream must have a `@timestamp` field. This
103110
field can be mapped as a <<date,`date`>> or <<date_nanos,`date_nanos`>> field
104111
data type by the stream's index template. This mapping can include other
105112
<<mapping-params,mapping parameters>>, such as <<mapping-date-format,`format`>>.
106-
If the template does not specify a mapping is specified in the template, the
107-
`@timestamp` field is mapped as a `date` field with default options.
113+
If the template does not specify a mapping, the `@timestamp` field is mapped as
114+
a `date` field with default options.
108115

109116
We recommend using {ilm-init} to manage a data stream's backing indices. Specify
110117
the name of the lifecycle policy with the `index.lifecycle.name` setting.
@@ -114,11 +121,24 @@ in this template before creating a data stream. Later changes to the mappings or
114121
settings of a stream's backing indices may require reindexing. See
115122
<<data-streams-change-mappings-and-settings>>.
116123

117-
The following <<indices-templates,put index template API>> request
118-
configures the `logs_data_stream` template.
124+
You can create an index template through the Kibana UI:
125+
126+
. From Kibana, open the menu and go to *Stack Management > Index Management*.
127+
. In the *Index Templates* tab, click *Create template*.
128+
. In the Create template wizard, use the *Data stream* toggle to indicate the
129+
template is used exclusively for data streams.
130+
131+
[role="screenshot"]
132+
image::images/data-streams/create-index-template.png[Create template page]
119133

120-
Because no field mapping is specified, the `@timestamp` field uses the `date`
121-
field data type by default.
134+
You can also create a template using the <<indices-put-template,put index
135+
template API>>. The template must include a `data_stream` object with an empty
136+
body (`{ }`). This object indicates the template is used exclusively for data
137+
streams.
138+
139+
The following request configures the `logs_data_stream` index template. Because
140+
no field mapping is specified, the `@timestamp` field uses the `date` field data
141+
type by default.
122142

123143
[source,console]
124144
----
@@ -176,7 +196,7 @@ You can create a data stream using one of two methods:
176196
[[index-documents-to-create-a-data-stream]]
177197
==== Index documents to create a data stream
178198

179-
You can automatically generate a data stream using an indexing request. Submit
199+
You can automatically create a data stream using an indexing request. Submit
180200
an <<add-documents-to-a-data-stream,indexing request>> to a target
181201
matching the name or wildcard pattern defined in the template's `index_patterns`
182202
property.
@@ -250,10 +270,16 @@ PUT /_data_stream/logs_alt
250270
[[get-info-about-a-data-stream]]
251271
=== Get information about a data stream
252272

253-
You can use the <<indices-get-data-stream,get data stream API>> to get
254-
information about one or more data streams, including:
273+
To view information about a data stream in Kibana, open the menu and go to
274+
*Stack Management > Index Management*. In the *Data Streams* tab, click a data
275+
stream's name to view information about the stream.
276+
277+
[role="screenshot"]
278+
image::images/data-streams/data-streams-list.png[Data Streams tab]
279+
280+
You can also use the <<indices-get-data-stream,get data stream API>> to retrieve
281+
the following information about one or more data streams:
255282

256-
* The timestamp field
257283
* The current backing indices, which is returned as an array. The last item in
258284
the array contains information about the stream's current write index.
259285
* The current generation
@@ -262,8 +288,6 @@ information about one or more data streams, including:
262288
* The current {ilm-init} lifecycle policy in the stream's matching index
263289
template
264290

265-
This is also handy way to verify that a recently created data stream exists.
266-
267291
The following get data stream API request retrieves information about the
268292
`logs` data stream.
269293

@@ -330,11 +354,18 @@ data. See <<data-stream-privileges>>.
330354
[[delete-a-data-stream]]
331355
=== Delete a data stream
332356

333-
You can use the <<indices-delete-data-stream,delete data stream API>> to delete
334-
a data stream and its backing indices.
357+
You can use the Kibana UI to delete a data stream and its backing indices. In
358+
Kibana, open the menu and go to *Stack Management > Index Management*. In the
359+
*Data Streams* tab, click the trash can icon to delete a stream and its backing
360+
indices.
361+
362+
[role="screenshot"]
363+
image::images/data-streams/data-streams-list.png[Data Streams tab]
335364

336-
The following delete data stream API request deletes the `logs` data stream. This
337-
request also deletes the stream's backing indices and any data they contain.
365+
You can also use the the <<indices-delete-data-stream,delete data stream API>>
366+
to delete a data stream. The following delete data stream API request deletes
367+
the `logs` data stream. This request also deletes the stream's backing indices
368+
and any data they contain.
338369

339370
[source,console]
340371
----

docs/reference/ilm/ilm-tutorial.asciidoc

Lines changed: 14 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -55,9 +55,10 @@ reaches either a `max_size` of 50 gigabytes or a `max_age` of 30 days.
5555
* A `delete` phase that sets `min_age` to remove the index 90 days after rollover.
5656
Note that this value is relative to the rollover time, not the index creation time.
5757

58-
You can create the policy through {kib} Management or with the
58+
You can create the policy through {kib} or with the
5959
<<ilm-put-lifecycle, put policy>> API.
60-
To create the policy from {kib}, go to Management and click **Index Lifecycle Policies**.
60+
To create the policy from {kib}, open the menu and go to *Stack Management >
61+
Index Lifecycle Policies*. Click *Index Lifecycle Policies*.
6162

6263
[role="screenshot"]
6364
image:images/ilm/create-policy.png[]
@@ -109,9 +110,14 @@ To enable the {ilm-init} to manage the data stream, the template configures one
109110

110111
* `index.lifecycle.name` specifies the name of the lifecycle policy to apply to the data stream.
111112

112-
You can use the {kib} Create template wizard to add the template.
113-
This wizard invokes the put _index_template API to create the <<indices-templates,index template>>
114-
with the options you specify.
113+
You can use the {kib} Create template wizard to add the template. From Kibana,
114+
open the menu and go to *Stack Management > Index Management*. In the *Index
115+
Templates* tab, click *Create template*.
116+
117+
image::images/data-streams/create-index-template.png[Create template page]
118+
119+
This wizard invokes the <<indices-put-template,put index template API>> to create
120+
the index template with the options you specify.
115121

116122
.API example
117123
[%collapsible]
@@ -303,9 +309,9 @@ that match the index pattern.
303309
* `index.lifecycle.rollover_alias` specifies the index alias to be rolled over
304310
when the rollover action is triggered for an index.
305311

306-
You can use the {kib} Create template wizard to add the template.
307-
To access the wizard, go to Management, click **Index Management**,
308-
and select the **Index Templates** view.
312+
You can use the {kib} Create template wizard to add the template. To access the
313+
wizard, open the menu, go to *Stack Management > Index Management*, and click
314+
the *Index Templates* tab.
309315

310316
[role="screenshot"]
311317
image:images/ilm/create-template-wizard.png[]
Loading
Loading

0 commit comments

Comments
 (0)