lib/logstash/inputs/http_poller.rb in logstash-input-http_poller-4.0.1 vs lib/logstash/inputs/http_poller.rb in logstash-input-http_poller-4.0.2

- old
+ new

@@ -40,12 +40,11 @@ public Schedule_types = %w(cron every at in) def register @host = Socket.gethostname.force_encoding(Encoding::UTF_8) - @logger.info("Registering http_poller Input", :type => @type, - :urls => @urls, :schedule => @schedule, :timeout => @timeout) + @logger.info("Registering http_poller Input", :type => @type, :schedule => @schedule, :timeout => @timeout) setup_requests! end def stop @@ -213,12 +212,19 @@ rescue StandardError, java.lang.Exception => e @logger.error? && @logger.error("Cannot read URL or send the error as an event!", :exception => e, :exception_message => e.message, :exception_backtrace => e.backtrace, + :name => name) + + # If we are running in debug mode we can display more information about the + # specific request which could give more details about the connection. + @logger.debug? && @logger.debug("Cannot read URL or send the error as an event!", + :exception => e, + :exception_message => e.message, + :exception_backtrace => e.backtrace, :name => name, - :url => request - ) + :url => request) end private def apply_metadata(event, name, request, response=nil, execution_time=nil) return unless @metadata_target