logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

__pmCheckAttribute - check value for a client connection attribute

C Synopsis

#include"pmapi.h"#include"libpcp.h"int__pmCheckAttribute(__pmAttrKeyattr,constchar*value);cc...-lpcp

Caveat

       This documentation is intended for internal Performance Co-Pilot (PCP) developer use.

       These  interfaces  are  not part of the PCP APIs that are guaranteed to remain fixed across releases, and
       they may not work, or may provide different semantics at some point in the future.

Description

       Connection attributes are exchanged between pmcd(1) and PCP client tools at the  start  of  the  protocol
       exchange.   They provide optional information relating to an individual connection, such as the name of a
       specific container that is under analysis by the client.

       __pmCheckAttribute verifies that the given attribute attr follows the expected syntax for  that  type  of
       attribute.   This  assists  with  the  prevention  of  malicious  content being accepted by pmcd as these
       attributes may subsequently be used in parsers or carried into structured output such as JSON format.

Name

__pmCheckAttribute - check value for a client connection attribute

Return Values

       When presented with  an  unrecognised  attribute  or  an  invalid  value  for  the  specified  attribute,
       __pmCheckAttribute  returns  a  negative  value  suitable  for reporting with pmErrStr(3).  Otherwise the
       return value is zero indicating success.

See Also

pmdbg(1), PMAPI(3) and pmErrStr(3).

Performance Co-Pilot                                   PCP                                   PMCHECKATTRIBUTE(3)

See Also