I have cut down the 'classic' list to these:
Name Order Purpose
---------------------------------------------------------------
LOG_ERR
LOG_WARN
LOG_NOTICE
LOG_DEBUG
LOG_INFO
I can add more and it's easy to add custom levels on the fly, but
my main question is, can we standardise the meaning of the names
and the purpose. For example, WARN, NOTICE and INFO look pretty
similar to me -- do we need them all? And when would we use
them?
Then there is also the question of the order, because whilst it's
possible to switch on a specific level (or, even cherry pick
levels with a bit of extra code), being able to say 'any log
levels below and including foo' is useful.
So I put that list, just to see what order and purpose you think
those levels should have. If you do not see what you'd like, add
it to the list :)
thanks,
G
What are we going to use certain log level for, and when/why?
I have cut down the 'classic' list to these:
Name Order Purpose
---------------------------------------------------------------
LOG_ERR
LOG_WARN
LOG_NOTICE
LOG_DEBUG
LOG_INFO
I can add more and it's easy to add custom levels on the fly, but
my main question is, can we standardise the meaning of the names
and the purpose. For example, WARN, NOTICE and INFO look pretty
similar to me -- do we need them all? And when would we use
them?
Then there is also the question of the order, because whilst it's
possible to switch on a specific level (or, even cherry pick
levels with a bit of extra code), being able to say 'any log
levels below and including foo' is useful.
So I put that list, just to see what order and purpose you think
those levels should have. If you do not see what you'd like, add
it to the list :)
thanks,
G
--
You received this message because you are subscribed to the Google Groups "CorinthiaTeam" group.
To unsubscribe from this group and stop receiving emails from it, send an email to corinthiatea...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
(snip)
> --
> Cheers,
>
> Ian C
Hi,
I have to admit I've never actually used a logger, until I wrote one
and tested it. *blush*
Mostly I used printf I typed out dutifully, then commented out and
eventually deleted, just to retype them. Several times over. (gah)
Hence, my desire to have something that allows me to selectively
create customised debug statements (say, per function) so that I write
once, and then just switch off, until I inevitably find that I need
them again.
Also, I have to ask/verify some things with y'all, just so I can
document this properly to make sure that everyone is on the same plane
:-)
LOG_ERR: Is this meant for production code? With the idea that ERR
seems to be a pretty serious case and probably something that
only happens when the moon is green.
LOG_INFO: Is this used to leave little communiques about the code,
say, if I made a less than optimal algo that works but could
do better, or if there is a TODO issue that affects the code
path later on?
LOG_TRACE: Is this a 'I was here' thingy as we know it from gdb's
stack trace, just less work? (if so, this would be very
nice to have a turn off/on switch[1])
LOG_DEBUG: I imagine to this to be incredibly noisy in a big
application. How do you use this so that it's not
ending up in a wall of text of everything?
LOG_WARN: Jan didn't think it's needed, Ian has said it's for 'near
misses', so Ian, could I ask you in what situation you would
prefer to use this instead of LOG_ERR, or, perhaps,
LOG_INFO?
LOG_VERBOSE: Ian mentioned this. He said 'even more info what is
going on'. Ian, do you have a use case so I can
understand how, where and why this is useful?
On another note, (to continue the LOG_ERR theme) the only other
error system I worked with was svn's rather comprehensive error
reporting system. Would that kind of thing be something for us
to consider for production code (so we can for example process
bug reports much easier), besides the dev centred logger?
G
Ps.: Sorry to be so overly picky and uh, logger obsessed(and, wordy!).
But I think that in code (for a change) words have meaning, and I
think that the above is important to have agreement on, because in the
end, it saves much time. Plus I'm curious as to what this all means
and how people are going to make this work for them, so I can 'reduce
to essence'.
[1] Ian about his Lenses branch: "It still needs some (quite a bit)
cleaning, to get rid of some warnings, and trace messages. "
See, that's what I'm talking about. N% of those messages will need
to be retyped at some point and with my little geegaw, they could just
be turned off with one command, and forgotten until they are needed
once more. Because they all start with LOG_, you could even have a
convention that they start with LOG_C_ and then teach emacs and vi to
blank those lines if you don't want to see them in the display.
I may be wrong, but currently I really think that this idea will save
a lot of programmer time in the end.
On 12 Sep 2015, at 12:38 am, jan i <ja...@apache.org> wrote:
On Thursday, September 10, 2015, Gabriela Gibson <gabriel...@gmail.com> wrote:What are we going to use certain log level for, and when/why?
I have cut down the 'classic' list to these:
Name Order Purpose
---------------------------------------------------------------
LOG_ERR
LOG_WARN
LOG_NOTICE
LOG_DEBUG
LOG_INFOi am all for romving LOG_WARN and LOG_NOTICE, It is too detailed in my opinion.rgdsjan i
I can add more and it's easy to add custom levels on the fly, but
my main question is, can we standardise the meaning of the names
and the purpose. For example, WARN, NOTICE and INFO look pretty
similar to me -- do we need them all? And when would we use
them?
On 15 Sep 2015, at 5:53 am, Gabriela Gibson <gabriel...@gmail.com> wrote:Also, I have to ask/verify some things with y'all, just so I can
document this properly to make sure that everyone is on the same plane
:-)
LOG_ERR: Is this meant for production code? With the idea that ERR
seems to be a pretty serious case and probably something that
only happens when the moon is green.