logstash-plugins / logstash-input-irc

Apache License 2.0
3 stars 16 forks source link

Throw error if IRC connect fails #19

Open rmoff opened 8 years ago

rmoff commented 8 years ago

When connecting to freenode from an EC2 instance fails with :

11:26 !orwell.freenode.net *** Looking up your hostname...
11:26 !orwell.freenode.net *** Checking Ident
11:26 !orwell.freenode.net *** Found your hostname
11:26 !orwell.freenode.net *** No Ident response
11:26 !orwell.freenode.net *** Notice -- You need to identify via SASL to use this server
11:26 -!- ERROR Closing Link: ec2-x-x-x-x.eu-west-1.compute.amazonaws.com (SASL access only)

The logstash irc input plugin silently fails to do anything, giving no indication of a problem:

[ec2-user@logs-01 ~]$ /opt/logstash-2.3.0/bin/logstash --verbose --config ~/logstash-irc.conf
starting agent {:level=>:info}
starting pipeline {:id=>"main", :level=>:info}
Settings: Default pipeline workers: 2
Connecting to irc server {:host=>"chat.freenode.net", :port=>6667, :nick=>"xxxxxxx", :channels=>["#xxxxx"], :level=>:info}

Could it recognise the failed connection and abort the pipeline?

acidvegas commented 1 year ago

Ive had the same issue with the plugin...and to be honest the entire IRC plugin for input is very buggy and will break due to its lacking abilitys to decode certain encoding types. I will be working on a PR for this soon.