[Asterisk-code-review] res_pjsip: Add endpoint configuration -- log_subscription_error (asterisk[master])
Mark Murawski
asteriskteam at digium.com
Tue May 12 10:12:34 CDT 2020
Mark Murawski has posted comments on this change. ( https://gerrit.asterisk.org/c/asterisk/+/14405 )
Change subject: res_pjsip: Add endpoint configuration -- log_subscription_error
......................................................................
Patch Set 2:
(1 comment)
https://gerrit.asterisk.org/c/asterisk/+/14405/2/res/res_pjsip_exten_state.c
File res/res_pjsip_exten_state.c:
https://gerrit.asterisk.org/c/asterisk/+/14405/2/res/res_pjsip_exten_state.c@419
PS2, Line 419: ast_log(LOG_NOTICE, "Endpoint '%s' state subscription failed: "
: "Extension '%s' does not exist in context '%s' or has no associated hint\n",
: ast_sorcery_object_get_id(endpoint), resource, context);
> I agree that having the ability to control at a finer level log messages would be nice, as log level […]
Hi Joshua,
Fair enough. There is definitely a slippery slope, we could literally wind up with a setting for every single log line.
Sounds like I'm setting myself up for a big ole project...
In my own applications, we have a system-wide unique log 'token' For example, I would call this log token LOG_PJSIP_SUBSCRIPTION_FAILED. No other log line anywhere in the system would use this token other than for logging the same exact issue.
There are quite a few benefits for this.
- Future multi-language support for console logging
- Documentation: Users can search the wiki for a matching log token and find the reason for this log, and any other information regarding this log.
- Fully configurable logging for all users, turn on and off bitwise flags as needed for tracing/troubleshooting
- Mapping into a new flag-based structure would not pollute the configuration namespaces for which modules the logging comes from
_ Centralized configuration (probably logger.conf) to turn on and off individual log tokens
--
To view, visit https://gerrit.asterisk.org/c/asterisk/+/14405
To unsubscribe, or for help writing mail filters, visit https://gerrit.asterisk.org/settings
Gerrit-Project: asterisk
Gerrit-Branch: master
Gerrit-Change-Id: I5dff21c3c8ac3a3e3aefbd89053581fb90bc7018
Gerrit-Change-Number: 14405
Gerrit-PatchSet: 2
Gerrit-Owner: Mark Murawski <markm at intellasoft.net>
Gerrit-Reviewer: Friendly Automation
Gerrit-CC: Joshua Colp <jcolp at sangoma.com>
Gerrit-CC: Kevin Harwell <kharwell at digium.com>
Gerrit-Comment-Date: Tue, 12 May 2020 15:12:34 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Joshua Colp <jcolp at sangoma.com>
Comment-In-Reply-To: Kevin Harwell <kharwell at digium.com>
Comment-In-Reply-To: Mark Murawski <markm at intellasoft.net>
Gerrit-MessageType: comment
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20200512/0cdb11a5/attachment-0001.html>
More information about the asterisk-code-review
mailing list