[Asterisk-code-review] logger: Console sessions will now respect logger.conf dateformat= option (asterisk[master])

George Joseph asteriskteam at digium.com
Wed Mar 17 09:54:51 CDT 2021


George Joseph has posted comments on this change. ( https://gerrit.asterisk.org/c/asterisk/+/15545 )

Change subject: logger: Console sessions will now respect logger.conf dateformat= option
......................................................................


Patch Set 3:

(1 comment)

> Patch Set 3:
> 
> > Patch Set 3: Code-Review-1
> > 
> > Which log level and formatter are you looking at?  When using the default log formatter, VERBOSE messages are processed differently than other messages and don't include the date or callid.  If you use the "plain" formatter you do get them, for both local and remote console.
> 
> Given the following basic configuration.  dateformat= is only respected for the full log, not the console
> 
> [general]
> dateformat=%F %T.%3q
> 
> [logfiles]
> console  => notice,warning,error,verbose
> full     => notice,warning,error,debug,verbose

OK, now I see what's going on. The main asterisk process sends the timestamp formatted by 'dateformat' to the remote console for all non-verbose messages.  For verbose messages, it doesn't include the timestamp at all and leaves it to the remote console to format.  You need to make that clear in the commit message and in the CHANGES file.

https://gerrit.asterisk.org/c/asterisk/+/15545/3/main/logger.c 
File main/logger.c:

https://gerrit.asterisk.org/c/asterisk/+/15545/3/main/logger.c@695 
PS3, Line 695: }
You need to call ast_config_destroy(cfg) here.



-- 
To view, visit https://gerrit.asterisk.org/c/asterisk/+/15545
To unsubscribe, or for help writing mail filters, visit https://gerrit.asterisk.org/settings

Gerrit-Project: asterisk
Gerrit-Branch: master
Gerrit-Change-Id: I3ea10990dbd920e9f7ce8ff771bc65aa7f4ea8c1
Gerrit-Change-Number: 15545
Gerrit-PatchSet: 3
Gerrit-Owner: Mark Murawski <markm at intellasoft.net>
Gerrit-Reviewer: Friendly Automation
Gerrit-Reviewer: George Joseph <gjoseph at digium.com>
Gerrit-Comment-Date: Wed, 17 Mar 2021 14:54:51 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Gerrit-MessageType: comment
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20210317/630a0c2a/attachment.html>


More information about the asterisk-code-review mailing list