elasticsearch-prometheus-exporter is used to collect all relevant metrics and makes them available to Prometheus via the Elasticsearch REST API.
http://:9200/_prometheus/metrics
This plugin supports till 7.17.7 version
How can we get the metrics from Elasticsearch 8 version with xpack enabled