Andrew Thompson
39ef6e4a5c
Re-factor the file backend so it starts one gen_event handler per file
13 anni fa
Andrew Thompson
121c4c5241
Initial implementation of 'tracing'
13 anni fa
Jared Morrow
f435790657
Roll version 0.9.4
13 anni fa
Andrew Thompson
3311702a6d
Add builtin chomping to lager_format
13 anni fa
Andrew Thompson
31d9529e3e
Default to treating lists as strings, (and set it false for ~w)
13 anni fa
Andrew Thompson
9c6ce62ff8
Fix some more formatting bugs
13 anni fa
Andrew Thompson
de5d84e349
Fix how the name/pid of the process is printed in crash reports
Before this fix, the code assumed that processes without a registered
name omitted the {registered_name, X} tuple in the crash report. In
actual fact, process_info/2 returns [] when the process has no
registered name, so unregistered processes were being printed with a
"name" of "[]". This corrects the code to print the Pid in this case
instead.
13 anni fa
Jared Morrow
1d7b6903d5
Roll version 0.9.3
13 anni fa
Andrew Thompson
9e735a72ad
Improve tests, fix some minor bugs
13 anni fa
Andrew Thompson
d16dfaa0f8
Implement ~P/~W style depth-limiting
13 anni fa
Andrew Thompson
e5b58fc71e
Implement print options for trunc_io so ~s/~p/~w emulation is more accurate
Specifically, the handling of lists/binaries/atoms is closer to
io_lib:format's behaviour, and some regular expressions are eliminated.
13 anni fa
Andrew Thompson
e45d5bc3c9
Implement an alternative and much faster lager_trunc_io:format/3
13 anni fa
Andrew Thompson
5140cb3449
Don't convert \r, etc to spaces, don't assume printablility by first char
13 anni fa
Jared Morrow
8427d06cb7
Roll version 0.9.2
13 anni fa
Andrew Thompson
b61718ff80
Make the call to the crash log synchronous only when testing
13 anni fa
Andrew Thompson
4dfee06cd9
Make tests less dependant on timer:sleeps to function correctly
13 anni fa
Jared Morrow
80f5ffbe04
Version roll 0.9.1
13 anni fa
Andrew Thompson
7e9da648db
Several fixes for printing binaries, improve quote stripping
In string mode, "..", '..' and <<"..">> are stripped, just like with
io:format.
13 anni fa
Andrew Thompson
6fdbe25071
Use mfargs instead of name attribute as the way to detect supervisor_bridge
As Ryan pointed out, the 'name' of a supervisor's child may be
'undefined' for a simple_one_for_one supervisor.
13 anni fa
Andrew Thompson
53d5de448c
Fix term printing in errors to properly show embedded lists
The ~w formatting used before was not printing lists embedded in other
terms. This change uses trunc_io to print those terms safely and without
potentially introducing linebreaks (like ~p would)
13 anni fa
Andrew Thompson
af4ea7f31d
Don't treat floats in a list as printable characters Reported by @bryanhughes
The test if an element in a list was in the printable range didn't
handle the case of a float in the list that compared to be in the
printable range.
13 anni fa
Andrew Thompson
a0440a9d60
Smarter doublequote stripping when printing strings with ~s
13 anni fa
Andrew Thompson
9a577df2e0
Use the io_lib_format:fwrite_g function to print floats
This is superior to float_to_list as it only prints the meaningful
digits and 1.0 isn't rendered as "1.00000000000000000000e+00".
13 anni fa
Andrew Thompson
3babca112c
Make sure atoms needing quoting are quoted.
13 anni fa
Scott Lystig Fritchie
042e210a9d
Remove application:unload() calls from test code
13 anni fa
Scott Lystig Fritchie
83c2a412ab
Mash in the remainder of adt-error-format-protection branch
13 anni fa
Scott Lystig Fritchie
cf51ba06d3
Rename format_string_chop() -> safe_format_chop(), add -export
13 anni fa
Scott Lystig Fritchie
eea29bece1
Rework using safe_format() from one of Andrew's branches
13 anni fa
Scott Lystig Fritchie
9a6aff40a7
Add lager:log() message size truncation
Use lager_trunc_io:format() for all messages submitted via
lager:log(). Also, refactor list flattening and final newline
stripping into shared func that uses re:replace() to do both.
13 anni fa
Andrew Thompson
95f87e5d8b
Remove unecessary and pointless call to lists:flatten
13 anni fa
Andrew Thompson
19f2339458
Make console backend more robust against bad configuration
13 anni fa
Andrew Thompson
d828c35f12
Fixup the tests after merging in the rotation code
13 anni fa
Andrew Thompson
116ee8d890
Try to preserve internal log messages generated before lager boots
If backends have a failure or something, don't discard the messages,
wait half a second and then try sending them again.
13 anni fa
Andrew Thompson
03d3fa1a95
Fixes and tests for deep-list handling in trunc_io:format
This solves an issue reported by 'cloudhead' in IRC where deep lists
weren't being flattened when printed with format specifiers like ~s ~p
and ~P, all of which should flatten the list.
13 anni fa
Andrew Thompson
cde3eecf1a
Tests for the gen_event handler watcher
13 anni fa
Andrew Thompson
bf5861a548
Tests for the crash log
13 anni fa
Andrew Thompson
bff8eb1162
Console backend tests
13 anni fa
Andrew Thompson
3fe861c348
Lots of tests for the file backend
13 anni fa
Andrew Thompson
55e0cc1f5a
schedule_rotation returns undefined when no rotation scheduled
13 anni fa
Andrew Thompson
052b639c0c
Wrap to 80 columns
IBM punchcards rejoice! Basho supports your right to continue to affect
how we format source code :)
13 anni fa
Andrew Thompson
874b76982b
Simple test for logfile rotation
13 anni fa
Andrew Thompson
b2d9d06abd
Cleanup logfile option validation, as suggested by @jtuple
13 anni fa
Andrew Thompson
7d8c104bfc
Update app.src file with time based rotation config
13 anni fa
Andrew Thompson
81d4aea7d8
Finish implementing time based log rotation
14 anni fa
Andrew Thompson
dc15d9272e
Initial work on time based rotation
Adding date spec parsing and calculation of when a spec indicates a file
next needs to be rotated.
14 anni fa
Andrew Thompson
6eb8240f1a
Crash log rotation & documentation on rotation
14 anni fa
Andrew Thompson
5c11c70a31
Add simple size based log rotation
14 anni fa
Andrew Thompson
5fe8f7c2ad
Pids are sometimes not pids, print them more safely
13 anni fa
Andrew Thompson
11366b355c
Wrap an obscenely long line
13 anni fa
Andrew Thompson
40b0e2d484
Record milliseconds with timestamps, make console less verbose by default
az558
13 anni fa