1PMIPUTLABEL(3) Library Functions Manual PMIPUTLABEL(3)
2
3
4
6 pmiPutLabel - add labels to the output archive
7
9 #include <pcp/pmapi.h>
10 #include <pcp/import.h>
11
12 int pmiPutLabel(unsigned int type, unsigned int id, unsigned int
13 instance, const char *name, const char *value)
14
15 cc ... -lpcp_import -lpcp
16
18 use PCP::LogImport;
19
20 pmiPutLabel($type, $id, $instance, $name, $value);
21
23 As part of the Performance Co-Pilot Log Import API (see LOGIMPORT(3)),
24 pmiPutLabel adds a label for the global context or for a given domain,
25 cluster, item, instance domain or instance.
26
27 The type must be one of PM_LABEL_CONTEXT, PM_LABEL_DOMAIN, PM_LA‐
28 BEL_CLUSTER, PM_LABEL_ITEM, PM_LABEL_INDOM, or PM_LABEL_INSTANCES.
29
30 If type is PM_LABEL_CONTEXT, then id and instance are ignored. Other‐
31 wise, id should match a domain, cluster, metric or instance domain de‐
32 fined earlier in a call to pmiAddMetric(3).
33
34 If type is PM_LABEL_INSTANCES, then instance should match an instance
35 number of the selected domain. Otherwise instance is ignored.
36
37 name is a string containing the name of the label to be added.
38
39 value is a string containing the value of the label to be added.
40
41 No data will be written until pmiWrite(3) is called, so multiple calls
42 to pmiPutLabel are typically used to accumulate several labels before
43 calling pmiWrite(3).
44
46 pmiPutLabel returns zero on success else a negative value that can be
47 turned into an error message by calling pmiErrStr(3).
48
50 LOGIMPORT(3), pmiAddInstance(3), pmiAddMetric(3), pmiErrStr(3), pmiPu‐
51 tResult(3), pmiPutValue(3), pmiPutValueHandle(3), pmiPutText(3) and
52 pmiWrite(3).
53
54
55
56Performance Co-Pilot PMIPUTLABEL(3)