[ZBX-4563] Problems with user defined macros Created: 2012 Jan 19 Updated: 2017 May 30 Resolved: 2012 Feb 27 |
|
Status: | Closed |
Project: | ZABBIX BUGS AND ISSUES |
Component/s: | API (A), Frontend (F) |
Affects Version/s: | 1.9.8 (beta) |
Fix Version/s: | 2.0.0rc1 |
Type: | Incident report | Priority: | Critical |
Reporter: | Alexander Vladishev | Assignee: | Unassigned |
Resolution: | Fixed | Votes: | 0 |
Labels: | usermacros | ||
Remaining Estimate: | Not Specified | ||
Time Spent: | Not Specified | ||
Original Estimate: | Not Specified | ||
Environment: |
trunk, r24888 |
Attachments: | admin.jpg distance-between-macros.jpg super-admin.jpg | ||||||||
Issue Links: |
|
Description |
Some problems found with user macros: 1. host and template level macros:
2. template level macros:
3. the source code for template/host and global level macros is very different; it should be unified 4. the validation order of macros isn't logical 5. in API there aren't some checks
6. error messages violates coding style; for example: |
Comments |
Comment by Pavels Jelisejevs (Inactive) [ 2012 Feb 07 ] |
We've discussed it with Vedmak and Eduard, and decided, that from now on, each public API method will have it's own validator, instead of a single monstrous checkInput-like method. Each validator will consist of multiple, mostly independent checks. That way the validation process will be clearer and more flexible. RESOLVED. <Eduard> CLOSED |
Comment by richlv [ 2012 Feb 08 ] |
(7) api documentation doesn't seem to be updated (both individual method pages and http://www.zabbix.com/documentation/2.0/manual/appendix/api/changes_1.8_-_2.0 ) <pavels> Yeah, I'll update the docs as soon as the fix is reviewed and tested. <pavels> Updated the changes section http://www.zabbix.com/documentation/2.0/manual/appendix/api/changes_1.8_-_2.0 and the API docs http://www.zabbix.com/documentation/2.0/manual/appendix/api/usermacro?&#methods <Sasha> CLOSED |
Comment by Eduards Samersovs (Inactive) [ 2012 Feb 14 ] |
(8) After saving host with user macros, macros will doubles (if user is not Super Admin). <pavels> RESOLVED. |
Comment by Eduards Samersovs (Inactive) [ 2012 Feb 20 ] |
(9) Duplicate "form_refresh" variable in administration->general->user macros page <pavels> RESOLVED. |
Comment by Eduards Samersovs (Inactive) [ 2012 Feb 20 ] |
(10) Typo in message: Macro "%1$s is not unique." <pavels> RESOLVED. |
Comment by Pavels Jelisejevs (Inactive) [ 2012 Feb 20 ] |
(11) Permission checks should be made prior to everything else. <pavels> RESOLVED. |
Comment by Eduards Samersovs (Inactive) [ 2012 Feb 20 ] |
(12) Login as common Admin user. Edit some host where exist {$A} and {$B}. Create {$C} and delete {$B} - error message is shown.. <pavels> RESOLVED. |
Comment by Eduards Samersovs (Inactive) [ 2012 Feb 22 ] |
(13) Global macros ordering is jumping after saving. <pavels> RESOLVED. |
Comment by Alexander Vladishev [ 2012 Feb 22 ] |
(14) in fields, created dynamically an 'id' property are missing. value: button: <pavels> RESOLVED. |
Comment by Alexander Vladishev [ 2012 Feb 22 ] |
(15) Very strange SQL requests while saving macros 5 macros updated https://support.zabbix.com/secure/attachment/18100/super-admin.jpg <Sasha> CLOSED |
Comment by Alexander Vladishev [ 2012 Feb 24 ] |
Great work! Successfully tested. Don't forget to update API documentation. |
Comment by Alexander Vladishev [ 2012 Feb 27 ] |
Related issue: |
Comment by Pavels Jelisejevs (Inactive) [ 2012 Feb 27 ] |
Merged to trunk r25614. |
Comment by Alexander Vladishev [ 2012 Feb 27 ] |
(16) Please change validateCreate() function to protected. <pavels> CLOSED. |
Comment by Pavels Jelisejevs (Inactive) [ 2012 Feb 27 ] |
CLOSED. |