logback
logback copied to clipboard
Resolve DNS (respecting InetAddress caching rules) for each UDP packet.
When using the SyslogOutputStream (noting that it's also used by LogstashSocketAppender) the InetAddress DNS lookup result is cached at initialization. The resulting effect is that if the upstream syslog host changes IP (such as in a cloud environment where the instance is relaunched) logs are silently dropped (as they're sent using UDP) until logging is re-initialized (typically a service restart). Additionally, it blocks horizontal scaling of upstream syslog servers using a DNS round robin approach.
The submitted change uses the standard InetAddress DNS caching mechanism and so (DNS configuration dependent, but by default) does not result in a large overhead on DNS servers or the local JVM.
@tony19 Thanks for reviewing. I've made the fix (sorry it took so long, I was on holiday).
@dstockton, Instead of merging master to your branch, please rebase your two changes onto the tip of master, and squash your commits.
@tony19 I believe this is done now. Would you be able to merge?
@ceki It looks like Tony has been very busy. I think this PR is a small and useful change. Would you be willing to merge it? Or suggest another Git repo owner for me to contact? Many thanks
@dstockton I have asked Tony to suspend merges. I will look into this pull request ASAP. If I somehow overlook this request, do not hesitate to remind me.
@ceki Just following up with you about reviewing this PR. Many thanks!
hi, is there any progress on merging this?
I am currently working on SLF4J related pull requests. Will be looking at logback related requests in the coming days.
I hate to "me too" / +1 bug tickets but this has been a pretty big deal for us, I was about to implement something similar and was pleased to see someone beat me to it. Thanks
@treyhyde Thanks for the mention. I've ended up writing an additional OutputStream & Appender class that we load in from another JAR that do this as it's taken too long for us to wait. Assuming the merges are still not coming on this repo, you could also do the same quite quickly by just duplicating & changing the class names if you can't wait. Good luck!
Hello been wondering is there any progress on merging this or provider alternate resolution?
@MSMSalim good luck reviving a PR from 4 years ago!! :)