Zabbix Documentation 4.0

2.23.04.04.2 (current)In development:4.4 (devel)Unsupported:1.82.02.43.23.4

User Tools

Site Tools


manual:config:items:item

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
manual:config:items:item [2019/07/16 14:03]
martins-v formatting change
manual:config:items:item [2019/07/17 08:04] (current)
martins-v removing duplicated jsonpath examples
Line 61: Line 61:
 |//Left trim// ​ |Remove specified characters from the beginning of the value. ​ | |//Left trim// ​ |Remove specified characters from the beginning of the value. ​ |
 |//XML XPath// ​ |Extract value or fragment from XML data using XPath functionality.\\ For this option to work, Zabbix server must be compiled with libxml support.\\ Examples:\\ ''​number(/​document/​item/​value)''​ will extract ''​10''​ from ''<​document><​item><​value>​10</​value></​item></​document>''​\\ ''​number(/​document/​item/​@attribute)''​ will extract ''​10''​ from ''<​nowiki><​document><​item attribute="​10"></​item></​document></​nowiki>''​\\ ''/​document/​item''​ will extract ''<​item><​value>​10</​value></​item>''​ from ''<​document><​item><​value>​10</​value></​item></​document>''​\\ Note that namespaces are not supported.\\ Supported since 3.4.0. ​ | |//XML XPath// ​ |Extract value or fragment from XML data using XPath functionality.\\ For this option to work, Zabbix server must be compiled with libxml support.\\ Examples:\\ ''​number(/​document/​item/​value)''​ will extract ''​10''​ from ''<​document><​item><​value>​10</​value></​item></​document>''​\\ ''​number(/​document/​item/​@attribute)''​ will extract ''​10''​ from ''<​nowiki><​document><​item attribute="​10"></​item></​document></​nowiki>''​\\ ''/​document/​item''​ will extract ''<​item><​value>​10</​value></​item>''​ from ''<​document><​item><​value>​10</​value></​item></​document>''​\\ Note that namespaces are not supported.\\ Supported since 3.4.0. ​ |
-|//JSON Path// ​ |Extract value or fragment from JSON data using [[:​manual/​appendix/​items/​jsonpath|JSONPath functionality]].\\ (//Note// that only a simple subset of JSONPath functionality is supported before Zabbix 4.0.11.)\\ JSONPath can be specified using the dot notation:\\ ''​$.document.item[0].value''​\\ or the bracket notation:\\ ''​$['​document'​]['​item'​][0]['​value'​]''​\\ The former, dot notation, can be used only if object names consist of alphanumeric + underscore characters:​\\ ''​$.document.item_0.value''​\\ If object name contains other characters, e. g. blanks, dashes, you must use the bracket notation:\\ ''​$['​document'​]['​item 0'​]['​value-0'​]''​\\ Both notations can be mixed:\\ ''​$.document['​item'​][0].value''​\\ For both notations only direct paths to single objects are supported.\\ Extracting multiple values is not supported.\\ More examples:\\ ''​$.document.item.value''​ will extract ''​10''​ from ''<​nowiki>​{"​document":​{"​item":​{"​value":​ 10}}}</​nowiki>''​\\ ''​$.document.item''​ will extract ''<​nowiki>​{"​value":​ 10}</​nowiki>''​ from ''<​nowiki>​{"​document":​{"​item":​{"​value":​ 10}}}</​nowiki>''​\\ ''​$['​a document'​].item.value''​ will extract ''​10''​ from ''<​nowiki>​{"​a document":​{"​item":​{"​value":​ 10}}}</​nowiki>''​\\ ''​$.document.items[1].value''​ will extract ''​20''​ from ''<​nowiki>​{"​document":​{"​items":​[{"​value":​ 10}, {"​value":​ 20}]}}</​nowiki>''​\\ Supported since 3.4.0. ​ |+|//JSON Path// ​ |Extract value or fragment from JSON data using [[:​manual/​appendix/​items/​jsonpath|JSONPath functionality]].\\ (//Note// that only a simple subset of JSONPath functionality is supported before Zabbix 4.0.11.) ​ |
 |//Custom multiplier// ​ |Multiply the value by the specified integer or floating-point value.\\ Use this option to convert values received in KB, MBps, etc into B, Bps. Otherwise Zabbix cannot correctly set [[:​manual/​appendix/​suffixes|prefixes]] (K, M, G etc).\\ //Note// that if the item type of information is //Numeric (unsigned)//,​ incoming values with a fractional part will be trimmed (i.e. '​0.9'​ will become '​0'​) before the custom multiplier is applied.\\ Starting with Zabbix 2.2, using scientific notation is also supported. E.g. 1e+70. ​ | |//Custom multiplier// ​ |Multiply the value by the specified integer or floating-point value.\\ Use this option to convert values received in KB, MBps, etc into B, Bps. Otherwise Zabbix cannot correctly set [[:​manual/​appendix/​suffixes|prefixes]] (K, M, G etc).\\ //Note// that if the item type of information is //Numeric (unsigned)//,​ incoming values with a fractional part will be trimmed (i.e. '​0.9'​ will become '​0'​) before the custom multiplier is applied.\\ Starting with Zabbix 2.2, using scientific notation is also supported. E.g. 1e+70. ​ |
 |//Simple change// ​ |Calculate difference between the current and previous value.\\ Evaluated as **value**-**prev_value**,​ where\\ //value// - current value; //​prev_value//​ - previously received value\\ This setting can be useful to measure a constantly growing value. If the current value is smaller than the previous value, Zabbix discards that difference (stores nothing) and waits for another value.\\ Only one change operation per item is allowed. ​ | |//Simple change// ​ |Calculate difference between the current and previous value.\\ Evaluated as **value**-**prev_value**,​ where\\ //value// - current value; //​prev_value//​ - previously received value\\ This setting can be useful to measure a constantly growing value. If the current value is smaller than the previous value, Zabbix discards that difference (stores nothing) and waits for another value.\\ Only one change operation per item is allowed. ​ |