Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Logging conventions [closed]

What conventions do you use for log categories in log4j or similar libraries ? Usually you see class names as categories, but have you used other systems ?

What about log levels ? What levels do you use and in which case ?

Update: as some of you replied, there is no 'right' answer. I'm just looking for what different conventions people use as a possible source of inspiration.

like image 927
Tom Avatar asked Nov 05 '22 23:11

Tom


1 Answers

I have 3 levels: errors, warnings and verbose log telling whatever the program is doing at a time.

I use class+function as a context.

like image 144
Milan Babuškov Avatar answered Nov 12 '22 15:11

Milan Babuškov