OpenSearch is a fork of Elasticsearch that is maintained by Amazon. It is a drop-in replacement for Elasticsearch, and is fully compatible with the Elasticsearch API. It is a community-driven project that is open source and free to use.
OpenSearch is a distributed, RESTful search and analytics engine capable of solving a growing number of use cases. It is a good choice for storing data that is not relational in nature.
NAIS offers OpenSearch via Aiven.
As there are few teams that need an OpenSearch instance we use a IaC-repo to provision each instance. Head over to aiven-iac to learn how to get your own instance. To make it easier for you, when creating the instance, we will also create four users with read, write, readwrite and admin access.
Access from Nais-app¶
If you need access from an application, use the following nais.yaml-reference.
When an application requesting an OpenSearch instance is deployed, credentials will be provided as environment variables.
The service URI for OpenSearch is also available.
If you specify
openSearch.access, the credentials will be for the user with those access rights.
The available access levels are: 'admin', 'read', 'write', 'readwrite'
If not specified, the credentials will be for a user with read access.
Access from laptop¶
With Naisdevice you have access to the aiven-prod gateway. This is a JITA (just in time access) gateway, so you need to describe why, but the access is automatically given.
The URL for OpenSearch Dashboards (similar to Kibana) is the same as the OpenSearch instance, but using port 443 (regular https).
We do not offer support on OpenSearch as software, but questions about Aiven and provisioning can be directed to #pig_aiven on Slack.
We recommend that you set up your own alerts so that you can react to problems in your OpenSearch instance. Aiven uses Telegraf to collect and present metrics, so available metrics can be found in the Telegraf documentation.
We have configured our Prometheus instances in GCP to scrape the OpenSearch clusters in Aiven, so these metrics should be available in Grafana.
Particularly relevant input plugins are:
- elasticsearch (We belive the current open search plugin is very similar to this one)
OpenSearch is relatively new, so there aren't a lot of good resources on alerts/metrics for it yet. However, since it is a fork of ElasticSearch, much of what is written about ElasticSearch applies to OpenSearch too.
The metrics use the prefix
opensearch instead of
elasticsearch, otherwise it looks like the same metrics are available.
O'Reilly has a useful article about metrics to watch in an Elastic cluster.
Awesome prometheus alerts is another good source of alerts to look out for.
Some metrics that might be useful to watch, based on above article (We need feedback on this list, as we have no practical experience to lean on):