[ZBX-7399] The Template Trigger Name does not appear in Action Conditions search list Created: 2013 Nov 18  Updated: 2017 May 30  Resolved: 2014 Jun 25

Status: Closed
Project: ZABBIX BUGS AND ISSUES
Component/s: Frontend (F)
Affects Version/s: 2.2.0
Fix Version/s: 2.2.4rc1, 2.3.2

Type: Incident report Priority: Major
Reporter: Areg Vrtanesyan Assignee: Unassigned
Resolution: Fixed Votes: 13
Labels: actions, conditions, unsquashable, usability
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Attachments: PNG File Action 001.PNG     PNG File Action 002.png     XML File Template AAA JMX.xml     PNG File bug3.png     PNG File trigger.png     PNG File trigger.png     PNG File trigger.png    
Issue Links:
Duplicate
duplicates ZBX-8225 Missed multiselect cleanup Closed
is duplicated by ZBXNEXT-1964 Improve template selection form Closed
is duplicated by ZBXNEXT-2115 Actions -> new trigger dropdown list ... Closed
is duplicated by ZBX-7635 20 search results limit Closed
is duplicated by ZBX-8044 Unable to select triggers in actions ... Closed
is duplicated by ZBX-8106 Can't select trigger for specific hos... Closed

 Description   

Hi

I got a problem after upgrading to the latest 2.2.0 version with the Action Conditions.
Previously it was possible to select the Trigger from the list manually so I can choose which Template trigger I would like to use in Actions.

Now as the rules are changed I can't find my trigger using the search and I am not sure what is wrong with the Template or Trigger configurations.

Regards,
Areg



 Comments   
Comment by richlv [ 2013 Nov 18 ]

please, verify that trigger is actually available for current user. also, post trigger expression here

Comment by Areg Vrtanesyan [ 2013 Nov 18 ]

Hi

I am a "Zabbix Super Admin" and it should be available for me.

Here is the expression:

{Template JMX:jmx["java.lang:type=Runtime",Uptime].nodata(240)}=1

Just would like to mention that this is JMX item.

Regards,
Areg

Comment by richlv [ 2013 Nov 19 ]

initial tests seem to work just fine for me - could you please also clarify a bit more on what exactly are you trying to add as a condition. preferably, provide detailed steps to reproduce the problem

Comment by Oleksii Zagorskyi [ 2013 Nov 19 ]

One user on forum (on Russian thread https://www.zabbix.com/forum/showthread.php?p=140621#post140621) tried to type host name or full trigger name without macro {HOST.NAME} which is not supported.

Btw, if I have tons of triggers like "Zabbix agent on {HOST.NAME} is unreachable for 5 minutes" would it be easy to scroll and find required host:trigger in filter results ?

Comment by Areg Vrtanesyan [ 2013 Nov 19 ]

Hi

I have attached my template and two screenshots explaining what I am trying to do.

From my understanding, and it was working for very long time in Zabbix previous versions the Action can be configured with the Template Trigger in it and it will capture all the assigned hosts events.

Now I have the "Report JMX Problems - Not Running" Action with the condition shown in first screenshot.

On the second one I am trying to add the same trigger from "Template AAA JMX" template but with no success.

In previous version it was easy to just select and it was more convenient as sometimes you dont remember all the names but know the Template, so selecting was quicker rather than search now as I need to go back to the Templates list and check the trigger name to search it.

So the feature is good but it can work much better with the combination of selecting too.

Regards,
Areg

Comment by Oleksii Zagorskyi [ 2013 Nov 19 ]

The same impression (need to remember a template/trigger name) as Areg's is described by one zabbix user in that russian forum thread.

I'm personally not sure what is better - old or new method for selections.

Comment by richlv [ 2013 Nov 19 ]

i'm confused - is this issue about a total inability to find the trigger, about inability to search expanded trigger names or inability to list the triggers ?

if the latter, then it's dupe of ZBXNEXT-1964

Comment by Areg Vrtanesyan [ 2013 Nov 19 ]

I think it should be the double choice - search and selection together.

If you have small installation search will be fine, in big installations with thousand monitored hosts search is mostly nightmare.

Regards,
Areg

Comment by Areg Vrtanesyan [ 2013 Nov 19 ]

richlv added a comment - 2013 Nov 19 12:18
i'm confused - is this issue about a total inability to find the trigger, about inability to search expanded trigger names or inability to list the triggers ?
if the latter, then it's dupe of ZBXNEXT-1964

Hi

This is about the problem that after upgrading to the version 2.2.0 many of the triggers become "invisible" in the Action Conditions when selecting exact trigger.
So this is about inability to find the trigger in Action Condition.

We spoke about search and selecting because even the search is nice feature it was more convenient in old version to select the trigger as for me.

Regards,
Areg

Comment by richlv [ 2013 Nov 20 ]

ah, that's exactly what zalex described... no ability to search by expanded macro names

yeah, i guess we have a bunch of usability problems to solve here

edit :
a) you can not search by template or host name in there, you have to search by trigger name only (even though template or host name is displayed later)
b) you can not search by resolved trigger name, you have to search by literal one (like "{HOST.NAME} is not"

this will be improved. somehow

Comment by Areg Vrtanesyan [ 2013 Nov 21 ]

The last somehow sounds very optimistic ...

Comment by Areg Vrtanesyan [ 2013 Dec 05 ]

Hi

Any progress update on this ?

Comment by Areg Vrtanesyan [ 2013 Dec 09 ]

Hi

I am just wondering is there are anyone else who noticed the same?

Regards,
Areg

Comment by Ale Brusotti [ 2013 Dec 16 ]

Dear all,

we had the same issue but now we have found an other way to use this important feature

the problem it seems to be the presence in the trigger name of the variable "{HOSTNAME}"

1. delete the variable "{HOSTNAME}" from the trigger description
2. Configure the trigger as below (replace "XXXX" with the application name)

Label Name Action
(A) Template = EZ_XXXX_Client
(B) Trigger name like XXXX Client

"XXXX Client" is the trigger name

Comment by Stepan Razenkov [ 2014 Jan 13 ]

Hi all,

Still experience the same issue while adding new condition under "Configuration of Actions".
Workaround described by Ale is working, but I believe it is not the way out.

Comment by Areg Vrtanesyan [ 2014 Feb 26 ]

Hi All

Any chance that fix will be available for test in any RC release - 2.2.3rcX?

Regards,
Areg

Comment by richlv [ 2014 Mar 16 ]

i'm terribly sorry about this regression. i've faced it myself several times.
unfortunately, i'm not aware of any plans to fix it.

interestingly, there are 3 votes only here - maybe it is worth increasing the awareness about this.

Comment by Ryan Armstrong [ 2014 Mar 20 ]

This is a huge issue for us with 5k+ devices (upvoted!), all of which have a 'Ping test failed' trigger applied by a single template.
I played around in the source to look for obvious answers but nothing reveals itself to me.
I think the following could be useful solutions:
1. Add a host/template filter before the trigger multiselect. Eg. Select a host/template, then a trigger from that host?
2. Allow for the desired host name to be included in the ajax search criteria?
3. Lightbox dialog with search criteria?
4. Macro expansion would help but not be ideal as we would still have a huge number of triggers with {HOST.NAME} in them.

Comment by Ryan Armstrong [ 2014 Mar 20 ]

For those in need, I replaced the multiselect with a popup. I need some more rigorous testing before being confident but it seems pretty fool proof.

include/views/configuration.action.edit.php[166]
        case CONDITION_TYPE_TRIGGER:
                /*
                $condition = new CMultiSelect(array(
                       'name' => 'new_condition[value][]',
                       'objectName' => 'triggers',
                       'objectOptions' => array(
                               'editable' => true
                       ),
                       'defaultValue' => 0
                ));
                */
                $conditionFormList->addItem(new CVar('new_condition[value]', '0'));
                $condition = array(
                        new CTextBox('trigger', '', ZBX_TEXTBOX_STANDARD_SIZE, 'yes'),
                        SPACE,
                        new CButton('btn1', _('Select'),
                                'return PopUp("popup.php?srctbl=triggers&srcfld1=triggerid&srcfld2=description'
                                        .'&dstfrm=' . $actionForm->getName() . '&dstfld1=new_condition_value&dstfld2=trigger", 450, 450);',
                                'link_menu'
                        )
                );
Comment by Areg Vrtanesyan [ 2014 Mar 31 ]

Hi

Seems even if the Fix Version is telling 2.2.3rc1 it it not in release notes - http://www.zabbix.com/rn2.2.3rc1.php

Regards,
Areg

Comment by Oleksii Zagorskyi [ 2014 Mar 31 ]

Does it fixed to be included to release notes ?
No !

Comment by richlv [ 2014 Mar 31 ]

we had really hoped to fix it for 2.2.3, but unfortunately that did not happen

Comment by hullzabbix [ 2014 Apr 14 ]

This is quite a bad one. We can't add any actions we need! We've only got ~200 hosts, but lots of ping checks.

Comment by hullzabbix [ 2014 Apr 14 ]

Thanks for the code Ryan, the popup worked. At least we can work around this now.

It would be nice in the fixed version to have an option to search OR select manually.

Comment by Oleg Egorov (Inactive) [ 2014 Apr 28 ]

Fixed for Configuration->Hosts in svn://svn.zabbix.com/branches/dev/ZBX-7399 r45248

Comment by Pavels Jelisejevs (Inactive) [ 2014 May 10 ]

(1) Please review my changes in r45348.

oleg.egorov CLOSED

Comment by Pavels Jelisejevs (Inactive) [ 2014 May 10 ]

(2) [trunk] The public methods of the multiselect plugins should be redesigned according to the jQuery standards.

oleg.egorov RESOLVED IN r46175

oleg.egorov And reviewed changes by Pavel in r46212

CLOSED

Comment by Pavels Jelisejevs (Inactive) [ 2014 May 10 ]

(3) Unnecessary space between the multiselect and the "Select" button.

oleg.egorov RESOLVED IN r45366

jelisejev CLOSED.

Comment by Pavels Jelisejevs (Inactive) [ 2014 May 10 ]

(4) The "existed_templates" parameter must be renamed into something more generic. It should also contain only IDs of elements, without the names.

oleg.egorov RESOLVED IN r45366

jelisejev Just noticed that the "popup.php" file also has an "excludeids" parameter, which does the same thing. It would be better to use it instead. The only different is that "excludeids" doesn't display an element in the list at all. It should be displayed, but disabled.

oleg.egorov RESOLVED IN r45377

jelisejev It's enough to pass the IDs as values, there's no need to pass them in keys as well.

oleg.egorov RESOLVED IN r45731

jelisejev I've made some changes in r45848, please review.

oleg.egorov CLOSED

Comment by Pavels Jelisejevs (Inactive) [ 2014 May 10 ]

(5) The current HTML structure seems inappropriate since it treats the "Select" button and the multiselect input as two independent elements. It would be easier to work with if it was rendered as a single element. Something like:

<div class="multiselect-wrapper">
    <div class="multiselect"></div>
    <input class="select-popup" />
</div>

It would also provide some context for CSS rules: ".selectPopup { float: right; }" would become ".multiselect-wrapper .select-popup { float: right; }" which is easier to work with.

Note, that "selectPopup" must be corrected to "select-popup".

oleg.egorov RESOLVED IN r45366

jelisejev CLOSED.

Comment by Pavels Jelisejevs (Inactive) [ 2014 May 10 ]

(6) The "Select" button label is not translated. The label should be passed using the "labels" parameter.

oleg.egorov RESOLVED IN r45366

jelisejev The translated label must also be passed via the $.multiSelectHelper() method.

oleg.egorov RESOLVED IN r45377

jelisejev CLOSED.

Comment by Oleg Egorov (Inactive) [ 2014 May 12 ]

(7) No translatable strings changed.

jelisejev CLOSED.

Comment by Pavels Jelisejevs (Inactive) [ 2014 May 20 ]

(8) Rename the CMultiSelect ID parameter into "wrapperId" so it wouldn't be confused with the multiselect JS helper "id" parameter. It must also be documented.

oleg.egorov RESOLVED IN r45731

jelisejev Documentation hasn't been updated.

oleg.egorov IN r45893 was removed wrapperId

jelisejev CLOSED.

Comment by Pavels Jelisejevs (Inactive) [ 2014 May 20 ]

(10) Host mass update template linking is not working.

oleg.egorov RESOLVED IN r45731

jelisejev I've changed the name of the changebox in 45850. Adding the "div" suffix is very confusing.

oleg.egorov CLOSED

Comment by Pavels Jelisejevs (Inactive) [ 2014 May 20 ]

(11) Some issues when selecting a target for a remote command action operation:

  1. the dropdown list is displayed incorrectly
  2. when selecting a host group it is added not only to the multiselect but also to the target list.

oleg.egorov RESOLVED IN r45828

jelisejev The first problem has not been resolved.

oleg.egorov RESOLVED IN r45893

jelisejev The same problem exists when selecting a template for a "Link to template", host groups "Add to host group" and other places.

oleg.egorov RESOLVED IN r45945

jelisejev I've committed a different fix in 46076, it's more consistent with other similar places. Please review.

oleg.egorov CLOSED

Comment by Pavels Jelisejevs (Inactive) [ 2014 May 20 ]

(12) Some issues in the map element configuration form:

  • The "Select" button is off.
  • Add a screen element, open it's form, close it and open again: there will be two "Select" buttons displayed.

oleg.egorov RESOLVED IN r45828

jelisejev I've managed to fix the "select" button in r45861, please review. But another problem remains: when I open a host element, switch to host group and then back to host, multiselect is initialized once again and creates another wrapper and select button.

oleg.egorov FIXED IN r45866

jelisejev This fix won't do. You shouldn't try to remove these specific parts of the multiselect. Try initializing the multiselect when the form is displayed instead of after switching the element type. The same thing for "jQuery('.multiselect-wrapper').remove();" in changeOpCmdTarget().

oleg.egorov RESOLVED IN r45945

jelisejev Now when I try to save a host element, I get the following error: "Host is not selected." I also cannot save the map in IE.

oleg.egorov RESOLVED IN r46023

jelisejev I've made a small change in r46071, please review.

oleg.egorov CLOSED

Comment by Pavels Jelisejevs (Inactive) [ 2014 May 20 ]

(13) The "empty" button shouldn't be displayed in the trigger selection popup in action condition configuration.

oleg.egorov Same issue will be fixed for applications

RESOLVED IN r45731

jelisejev CLOSED.

Comment by Pavels Jelisejevs (Inactive) [ 2014 May 20 ]

(14) In configuration.action.edit.js the wrapper div must be created by the multiSelectHelper() the same way as in the CMultiSelect class. Same thing for configuration.sysmaps.js.php.

oleg.egorov RESOLVED IN r45828

jelisejev After some thought that it's would be better to create the wrapper inside the multiSelect() function and remove it from the PHP and JS helpers.

oleg.egorov RESOLVED IN r45893

jelisejev CLOSED.

Comment by Pavels Jelisejevs (Inactive) [ 2014 May 26 ]

(15) When I try to select a trigger for a map element, an error is displayed: "Field "sysmapid" is mandatory."

oleg.egorov RESOLVED IN r45900

jelisejev CLOSED.

Comment by Pavels Jelisejevs (Inactive) [ 2014 Jun 02 ]

Fixed for 2.2 is TESTED. If (11) and (12) are OK you can merge.

Don't forget to fix (2) before merging to trunk.

Comment by Alexander Vladishev [ 2014 Jun 02 ]

(16) It is possible to add host groups to a disabled multiselect (Dashboard configuration form)

oleg.egorov RESOLVED IN r46079, r46082

sasha CLOSED

Comment by Oleg Egorov (Inactive) [ 2014 Jun 04 ]

Resolved for trunk and fixed ZBX-8225 in r46175

Comment by richlv [ 2014 Jun 04 ]

(17) let's verify the fix for ZBX-8225 specifically

jelisejev Verified, everything OK. CLOSED.

Comment by Pavels Jelisejevs (Inactive) [ 2014 Jun 05 ]

(18) I've refactored the code so that it would conform to jQuery coding standards in r46212, please review.

oleg.egorov CLOSED

Comment by Pavels Jelisejevs (Inactive) [ 2014 Jun 05 ]

(19) I've also corrected the "Select" button for the application filter in 46216.

oleg.egorov CLOSED

Comment by Oleg Egorov (Inactive) [ 2014 Jun 05 ]

FIXED IN 2.2.4rc1 r46119 AND IN trunk(2.3.2) r46222

Comment by Pavels Jelisejevs (Inactive) [ 2014 Jun 19 ]

(20) This caused a regression in the trunk. It's impossible to select an application in the filter of the Monitoring -> Triggers page.

oleg.egorov RESOLVED IN r46670

jelisejev CLOSED.

Comment by Oleg Egorov (Inactive) [ 2014 Jun 25 ]

(21) Don't work trigger dependencies in mass update

RESOLVED IN r46789

jelisejev CLOSED.

Comment by Pavels Jelisejevs (Inactive) [ 2014 Jun 25 ]

(22) [trunk] Another regression: cannot add a trigger to a link indicator in map configuration. Both the links and the submit buttons aren't working.

oleg.egorov RESOLVED IN r46826

jelisejev CLOSED.

Comment by Pavels Jelisejevs (Inactive) [ 2014 Jun 26 ]

TESTED.

Comment by Oleg Egorov (Inactive) [ 2014 Jun 26 ]

FIXED IN trunk(2.3.2) r46862

Comment by Ryan Armstrong [ 2014 Jul 08 ]

Just installed v2.2.4 and the fix is absolutely beautiful! Thanks very much for addressing this issue so quickly.

Comment by Martins Valkovskis [ 2014 Dec 18 ]

(23) Reflected in documentation:

RESOLVED.

oleg.egorov Reviewed. CLOSED

Generated at Thu Apr 18 11:31:31 EEST 2024 using Jira 9.12.4#9120004-sha1:625303b708afdb767e17cb2838290c41888e9ff0.