Query to return a result set bounded by a fixed number of zeros (no rainfall)

I'm using ES to store rainfall data from a weather API that updates every 10 minutes. I'm trying to write a query to return a set of records where a spell of dry weather ( 30 consecutive rain values in the range of 0 to 0.2) is followed by rainfall ( values 0+) to the present time. I was hoping to use a regex, but my values are floats and the query errors.

I'm new to ElasticSearch and am hoping that someone can give me some guidance of how best to construct a query.

Welcome to our community! :smiley:

What about doing it with a Watch, eg examples/Alerting/Sample Watches/system_fails_to_provide_data at master · elastic/examples · GitHub

Thanks Mark for the GitHub link! I'll read up on the ES docs as well about Watches.

Cheers
Rebecca

1 Like

Hi Mark, using a Watcher requires a non basic licence. I'm developing a product for research and community use and need to avoid unnecessary costs. Could you suggest another solution?

Many thanks
Rebecca

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.