New to Kestra?
Use blueprints to kickstart your first workflows.
Monitor a Meilisearch index with a scheduled canary query in Kestra. Alert Slack and fail the execution when an evergreen query returns zero hits.
A search index can be empty and still return HTTP 200. Health checks pass, dashboards stay green, and users quietly get zero results until someone notices. This blueprint closes that gap with a canary: io.kestra.plugin.meilisearch.Search runs a query that must always match in a healthy docs index, and an If task inspects the totalHits output. Zero hits sends a Slack alert with the exact query and then fails the execution through io.kestra.plugin.core.execution.Fail, so the incident is visible both in chat and in every dashboard built on execution state.
probe_search (io.kestra.plugin.meilisearch.Search) runs the canary_query input against the docs_site index. The task exposes the hit count as {{ outputs.probe_search.totalHits }} and stores the full result set as a file at {{ outputs.probe_search.uri }}.check_hits (io.kestra.plugin.core.flow.If) evaluates totalHits == 0.alert_zero_hits posts the query and index name to Slack, then fail_execution fails the run with a precise error message.log_healthy records the number of hits, turning the execution history into an availability log.errors block posts to Discord when the execution goes red for any reason, including an unreachable Meilisearch instance, so content alerts and platform alerts land in separate channels.Schedule trigger probes every 15 minutes.A canary is only useful if it runs relentlessly and complains loudly. Kestra provides the schedule, the conditional branching on the hit count, the deliberate failure semantics, and the execution history that turns every probe into an auditable data point, all in declarative YAML with no monitoring agent to deploy.
docs_site index, for example from the docs site ingest blueprint.MEILISEARCH_URL: Meilisearch connection URL, e.g. https://meilisearch.internal:7700.MEILISEARCH_KEY: Meilisearch API key with search permissions.SLACK_WEBHOOK_URL: Slack incoming webhook URL.DISCORD_WEBHOOK_URL: Discord incoming webhook URL.canary_query to a term that appears on evergreen pages of your docs.disabled: false on the every_15_minutes trigger.If condition, catching partial index loss as well.ForEach over index names.Subflow task.totalHits to the KV store after each probe.