Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature Request: Support multiple target addresses in GELF::Notifier #104

Open
afreiberger opened this issue Jan 26, 2022 · 0 comments
Open

Comments

@afreiberger
Copy link

In the logstash-output-gelf project, there is a feature request to support multiple GELF destination hosts.
logstash-plugins/logstash-output-gelf#4

The GELF::Notifier initiator and the create_sender methods in this module would need to support passing multiple hosts and/or ports in order to properly address multiple destination GELF units when instantiating the transport layer.

The backend TCP, UDP, and TCP-TLS transport layers incorporate socket and failover management if provided with multiple addresses, however the GELF::Notifier module does not expose this functionality to consumers of this library.

The Notifier instantiation begins here and ends with a call to create_sender with a single host and port.
https://github.com/graylog-labs/gelf-rb/blob/master/lib/gelf/notifier.rb#L25

The create_sender definition is here:
https://github.com/graylog-labs/gelf-rb/blob/master/lib/gelf/notifier.rb#L137

This line of create_sender packs the single host and port into the proper array of host, port tuples, and requires further expansion to support multiple backend servers.
https://github.com/graylog-labs/gelf-rb/blob/master/lib/gelf/notifier.rb#L138

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant