elastic / elastic/logstash

Add TCP keepalive to Logstash output plugins

Open
#17,614 1 comment 0 reactions 0 assignees View on GitHub
enhancement status:needs-triage
Dominant language
Java
Stars
14.9k
Forks
3.5k
Avg merge
1d 4h
Merged PRs (30d)
88

Description

Would it be possible to add support for TCP keepalive in some of the output plugins by default?

I found that the tcp input plugin supports keepalive
/usr/share/logstash/vendor/bundle/jruby/3.1.0/gems/logstash-input-tcp-6.4.3-java/lib/logstash/inputs/tcp.rb

However I need this on some output plugins
/usr/share/logstash/vendor/bundle/jruby/3.1.0/gems/logstash-output-syslog-3.0.5/lib/logstash/outputs/syslog.rb
/usr/share/logstash/vendor/bundle/jruby/3.1.0/gems/logstash-output-tcp-6.2.1/lib/logstash/outputs/tcp.rb

Currently I am manually duplicating the keepalive settings from the tcp-input plugin over to the tcp-output and syslog-output plugins to enable this feature every time I update logstash. Would be nice if this were baked in so it could be easily turned on in the config.

Contributor guide

Open the contributing guide

Research direction

Start by comparing the keepalive handling in logstash-input-tcp-6.4.3-java/lib/logstash/inputs/tcp.rb with the mentioned output plugin files: logstash-output-syslog-3.0.5/lib/logstash/outputs/syslog.rb and logstash-output-tcp-6.2.1/lib/logstash/outputs/tcp.rb. Determine the intended configuration and scope for the output plugins; done means keepalive can be enabled through their Logstash configuration without manual plugin changes.

Written by the indexing model from the issue text.

Assessment

Tech stack
ruby
Domain
networking
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.