Uploaded image for project: 'ZABBIX FEATURE REQUESTS'
  1. ZABBIX FEATURE REQUESTS
  2. ZBXNEXT-8813

Support for values in scientific notation for numeric unsigned data type

XMLWordPrintable

    • Icon: Change Request Change Request
    • Resolution: Unresolved
    • Icon: Minor Minor
    • None
    • 6.0.23, 6.4.8
    • Server (S)
    • None

      It's very common that Prometheus data have values in scientific notation even if that's not really necessary, for example some metrics might look like this:

      # HELP minio_node_drive_free_inodes Free inodes on a drive
      # TYPE minio_node_drive_free_inodes gauge
      minio_node_drive_free_inodes{drive="/mnt/disk1/minio",server="minio-01.example.com:9000"} 5.242839e+06

      Such metrics will fit the UInt64 data type, but if you'll try to set the item type to "Numeric (unsigned)", and test the Prometheus pattern in preprocessing steps for the item, it will treat the value as a string and not a number:

      So we either have to use the "Float" type for these to be automatically converted, or use some preprocessing: for example you can multiply the value by "1" before putting it into DB and it will work fine:

      Using float is an overkill in such cases and probably it would be better to add the automatic conversion for "Numeric (unsigned)" too and only then check if value actually fits the UInt64, because workarounds with additional preprocessing look odd as well.

            wiper Andris Zeila
            drasikhov Denis Rasikhov
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: