Ad Widget

Collapse

Suggested change to process_data in function.c

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • hwmpd
    Junior Member
    • May 2005
    • 3

    #1

    Suggested change to process_data in function.c

    Alexei,

    Active checks sent by a remote agent are processed by the trapper in the
    routine process_data (in the module function.c). If an active check returns
    "ZBX_NOTSUPPORTED" (instead of a value), the error is logged, but then
    the value (which would be the result of converting the error string to double)
    appears to be entered into the database anyway (since the code in process_data
    does not exit early on a NOTSUPP error).

    I'd like to suggest that the code in process_data look more like the code in
    get_values (in server.c) - so that on error conditions (like ZBX_NOTSUPPORTED)
    data is not put in the database. Also, it would be nice if process_data would
    recognize "ZBX_ERROR" as an additionally valid string that could be returned on
    active check so that a temporary error on an active check could be distinguished
    from the more permanent "not supported" condition (where an agent really cannot
    perform that check ever on the remote machine).

    Thank you.
Working...