View Issue Details
| ID | Project | Category | View Status | Date Submitted | Last Update | 
|---|---|---|---|---|---|
| 0025391 | mantisbt | plug-ins | public | 2019-01-28 05:34 | 2019-02-03 09:21 | 
| Reporter | c2pil | Assigned To | |||
| Priority | normal | Severity | feature | Reproducibility | always | 
| Status | new | Resolution | open | ||
| Product Version | 2.15.0 | ||||
| Summary | 0025391: Write logs in a log file by plug-ins. | ||||
| Description | I use Mantis with some plugins. Currently, when my plugins logs events, they are in a single file (with current Mantis logs). I would like to have one log file by plugins when I call the function "log_event". Is it possible to add a function "log_event_plugins" for example, which will generate a log file by plugins ? | ||||
| Steps To Reproduce | Configure Mantis to log in a file : $g_log_destination = 'file:/PATHFILE' | ||||
| Tags | No tags attached. | ||||
| I don't really see the added value of a new feature to log plugin events to a separate file. The logging API already records the plugin name in the log file, and you can call existing function plugin_log_event(). If this is not sufficient for your purposes, then you can write a plugin that will hook into the EVENT_LOG event. | |
| Thanks for your answer. I work with Mantis on a restricted network and where I do not have access to apache logs. Some of our plugins do a lot of processing, which is why we need to have a log file per plugin (to debug ..). In addition, is it possible to configure log rotation in Mantis? Thanks again | |
| 
 There is no need to have access to the apache logs. My point was that you can just use the mantisbt log with   | |
| 
 Not from within Mantis, and this is not a feature we're planning to add. I suggest you use an OS-specific solution to achieve that, for example logrotate on linux. | |
