[ZBXNEXT-5466] Allow for "Custom on fail" also on LLD macros Created: 2019 Sep 24  Updated: 2021 May 19  Resolved: 2021 May 19

Status: Closed
Project: ZABBIX FEATURE REQUESTS
Component/s: Frontend (F), Server (S)
Affects Version/s: 4.2.6
Fix Version/s: None

Type: New Feature Request Priority: Minor
Reporter: Robin Roevens Assignee: Valdis Murzins
Resolution: Duplicate Votes: 0
Labels: lld, macro, macros
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Duplicate
duplicates ZBXNEXT-6252 Introduce an option to check macro pr... Closed

 Description   

It would be nice to also have a "Custom on fail" checkbox next to the LLD macro's in LLD with at least the possibility to discard the value or assign a predefined value to the macro.
I've come across a few REST API's where I need macro's extracted, but the required json path does not always exist in every array element used by LLD. In such a case I'm not interested in that array element and I'd like LLD to ignore those elements.
Currently the macro's that Zabbix fails to resolve due to such a missing jsonpath, are just not defined, but the item prototypes are still generated, with an unexpanded macro name for those macro's.
This can be "fixed" by setting a filter on those macro's that can have missing jsonpath's. In this case LLD works, but for each element without those required jsonpath's now an error is generated:

Cannot accurately apply filter: no value received for macro "{#MACRO}" json path '$.json.path'.

Which is a bit ugly when this is known behavior of the REST API that is being queried.



 Comments   
Comment by Oleksii Zagorskyi [ 2021 Jan 05 ]

ZBXNEXT-6252 looks like related.

Comment by Oleksii Zagorskyi [ 2021 May 19 ]

Let's close it as duplicate.

Generated at Tue Jul 22 08:58:06 EEST 2025 using Jira 9.12.4#9120004-sha1:625303b708afdb767e17cb2838290c41888e9ff0.