PMIPUTMARK(3)

πŸ’– PMIPUTMARK(3) πŸ’–

okay bestie, gather round, because today we're talking about pmiPutMark from the Performance Co-Pilot library functions manual β€” aka the little function that writes a <mark> record to a PCP archive, and honestly? it's giving boundary-setting queen. ✨


🌸 NAME 🌸

pmiPutMark β€” write a <mark> record to a PCP archive πŸŽ€


✨ C SYNOPSIS ✨

#include <pcp/pmapi.h>
#include <pcp/import.h>

int pmiPutMark(void);

cc ... -lpcp_import -lpcp

πŸ¦‹ Perl SYNOPSIS πŸ¦‹

use PCP::LogImport;

pmiPutMark();

🌈 Python SYNOPSIS 🌈

from pcp import pmi

log.pmiPutMark()

πŸ‘‘ DESCRIPTION πŸ‘‘

so here's the tea, bestie πŸ“. As part of the Performance Co-Pilot Log Import API (peep LOGIMPORT(3) for the full lore), pmiPutMark writes a <mark> record to the current PCP output archive. no cap.

You need this when there's a temporal discontinuity between the current input source and the next input source (if there even is one), and it should be called after the final call to pmiWrite(3) for the current input. literally after. don't do it before, that's not the vibe. πŸ™ˆ

And if there's no next input to be processed, or no temporal gap between sources? then the <mark> record is not required. you can just chill. πŸ’…

The <mark> record is used to signify a temporal gap β€” so that when you're replaying the output PCP archive, interpolation of metric values should not be performed between the last timestamp in the current input source and the first timestamp in the next input source. i.e. across the <mark> record. πŸš«πŸ“ˆπŸš«

think of it like: no, you cannot smooth over the gap, the gap is real, respect the boundary periodt. 😭

πŸ’€ DIAGNOSTICS πŸ’€

pmiPutMark returns zero on success, else a negative value that can be turned into an error message by calling pmiErrStr(3). so if it's mad at you, ask pmiErrStr(3) what's wrong. communication is key. 🫢


πŸ”₯ SEE ALSO πŸ”₯


Performance Co-Pilot ✨ PMIPUTMARK(3) β€” that's the whole page bestie, go forth and mark those temporal gaps, ily, mwah πŸ’–πŸŽ€πŸ¦‹

πŸ“¦ where this page comes from