Skip to content
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
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ PUT /_ilm/policy/my-data-stream-policy
"hot": {
"actions": {
"rollover": {
"max_size": "25GB"
"max_primary_shard_size": "25GB"
}
}
},
Expand Down
2 changes: 1 addition & 1 deletion docs/reference/data-streams/set-up-a-data-stream.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ PUT /_ilm/policy/my-data-stream-policy
"hot": {
"actions": {
"rollover": {
"max_size": "25GB"
"max_primary_shard_size": "25GB"
}
}
},
Expand Down
23 changes: 23 additions & 0 deletions docs/reference/ilm/actions/ilm-rollover.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,29 @@ shard is a primary (`p`) or a replica (`r`).
[[ilm-rollover-ex]]
==== Example

[[ilm-rollover-primar-shardsize-ex]]
===== Roll over based on largest primary shard size

This example rolls the index over when its largest primary shard is at least 50 gigabytes.

[source,console]
--------------------------------------------------
PUT _ilm/policy/my_policy
{
"policy": {
"phases": {
"hot": {
"actions": {
"rollover" : {
"max_primary_shard_size": "50GB"
}
}
}
}
}
}
--------------------------------------------------

[[ilm-rollover-size-ex]]
===== Roll over based on index size

Expand Down
12 changes: 6 additions & 6 deletions docs/reference/ilm/ilm-tutorial.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ and the actions to perform in each phase. A lifecycle can have up to five phases
For example, you might define a `timeseries_policy` that has two phases:

* A `hot` phase that defines a rollover action to specify that an index rolls over when it
reaches either a `max_size` of 50 gigabytes or a `max_age` of 30 days.
reaches either a `max_primary_shard_size` of 50 gigabytes or a `max_age` of 30 days.
* A `delete` phase that sets `min_age` to remove the index 90 days after rollover.
Note that this value is relative to the rollover time, not the index creation time.

Expand All @@ -72,18 +72,18 @@ PUT _ilm/policy/timeseries_policy
{
"policy": {
"phases": {
"hot": { <1>
"hot": { <1>
"actions": {
"rollover": {
"max_size": "50GB", <2>
"max_primary_shard_size": "50GB", <2>
"max_age": "30d"
}
}
},
"delete": {
"min_age": "90d", <3>
"min_age": "90d", <3>
"actions": {
"delete": {} <4>
"delete": {} <4>
}
}
}
Expand Down Expand Up @@ -232,7 +232,7 @@ is met.
"min_age": "0ms",
"actions": {
"rollover": {
"max_size": "50gb",
"max_primary_shard_size": "50gb",
"max_age": "30d"
}
}
Expand Down
2 changes: 1 addition & 1 deletion docs/reference/ilm/set-up-lifecycle-policy.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ PUT _ilm/policy/my_policy
"hot": {
"actions": {
"rollover": {
"max_size": "25GB" <1>
"max_primary_shard_size": "25GB" <1>
}
}
},
Expand Down
2 changes: 1 addition & 1 deletion docs/reference/indices/get-data-stream.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ PUT /_ilm/policy/my-lifecycle-policy
"hot": {
"actions": {
"rollover": {
"max_size": "25GB"
"max_primary_shard_size": "25GB"
}
}
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"hot": {
"actions": {
"rollover": {
"max_size": "50GB",
"max_primary_shard_size": "50gb",
"max_age": "30d"
}
}
Expand Down
2 changes: 1 addition & 1 deletion x-pack/plugin/core/src/main/resources/logs-policy.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"hot": {
"actions": {
"rollover": {
"max_size": "50gb",
"max_primary_shard_size": "50gb",
"max_age": "30d"
}
}
Expand Down
2 changes: 1 addition & 1 deletion x-pack/plugin/core/src/main/resources/metrics-policy.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"hot": {
"actions": {
"rollover": {
"max_size": "50gb",
"max_primary_shard_size": "50gb",
"max_age": "30d"
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"hot": {
"actions": {
"rollover": {
"max_size": "50GB"
"max_primary_shard_size": "50gb"
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"hot": {
"actions": {
"rollover": {
"max_size": "50gb",
"max_primary_shard_size": "50gb",
"max_age": "30d"
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"hot": {
"actions": {
"rollover": {
"max_size": "50GB",
"max_primary_shard_size": "50gb",
"max_age": "30d"
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"hot": {
"actions": {
"rollover": {
"max_size": "50gb",
"max_primary_shard_size": "50gb",
"max_age": "30d"
}
}
Expand Down