spotify/ffwd-ruby

crash when non-existant hostname is specified in configuration

Opened this issue · 0 comments

With the following configuration:

:output:
  - :type: "riemann"
    :host: "non-existant.example.com"

You get the following on stderr:

/opt/rbenv/ffwd-all/versions/2.1.0/lib/ruby/gems/2.1.0/gems/eventmachine-1.0.3/lib/eventmachine.rb:664:in `connect_server': unable to resolve server address (EventMachine::ConnectionError)
        from /opt/rbenv/ffwd-all/versions/2.1.0/lib/ruby/gems/2.1.0/gems/eventmachine-1.0.3/lib/eventmachine.rb:664:in `bind_connect'
        from /opt/rbenv/ffwd-all/versions/2.1.0/lib/ruby/gems/2.1.0/gems/eventmachine-1.0.3/lib/eventmachine.rb:640:in `connect'
        from /opt/rbenv/ffwd-all/versions/2.1.0/lib/ruby/gems/2.1.0/gems/ffwd-0.2.3/lib/ffwd/protocol/tcp/connection.rb:58:in `connect'
        from /opt/rbenv/ffwd-all/versions/2.1.0/lib/ruby/gems/2.1.0/gems/ffwd-0.2.3/lib/ffwd/protocol/tcp/flushing_connect.rb:68:in `block in initialize'
        from /opt/rbenv/ffwd-all/versions/2.1.0/lib/ruby/gems/2.1.0/gems/ffwd-0.2.3/lib/ffwd/lifecycle.rb:51:in `call'
        from /opt/rbenv/ffwd-all/versions/2.1.0/lib/ruby/gems/2.1.0/gems/ffwd-0.2.3/lib/ffwd/lifecycle.rb:51:in `each'
        from /opt/rbenv/ffwd-all/versions/2.1.0/lib/ruby/gems/2.1.0/gems/ffwd-0.2.3/lib/ffwd/lifecycle.rb:51:in `start'
        from /opt/rbenv/ffwd-all/versions/2.1.0/lib/ruby/gems/2.1.0/gems/ffwd-0.2.3/lib/ffwd/lifecycle.rb:83:in `block in depend_on'
        from /opt/rbenv/ffwd-all/versions/2.1.0/lib/ruby/gems/2.1.0/gems/ffwd-0.2.3/lib/ffwd/lifecycle.rb:51:in `call'
        from /opt/rbenv/ffwd-all/versions/2.1.0/lib/ruby/gems/2.1.0/gems/ffwd-0.2.3/lib/ffwd/lifecycle.rb:51:in `each'
        from /opt/rbenv/ffwd-all/versions/2.1.0/lib/ruby/gems/2.1.0/gems/ffwd-0.2.3/lib/ffwd/lifecycle.rb:51:in `start'
        from /opt/rbenv/ffwd-all/versions/2.1.0/lib/ruby/gems/2.1.0/gems/ffwd-0.2.3/lib/ffwd/core.rb:132:in `block in run'
        from /opt/rbenv/ffwd-all/versions/2.1.0/lib/ruby/gems/2.1.0/gems/eventmachine-1.0.3/lib/eventmachine.rb:187:in `call'
        from /opt/rbenv/ffwd-all/versions/2.1.0/lib/ruby/gems/2.1.0/gems/eventmachine-1.0.3/lib/eventmachine.rb:187:in `run_machine'
        from /opt/rbenv/ffwd-all/versions/2.1.0/lib/ruby/gems/2.1.0/gems/eventmachine-1.0.3/lib/eventmachine.rb:187:in `run'
        from /opt/rbenv/ffwd-all/versions/2.1.0/lib/ruby/gems/2.1.0/gems/ffwd-0.2.3/lib/ffwd/core.rb:128:in `run'
        from /opt/rbenv/ffwd-all/versions/2.1.0/lib/ruby/gems/2.1.0/gems/ffwd-0.2.3/lib/ffwd.rb:360:in `main'
        from /opt/rbenv/ffwd-all/versions/2.1.0/lib/ruby/gems/2.1.0/gems/ffwd-0.2.3/bin/ffwd:9:in `<top (required)>'
        from /opt/rbenv/ffwd-all/versions/2.1.0/bin/ffwd:23:in `load'
        from /opt/rbenv/ffwd-all/versions/2.1.0/bin/ffwd:23:in `<main>'