View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0022053 | mantisbt | plug-ins | public | 2016-12-18 14:31 | 2017-10-08 23:52 |
Reporter | cproensa | Assigned To | cproensa | ||
Priority | normal | Severity | feature | Reproducibility | have not tried |
Status | closed | Resolution | fixed | ||
Product Version | 1.3.4 | ||||
Target Version | 2.7.0 | Fixed in Version | 2.7.0 | ||
Summary | 0022053: Implement logging functionality for plugins | ||||
Description | Plugins should have a standard way of log messages to mantis standard log. Currently, logging_api provides log_event(), but this uses the standard defined log levels, eg: LOG_FILTERING, LOG_EMAIL, etc The proposal is: 1) As a first step:
2) A second step: | ||||
Tags | No tags attached. | ||||
+1 for the first step. Regarding 2), I think it would be worth considering in a wider refactoring of how we handle logging. Currently we have several log categories, that can be switched ON/OFF individually. IMO we should have a more detailed way of defining the log level (e.g. error, warning, info, debug...), following standard such as PSR-3 [1] This would allow us to get rid of LOG_EMAIL "sub-categories" like LOG_EMAIL_RECIPIENT and LOG_EMAIL_VERBOSE for example. |
|
MantisBT: master 075369ab 2017-08-20 10:48 Committer: dregad Details Diff |
Add logging functionality for plugins - Create a new loglevel LOG_PLUGIN to write logs specifically from plugins. - Add function plugin_log_event() to wrap the log call for plugins. Fixes: 0022053 |
Affected Issues 0022053 |
|
mod - config_defaults_inc.php | Diff File | ||
mod - core/constant_inc.php | Diff File | ||
mod - core/logging_api.php | Diff File | ||
mod - core/plugin_api.php | Diff File | ||
mod - docbook/Admin_Guide/en-US/config/logging.xml | Diff File |