lib/logstasher/active_support/log_subscriber.rb in logstasher-1.0.1 vs lib/logstasher/active_support/log_subscriber.rb in logstasher-1.1.0

- old
+ new

@@ -13,10 +13,11 @@ data = extract_request(payload) data.merge! extract_status(payload) data.merge! runtimes(event) data.merge! location(event) data.merge! extract_exception(payload) + data.merge! LogStasher.store data.merge! extract_custom_fields(payload) tags = ['request'] tags.push('exception') if payload[:exception] logger << LogStasher.build_logstash_event(data, tags).to_json + "\n" @@ -84,10 +85,10 @@ # Monkey patching to enable exception logging def extract_exception(payload) if payload[:exception] exception, message = payload[:exception] - status = ActionDispatch::ExceptionWrapper.status_code_for_exception(exception) + status = ::ActionDispatch::ExceptionWrapper.status_code_for_exception(exception) if LogStasher.backtrace backtrace = $!.backtrace.join("\n") else backtrace = $!.backtrace.first end