[ZBX-3137] undefined variables when deleting an application used in templated web scenario Created: 2010 Oct 25  Updated: 2017 May 30  Resolved: 2010 Nov 04

Status: Closed
Project: ZABBIX BUGS AND ISSUES
Component/s: Frontend (F)
Affects Version/s: None
Fix Version/s: 1.8.4

Type: Incident report Priority: Blocker
Reporter: richlv Assignee: Unassigned
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Attachments: PNG File scenario-application.png    

 Description   

1. it is possible to create web scenarios for templates - probably should not be possible;

2. deleting an application used in such a web scenario results in undefined variable errors :

Undefined variable: host[/usr/local/apache2/htdocs/trunk/include/hosts.inc.php:1394]
Undefined variable: app[/usr/local/apache2/htdocs/trunk/include/hosts.inc.php:1394]
Application ":" used by item "Download speed for step 'df' of scenario 'zz'"
Application "Template_Linux:zz" used by scenario "zz"
[ CApplication::delete ] Cannot delete application



 Comments   
Comment by Konstantin Buravcov (Inactive) [ 2010 Oct 28 ]

DEV branch: ZBX-3137

Removed templates from host menus in web scenarios;
Button "Create scenario" is now shown disabled when no host is selected with additional hint.

Since it's not possible to use template applications in scenarios, bug is not actual anymore

Comment by Konstantin Buravcov (Inactive) [ 2010 Oct 29 ]

For 1.8: ZBX-3137-1.8

Comment by Konstantin Buravcov (Inactive) [ 2010 Oct 29 ]

Seems that "Undefined variable" is still present when trying to delete host application used in scenario.

Comment by Konstantin Buravcov (Inactive) [ 2010 Nov 02 ]

Changes made:

  • When deleting a template, that has an app used in web scenario, the app is unlinked but not deleted and warning is shown to the user.
  • Template app can't be deleted if it is used by web scenario
  • Some UI improvements

Merged: branches/1.8 15204

Comment by Aleksandrs Saveljevs [ 2010 Nov 03 ]

Errors still exist. Steps to reproduce:

(1) Create application A on host H.
(2) Create scenario on H in application A.
(3) Create template T1.
(4) Create template T2 and link that to template T1.
(5) Create application A in template T2.
(6) Link template T1 to host H.
(7) Delete application A from template T2.
(8) Go to applications for host H.
(9) Observe scenario-application.png.

Also, while according to the new logic application A should stay on host H after step (7), it should be removed from template T1.

Comment by Konstantin Buravcov (Inactive) [ 2010 Nov 04 ]

Fixed for 1.8. For trunk this one is fixed in another issue by Aleksei.

Generated at Thu Apr 25 00:02:17 EEST 2024 using Jira 9.12.4#9120004-sha1:625303b708afdb767e17cb2838290c41888e9ff0.