Replaces Logger everywhere, and implements a simplified internal logging model because Log does the heavy lifting.
fixes #46
The logging namespace is 'mosquito' and job logs are run through a sub namespace for that class, which should make all sorts of filtering options possible.
The make demo output has been adjusted to provide output from the logger as well.
An excerpt from the make demo output:
I, [2020-04-21T18:53:17.025903000Z #73488] INFO -- crystal-run-run.tmp:mosquito: Success: task custom_serializers_job<1587495196913:549> finished and took 35.0µs
I, [2020-04-21T18:53:17.026565000Z #73488] INFO -- crystal-run-run.tmp:mosquito: Running task throttled_job<1587495196915:595> from throttled_job
I, [2020-04-21T18:53:17.026656000Z #73488] INFO -- crystal-run-run.tmp:throttled_job: throttled job: 2
I, [2020-04-21T18:53:17.027217000Z #73488] INFO -- crystal-run-run.tmp:mosquito: Success: task throttled_job<1587495196915:595> finished and took 31.0µs
I, [2020-04-21T18:53:17.130830000Z #73488] INFO -- crystal-run-run.tmp:mosquito: Running task custom_serializers_job<1587495196914:943> from custom_serializers_job
I, [2020-04-21T18:53:17.130953000Z #73488] INFO -- crystal-run-run.tmp:custom_serializers_job: using custom serialization: 525600
I, [2020-04-21T18:53:17.131040000Z #73488] INFO -- crystal-run-run.tmp:custom_serializers_job: deserialized: 5256000
I, [2020-04-21T18:53:17.131809000Z #73488] INFO -- crystal-run-run.tmp:mosquito: Success: task custom_serializers_job<1587495196914:943> finished and took 54.0µs
I, [2020-04-21T18:53:17.132913000Z #73488] INFO -- crystal-run-run.tmp:mosquito: Running task throttled_job<1587495196915:630> from throttled_job
I, [2020-04-21T18:53:17.133024000Z #73488] INFO -- crystal-run-run.tmp:throttled_job: throttled job: 3
I, [2020-04-21T18:53:17.134172000Z #73488] INFO -- crystal-run-run.tmp:throttled_job: Execution limit reached next_batch in 00:00:10 (at 2020-04-21 18:53:27 UTC)
I, [2020-04-21T18:53:17.134450000Z #73488] INFO -- crystal-run-run.tmp:mosquito: Success: task throttled_job<1587495196915:630> finished and took 69.0µs
I, [2020-04-21T18:53:17.240632000Z #73488] INFO -- crystal-run-run.tmp:mosquito: Running task periodically_puts<1587495196919:859> from periodically_puts
I, [2020-04-21T18:53:17.240774000Z #73488] INFO -- crystal-run-run.tmp:periodically_puts: Hello from PeriodicallyPuts
I, [2020-04-21T18:53:17.241506000Z #73488] INFO -- crystal-run-run.tmp:mosquito: Success: task periodically_puts<1587495196919:859> finished and took 45.0µs
I, [2020-04-21T18:53:20.345785000Z #73488] INFO -- crystal-run-run.tmp:mosquito: Running task periodically_puts<1587495200041:9> from periodically_puts
I, [2020-04-21T18:53:20.345910000Z #73488] INFO -- crystal-run-run.tmp:periodically_puts: Hello from PeriodicallyPuts
I, [2020-04-21T18:53:20.346787000Z #73488] INFO -- crystal-run-run.tmp:mosquito: Success: task periodically_puts<1587495200041:9> finished and took 44.0µs
I, [2020-04-21T18:53:23.453115000Z #73488] INFO -- crystal-run-run.tmp:mosquito: Running task periodically_puts<1587495203146:606> from periodically_puts
I, [2020-04-21T18:53:23.453235000Z #73488] INFO -- crystal-run-run.tmp:periodically_puts: Hello from PeriodicallyPuts
I, [2020-04-21T18:53:23.453957000Z #73488] INFO -- crystal-run-run.tmp:mosquito: Success: task periodically_puts<1587495203146:606> finished and took 44.0µs
I, [2020-04-21T18:53:26.543763000Z #73488] INFO -- crystal-run-run.tmp:mosquito: Running task periodically_puts<1587495206231:738> from periodically_puts
I, [2020-04-21T18:53:26.543887000Z #73488] INFO -- crystal-run-run.tmp:periodically_puts: Hello from PeriodicallyPuts
I, [2020-04-21T18:53:26.544671000Z #73488] INFO -- crystal-run-run.tmp:mosquito: Success: task periodically_puts<1587495206231:738> finished and took 46.0µs
I, [2020-04-21T18:53:27.071520000Z #73488] INFO -- crystal-run-run.tmp:mosquito: Running task throttled_job<1587495196916:684> from throttled_job
I, [2020-04-21T18:53:27.071650000Z #73488] INFO -- crystal-run-run.tmp:throttled_job: throttled job: 1
I, [2020-04-21T18:53:27.072713000Z #73488] INFO -- crystal-run-run.tmp:mosquito: Success: task throttled_job<1587495196916:684> finished and took 51.0µs
Replaces Logger everywhere, and implements a simplified internal logging model because Log does the heavy lifting.
fixes #46
The logging namespace is 'mosquito' and job logs are run through a sub namespace for that class, which should make all sorts of filtering options possible.
The
make demo
output has been adjusted to provide output from the logger as well.An excerpt from the
make demo
output: