Rolloveredit

action: rollover
description: >-
  Rollover the index associated with index 'name', which should be in the
  form of prefix-000001 (or similar), or prefix-YYYY.MM.DD-1.
options:
  name: aliasname
  conditions:
    max_age: 1d
    max_docs: 1000000

This action uses the Elasticsearch Rollover API to create a new index, if the described conditions are met.

When choosing conditions, either one of max_age or max_docs, or both may be used. If both are used, then both conditions must be matched for the rollover to occur.

If either or both of the max_age or max_docs options are present, they must each have a value. Because there is no default value, neither of these options can be left empty, or Curator will generate an error.

Extra settingsedit

The extra_settings option allows the addition of extra index settings (but not mappings). An example of how these settings can be used might be:

action: rollover
description: >-
  Rollover the index associated with index 'name', which should be in the
  form of prefix-000001 (or similar), or prefix-YYYY.MM.DD-1.
options:
  name: aliasname
  conditions:
    max_age: 1d
    max_docs: 1000000
  extra_settings:
    index.number_of_shards: 3
    index.number_of_replicas: 1
  timeout_override:
  continue_if_exception: False
  disable_action: False

Required settingsedit

  • name The alias name
  • max_age The maximum age that is allowed before triggering a rollover. This must be nested under conditions:. There is no default value. If this condition is specified, it must have a value, or Curator will generate an error.
  • max_docs The maximum number of documents allowed in an index before triggering a rollover. This must be nested under conditions:. There is no default value. If this condition is specified, it must have a value, or Curator will generate an error.

Optional settingsedit

See an example of this action in an actionfile here.