Skip to content
This repository has been archived by the owner on Sep 21, 2023. It is now read-only.

Allow the Elasticsearch output to load balance between multiple hosts #152

Open
Tracked by #16
cmacknz opened this issue Oct 31, 2022 · 0 comments
Open
Tracked by #16
Labels
8.9-candidate Team:Elastic-Agent-Data-Plane Label for the Agent Data Plane team

Comments

@cmacknz
Copy link
Member

cmacknz commented Oct 31, 2022

Support load balancing when multiple Elasticsearch hosts are configured. The behaviour should be the same as the existing Elasticsearch output. See the hosts documentation:

The list of Elasticsearch nodes to connect to. The events are distributed to these nodes in round robin order. If one node becomes unreachable, the event is automatically sent to another node. Each Elasticsearch node can be defined as a URL or IP:PORT. For example: http://192.15.3.2, https://es.found.io:9230 or 192.24.3.2:9300. If no port is specified, 9200 is used.

The go-elasticsearch client accepts multiple host addresses per its configuration, which it uses with the elastictransport which claims to have this behaviour by default:

When multiple addresses are passed in configuration, the package will use them in a round-robin fashion, and will keep track of live and dead nodes. The status of dead nodes is checked periodically.

The scope of this issue should just be testing that the configuration works as desired without requiring any specific code changes.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
8.9-candidate Team:Elastic-Agent-Data-Plane Label for the Agent Data Plane team
Projects
None yet
Development

No branches or pull requests

2 participants