Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Index Lifecycle Management does not have a lower bound on poll_interval #39163

Closed
jakelandis opened this issue Feb 20, 2019 · 6 comments
Closed
Labels
:Data Management/ILM+SLM Index and Snapshot lifecycle management good first issue low hanging fruit help wanted adoptme

Comments

@jakelandis
Copy link
Contributor

Index Lifecycle Management has a polling interval that is configurable. The default is 10 minutes but may be changed via the dynamic indices.lifecycle.poll_interval setting.

Currently there is no lower bound, which if set too low could consume more compute resources that are reasonably required. We should enforce a lower bound of 1000ms (1s).

To reproduce:

PUT /_cluster/settings
{
  "persistent": {
    "indices.lifecycle.poll_interval": "1ms",
    "logger.org.elasticsearch.xpack.indexlifecycle": "TRACE"
  }
}

(watch the log file)

@jakelandis jakelandis added the :Data Management/ILM+SLM Index and Snapshot lifecycle management label Feb 20, 2019
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-core-features

@ppf2
Copy link
Member

ppf2 commented Feb 22, 2019

I wonder if we will want to set the lower bound to something higher than 1s. Do we see potential issues with ILM triggers as frequent as 1s for clusters that have frequent state changes that might have a fairly busy master node?

@gwbrown
Copy link
Contributor

gwbrown commented Feb 22, 2019

If we were basing a lower bound on what we expect to be useful in the wild, a minimum of something like 1m might be reasonable, but one thing that's prevented us from using a higher minimum than 1s in the past is that we set the poll_interval very low (1s or lower) in tests to speed up how long it takes to run the tests, and in many cases it makes tests possible that would not be possible otherwise (within a reasonable time frame per test).

Having a 1s minimum poll interval makes sense. While being able to set this setting lower has been occasionally useful in the past for more quickly reproducing race conditions, if we need to do that, it can always be done in a custom build with the lower limit disabled.

@WhiteBlackX6
Copy link

Hello all,
I am a new developer and I would really like to contribute to this project. May I work on this? Thank you.

@dakrone
Copy link
Member

dakrone commented Mar 4, 2019

@ApolloTheDeveloper there's currently already a PR open for it at #39593

@gwbrown
Copy link
Contributor

gwbrown commented Mar 5, 2019

Just merged #39593, which adds the lower bound of 1 second.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
:Data Management/ILM+SLM Index and Snapshot lifecycle management good first issue low hanging fruit help wanted adoptme
Projects
None yet
Development

No branches or pull requests

6 participants