Skip to content

Commit dd4ede5

Browse files
authored
[DOCS] Adds filter and calendar attributes (#50566)
1 parent 671fefa commit dd4ede5

16 files changed

+55
-79
lines changed

docs/reference/ml/anomaly-detection/apis/close-job.asciidoc

-2
Original file line numberDiff line numberDiff line change
@@ -88,8 +88,6 @@ include::{docdir}/ml/ml-shared.asciidoc[tag=allow-no-jobs]
8888
[[ml-close-job-example]]
8989
==== {api-examples-title}
9090

91-
The following example closes the `total-requests` job:
92-
9391
[source,console]
9492
--------------------------------------------------
9593
POST _ml/anomaly_detectors/low_request_rate/_close

docs/reference/ml/anomaly-detection/apis/delete-calendar-event.asciidoc

+2-1
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,8 @@ events and delete the calendar, see the
3131
==== {api-path-parms-title}
3232

3333
`<calendar_id>`::
34-
(Required, string) Identifier for the calendar.
34+
(Required, string)
35+
include::{docdir}/ml/ml-shared.asciidoc[tag=calendar-id]
3536

3637
`<event_id>`::
3738
(Required, string) Identifier for the scheduled event. You can obtain this

docs/reference/ml/anomaly-detection/apis/delete-calendar-job.asciidoc

+2-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,8 @@ Deletes {anomaly-jobs} from a calendar.
2424
==== {api-path-parms-title}
2525

2626
`<calendar_id>`::
27-
(Required, string) Identifier for the calendar.
27+
(Required, string)
28+
include::{docdir}/ml/ml-shared.asciidoc[tag=calendar-id]
2829

2930
`<job_id>`::
3031
(Required, string)

docs/reference/ml/anomaly-detection/apis/delete-calendar.asciidoc

+2-1
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,8 @@ calendar.
3030
==== {api-path-parms-title}
3131

3232
`<calendar_id>`::
33-
(Required, string) Identifier for the calendar.
33+
(Required, string)
34+
include::{docdir}/ml/ml-shared.asciidoc[tag=calendar-id]
3435

3536
[[ml-delete-calendar-example]]
3637
==== {api-examples-title}

docs/reference/ml/anomaly-detection/apis/delete-filter.asciidoc

+2-1
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,8 @@ update or delete the job before you can delete the filter.
3131
==== {api-path-parms-title}
3232

3333
`<filter_id>`::
34-
(Required, string) Identifier for the filter.
34+
(Required, string)
35+
include::{docdir}/ml/ml-shared.asciidoc[tag=filter-id]
3536

3637
[[ml-delete-filter-example]]
3738
==== {api-examples-title}

docs/reference/ml/anomaly-detection/apis/eventresource.asciidoc

-27
This file was deleted.

docs/reference/ml/anomaly-detection/apis/filterresource.asciidoc

-17
This file was deleted.

docs/reference/ml/anomaly-detection/apis/get-calendar-event.asciidoc

+10-9
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,8 @@ For more information, see
3535
==== {api-path-parms-title}
3636

3737
`<calendar_id>`::
38-
(Required, string) Identifier for the calendar.
38+
(Required, string)
39+
include::{docdir}/ml/ml-shared.asciidoc[tag=calendar-id]
3940

4041
[[ml-get-calendar-event-request-body]]
4142
==== {api-request-body-title}
@@ -60,22 +61,22 @@ The API returns an array of scheduled event resources, which have the
6061
following properties:
6162

6263
`calendar_id`::
63-
(string) An identifier for the calendar that contains the scheduled
64-
event.
64+
(string)
65+
include::{docdir}/ml/ml-shared.asciidoc[tag=calendar-id]
6566

6667
`description`::
67-
(string) A description of the scheduled event.
68+
(string) A description of the scheduled event.
6869

6970
`end_time`::
70-
(date) The timestamp for the end of the scheduled event
71-
in milliseconds since the epoch or ISO 8601 format.
71+
(date) The timestamp for the end of the scheduled event in milliseconds since
72+
the epoch or ISO 8601 format.
7273

7374
`event_id`::
74-
(string) An automatically-generated identifier for the scheduled event.
75+
(string) An automatically-generated identifier for the scheduled event.
7576

7677
`start_time`::
77-
(date) The timestamp for the beginning of the scheduled event
78-
in milliseconds since the epoch or ISO 8601 format.
78+
(date) The timestamp for the beginning of the scheduled event in milliseconds
79+
since the epoch or ISO 8601 format.
7980

8081
[[ml-get-calendar-event-example]]
8182
==== {api-examples-title}

docs/reference/ml/anomaly-detection/apis/get-calendar.asciidoc

+4-2
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,8 @@ For more information, see
3535
==== {api-path-parms-title}
3636

3737
`<calendar_id>`::
38-
(Required, string) Identifier for the calendar.
38+
(Required, string)
39+
include::{docdir}/ml/ml-shared.asciidoc[tag=calendar-id]
3940

4041
[[ml-get-calendar-request-body]]
4142
==== {api-request-body-title}
@@ -53,7 +54,8 @@ The API returns an array of calendar resources, which have the following
5354
properties:
5455

5556
`calendar_id`::
56-
(string) A numerical character string that uniquely identifies the calendar.
57+
(string)
58+
include::{docdir}/ml/ml-shared.asciidoc[tag=calendar-id]
5759

5860
`job_ids`::
5961
(array) An array of {anomaly-job} identifiers. For example:

docs/reference/ml/anomaly-detection/apis/get-filter.asciidoc

+4-2
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,8 @@ You can get a single filter or all filters. For more information, see
3232
==== {api-path-parms-title}
3333

3434
`<filter_id>`::
35-
(Optional, string) Identifier for the filter.
35+
(Optional, string)
36+
include::{docdir}/ml/ml-shared.asciidoc[tag=filter-id]
3637

3738
[[ml-get-filter-query-parms]]
3839
==== {api-query-parms-title}
@@ -53,7 +54,8 @@ properties:
5354
(string) A description of the filter.
5455

5556
`filter_id`::
56-
(string) A string that uniquely identifies the filter.
57+
(string)
58+
include::{docdir}/ml/ml-shared.asciidoc[tag=filter-id]
5759

5860
`items`::
5961
(array of strings) An array of strings which is the filter item list.

docs/reference/ml/anomaly-detection/apis/post-calendar-event.asciidoc

+12-11
Original file line numberDiff line numberDiff line change
@@ -30,30 +30,31 @@ of which must have a start time, end time, and description.
3030
==== {api-path-parms-title}
3131

3232
`<calendar_id>`::
33-
(Required, string) Identifier for the calendar.
33+
(Required, string)
34+
include::{docdir}/ml/ml-shared.asciidoc[tag=calendar-id]
3435

3536
[[ml-post-calendar-event-request-body]]
3637
==== {api-request-body-title}
3738

3839
`events`::
39-
(Required, array) A list of one of more scheduled events. The event's start
40-
and end times may be specified as integer milliseconds since the epoch or as a
41-
string in ISO 8601 format. An event resource has the following properties:
40+
(Required, array) A list of one of more scheduled events. The event's start and
41+
end times may be specified as integer milliseconds since the epoch or as a
42+
string in ISO 8601 format. An event resource has the following properties:
4243

4344
`events`.`calendar_id`:::
44-
(Optional, string) An identifier for the calendar that contains the scheduled
45-
event.
45+
(Optional, string)
46+
include::{docdir}/ml/ml-shared.asciidoc[tag=calendar-id]
4647

4748
`events`.`description`:::
48-
(Optional, string) A description of the scheduled event.
49+
(Optional, string) A description of the scheduled event.
4950

5051
`events`.`end_time`:::
51-
(Required, date) The timestamp for the end of the scheduled event
52-
in milliseconds since the epoch or ISO 8601 format.
52+
(Required, date) The timestamp for the end of the scheduled event in
53+
milliseconds since the epoch or ISO 8601 format.
5354

5455
`events`.`start_time`:::
55-
(Required, date) The timestamp for the beginning of the scheduled event
56-
in milliseconds since the epoch or ISO 8601 format.
56+
(Required, date) The timestamp for the beginning of the scheduled event in
57+
milliseconds since the epoch or ISO 8601 format.
5758

5859
[[ml-post-calendar-event-example]]
5960
==== {api-examples-title}

docs/reference/ml/anomaly-detection/apis/put-calendar-job.asciidoc

+2-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,8 @@ Adds an {anomaly-job} to a calendar.
2424
==== {api-path-parms-title}
2525

2626
`<calendar_id>`::
27-
(Required, string) Identifier for the calendar.
27+
(Required, string)
28+
include::{docdir}/ml/ml-shared.asciidoc[tag=calendar-id]
2829

2930
`<job_id>`::
3031
(Required, string)

docs/reference/ml/anomaly-detection/apis/put-calendar.asciidoc

+3-2
Original file line numberDiff line numberDiff line change
@@ -30,13 +30,14 @@ For more information, see
3030
==== {api-path-parms-title}
3131

3232
`<calendar_id>`::
33-
(Required, string) Identifier for the calendar.
33+
(Required, string)
34+
include::{docdir}/ml/ml-shared.asciidoc[tag=calendar-id]
3435

3536
[[ml-put-calendar-request-body]]
3637
==== {api-request-body-title}
3738

3839
`description`::
39-
(Optional, string) A description of the calendar.
40+
(Optional, string) A description of the calendar.
4041

4142
[[ml-put-calendar-example]]
4243
==== {api-examples-title}

docs/reference/ml/anomaly-detection/apis/put-filter.asciidoc

+2-1
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,8 @@ the `custom_rules` property of detector configuration objects.
3131
==== {api-path-parms-title}
3232

3333
`<filter_id>`::
34-
(Required, string) Identifier for the filter.
34+
(Required, string)
35+
include::{docdir}/ml/ml-shared.asciidoc[tag=filter-id]
3536

3637
[[ml-put-filter-request-body]]
3738
==== {api-request-body-title}

docs/reference/ml/anomaly-detection/apis/update-filter.asciidoc

+2-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,8 @@ Updates the description of a filter, adds items, or removes items.
2424
==== {api-path-parms-title}
2525

2626
`<filter_id>`::
27-
(Required, string) Identifier for the filter.
27+
(Required, string)
28+
include::{docdir}/ml/ml-shared.asciidoc[tag=filter-id]
2829

2930
[[ml-update-filter-request-body]]
3031
==== {api-request-body-title}

docs/reference/ml/ml-shared.asciidoc

+8
Original file line numberDiff line numberDiff line change
@@ -140,6 +140,10 @@ analyzing the splits with respect to their own history. It is used for finding
140140
unusual values in the context of the split.
141141
end::by-field-name[]
142142

143+
tag::calendar-id[]
144+
A string that uniquely identifies a calendar.
145+
end::calendar-id[]
146+
143147
tag::categorization-analyzer[]
144148
If `categorization_field_name` is specified, you can also define the analyzer
145149
that is used to interpret the categorization field. This property cannot be used
@@ -570,6 +574,10 @@ optional. If it is not specified, no token filters are applied prior to
570574
categorization.
571575
end::filter[]
572576

577+
tag::filter-id[]
578+
A string that uniquely identifies a filter.
579+
end::filter-id[]
580+
573581
tag::frequency[]
574582
The interval at which scheduled queries are made while the {dfeed} runs in real
575583
time. The default value is either the bucket span for short bucket spans, or,

0 commit comments

Comments
 (0)