View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0021791 | mantisbt | plug-ins | public | 2016-10-09 16:00 | 2016-10-23 11:44 |
Reporter | noizeg | Assigned To | atrol | ||
Priority | normal | Severity | major | Reproducibility | always |
Status | closed | Resolution | no change required | ||
Product Version | 1.3.1 | ||||
Summary | 0021791: Constantly increasing Apache error.log while using event_signal in project_api. | ||||
Description | If you add event_signal(...) inside project_get_field function in project_api.php, this will add a lot of calls to | ||||
Steps To Reproduce |
| ||||
Tags | No tags attached. | ||||
noizeg, This is not a bug or feature request for MantisBT (you are asking for help on how to deal with problems you introduced by changing original source of MantisBT). I am therefore resolving this issue as "no change required". Please use the forums, the mantisbt-help mailing list or IRC to get support on customizing and using MantisBT (refer to http://www.mantisbt.org/support.php for links and further details). |
|
Hi Atrol, |
|
This bug tracker is used to track bugs in delivered code of MantisBT. It is not used as a support channel.
|
|
Documentation explains how to declare new event, from within a plugin, to be hooked by other plugins. Atrol's response is right, probably it's an error on your side, which is not the subject of a bug report. |
|
Just to get you going, core events are declared in file events_inc.php |
|
Thanks for reply. I agree that it's not as critical as I thought. However, I have a lot of different changes in core api, but only project_api raises UNDECLARED for custom plugin events, that's why I still think it's a design issue, won't it be logically correct to declare all plugin events at the same time as core events? |
|
then the fact that it worked in other places is actually an accident...
No... Your dependency injection is reversed. Core cannot depend on a plugin, by definition, and by design... The existence of a way to declare events by a plugin was introduced because the main point of plugin development is to NOT modify the application source. By this principle, the only place where you can use a plugin-defined event, is from another plugin. Anything else, is unsupported |
|
Oh, so that's how it is. Got it, thanks. |
|
@cproensa, I think that's a pretty good explanation, which might be worth adding to the relevant section in the docs / dev guide. |
|