Open adityaj1107 opened 3 years ago
Comment by dbbaughe Tuesday Apr 02, 2019 at 18:57 GMT
Hi Jon,
We do not allow per-second monitors currently. The Alerting Elasticsearch plugin currently only allows monitors to run as frequently as every minute which is why the UI only shows minutes, hours, and days. I will move this issue to the Alerting Elasticsearch plugin repo as a feature request.
Thanks, Drew
Comment by ghost Sunday Apr 07, 2019 at 05:46 GMT
@Jon-AtAWS Can you elaborate a bit on what is your use case for per-second/10 secs/30 secs monitoring intervals?
Comment by Jon-AtAWS Monday Apr 08, 2019 at 21:50 GMT
If I'm monitoring something... security, infra, whatever, seconds can matter. I don't necessarily want to wait a minute, worst case, to find out my website went down.
Apart from that, it seems arbitrary to cut off at minutes. If I want to pay the cost of scaling to handle per-second queries, I should be able to do that. I haven't dug into cron, did we cut the seconds off of that?
Comment by ghost Tuesday Apr 09, 2019 at 04:36 GMT
We absolutely do want to support shorter intervals in the future but wanted to take a cautious approach to it after gathering user feedback on use-cases.
That said there are some valid reasons we elected to pick 1 minute as a good lower bound for the initial release:
discovery.zen.publish_timeout
which is 30s) . This doesn't completely address the failure mode but having monitors run at a much higher frequency can lead to duplicate/missing runs. script.max_compilations_rate
which is currently 15/minute. For the use cases you bring up (security, infra) I think we would rather investigate a model where the monitor is run in response to a different external input rather than a high frequency cron based polling.
Adding voice of the community from another discussion -
Currently, minimum time unit of OpenSearch scheduler plugin is minute. It can lead request throttling if many jobs (ISM, monitor) are registered. To solve throttling, customers need to set jitter or specify "second" on cron expression to distribute time for triggering each jobs.
Other tools support second unit for scheduling.
Issue by Jon-AtAWS Monday Apr 01, 2019 at 21:27 GMT Originally opened as https://github.com/opendistro-for-elasticsearch/alerting/issues/20
Currently, setting by interval, I can choose minutes, hours, or days under Every. Please add seconds to this menu as well. There's no need to make me fiddle with a custom cron for a non-complicated, every 30 second (or every 10 second) monitor.