logstash-plugins / logstash-input-gelf

Apache License 2.0
20 stars 39 forks source link

log on exception, and continue event processing #51

Open Cactusbone opened 7 years ago

Cactusbone commented 7 years ago

log on exception, and continue event processing.

This should allow for easier debugging ( crash won't be lost in thousands of SocketError: bind: name or service not known logs)

and also won't stop logs processing...

jlecour commented 7 years ago

Thank you for this patch.

To make the whole problem disappear, those lines must also be in a begin/rescue block : https://github.com/F4-Group/logstash-input-gelf/blob/d525918876ccc86cb904be504eb71783336a7854/lib/logstash/inputs/gelf.rb#L110-L114

Cactusbone commented 7 years ago

Indeed, you're right !

I'll try adding some useful info after a few tests