lib/logjam_agent/request.rb in logjam_agent-0.11.2 vs lib/logjam_agent/request.rb in logjam_agent-0.11.3
- old
+ new
@@ -47,10 +47,10 @@
end
def add_line(severity, timestamp, message)
return if @bytes_all_lines > @max_bytes_all_lines
message = message.strip
- if message.size > @max_line_length
+ if message.size > @max_line_length && severity < Logger::ERROR
message[(@max_line_length-21)..-1] = " ... [LINE TRUNCATED]"
end
@mutex.synchronize do
if (@bytes_all_lines += message.bytesize) < @max_bytes_all_lines
@lines << [severity, format_time(timestamp), message]