opensearch-project / logstash-output-opensearch

A Logstash plugin that sends event data to a OpenSearch clusters and stores as an index.
https://opensearch.org/docs/latest/clients/logstash/index/
Apache License 2.0
106 stars 80 forks source link

Add a config to skip doing a GET on the healthcheck endpoint #165

Closed deepdatta closed 2 years ago

deepdatta commented 2 years ago

Is your feature request related to a problem? Please describe. I have come across instances of OpenSearch which responds with a 404 on the healthcheck endpoint causing the plugin to hit exceptions when trying to parse out a version number.

Describe the solution you'd like Add a skip_healthcheck config, which is false by default. When set to true it will not send a GET request to the healthcheck endpoint. However it will still send the HEAD request to make sure the node is alive. To get a version number in that scenario, add another config default_server_major_version which is 2 by default denoting OpenSearch 2.x, but can be changed by the user.

Describe alternatives you've considered

Additional context Add any other context or screenshots about the feature request here.