Loading result_listener.rb +0 −5 Original line number Diff line number Diff line Loading @@ -97,7 +97,6 @@ def results(options, config) if(Time.now.to_i > message['timestamp'] + config['max_skew']) report("Rejected message #{message['id']}: Timestamp too old. (#{delivery_info[:channel].connection.host})") else puts message uri = URI.parse(config['api_url_results']) response = Net::HTTP.post_form(uri, { Loading @@ -108,7 +107,6 @@ def results(options, config) 'key' => config['api_pass'] } ) puts response.body end rescue Exception => e report("Could not decode message. (#{delivery_info[:channel].connection.host})") Loading Loading @@ -146,7 +144,6 @@ def requests(options, config) if(Time.now.to_i > message['timestamp'] + config['max_skew']) report("Rejected message #{message['id']}: Timestamp too old. (#{delivery_info[:channel].connection.host})") else puts message uri = URI.parse(config['api_url_requests']) response = Net::HTTP.post_form(uri, { Loading @@ -158,10 +155,8 @@ def requests(options, config) 'key' => config['api_pass'] } ) puts response.body end rescue Exception => e puts e.to_s report("Could not decode message. (#{delivery_info[:channel].connection.host})") end end Loading Loading
result_listener.rb +0 −5 Original line number Diff line number Diff line Loading @@ -97,7 +97,6 @@ def results(options, config) if(Time.now.to_i > message['timestamp'] + config['max_skew']) report("Rejected message #{message['id']}: Timestamp too old. (#{delivery_info[:channel].connection.host})") else puts message uri = URI.parse(config['api_url_results']) response = Net::HTTP.post_form(uri, { Loading @@ -108,7 +107,6 @@ def results(options, config) 'key' => config['api_pass'] } ) puts response.body end rescue Exception => e report("Could not decode message. (#{delivery_info[:channel].connection.host})") Loading Loading @@ -146,7 +144,6 @@ def requests(options, config) if(Time.now.to_i > message['timestamp'] + config['max_skew']) report("Rejected message #{message['id']}: Timestamp too old. (#{delivery_info[:channel].connection.host})") else puts message uri = URI.parse(config['api_url_requests']) response = Net::HTTP.post_form(uri, { Loading @@ -158,10 +155,8 @@ def requests(options, config) 'key' => config['api_pass'] } ) puts response.body end rescue Exception => e puts e.to_s report("Could not decode message. (#{delivery_info[:channel].connection.host})") end end Loading