ElasticSearch
This check connects to a specified ElasticSearch database, run a query against it and verify the results.
Opensearch
To connect to Opensearch use opensearch
field instead of elasticsearch
elasticsearch.yamlapiVersion: canaries.flanksource.com/v1
kind: Canary
metadata:
name: elasticsearch-pass
spec:
schedule: "@every 5m"
elasticsearch:
- url: http://elasticsearch.canaries.svc.cluster.local:9200
description: Elasticsearch checker
index: index
query: |
{
"query": {
"term": {
"system.role": "api"
}
}
}
results: 1
name: elasticsearch_pass
Field | Description | Scheme |
---|---|---|
index* | Index against which query should be ran | |
name* | Name of the check, must be unique within the canary |
|
query* | Query that needs to be executed on the server | JSON |
url* | Elasticsearch URL | |
results | Number of expected hits |
|
description | Description for the check |
|
display | Expression to change the formatting of the display | |
icon | Icon for overwriting default icon on the dashboard | |
labels | Labels for check | map[string]string |
metrics | Metrics to export from | |
test | Evaluate whether a check is healthy | |
transform | Transform data from a check into multiple individual checks | |
username | ||
password |