Hi, Marko -
> >> - how would you use the API with non-leaf PMNS nodes?
> [...]
> Do you think something like below would be achievable or how would you
> deal with N pmExtendFetchGroup_item calls in Python?
> [...]
> atoms = []
> metrics = []
> def add_metric(metric):
> metrics.append(metric)
> pmExtendFetchGroup_item(pmfg, metric, None, None, atoms, PM_TYPE_STRING)
> def test():
> pmfg = pmCreateFetchGroup()
> pmTraversePMNS("disk.dev", add_metric)
> [...]
Yeah, that sort of thing should work (from python or C). In the
Python case, I'm hoping to abstract a little more.
> [...] By the way, one of the items in pmrep todo-list is handling
> counter wrapping. According to PCPIntro(1) it's disabled by default
> nowadays (not sure why it was changed), do you plan to handle that
> with fetch groups?
It'd be nice to do it consistently with other rate-conversion code in
pcp; there are probably three or four different places now. We've
also encountered situations where rates are of interest, but for
metrics that aren't monotonically-increasing counters. So
wrapping-awareness code would have to be semantic-aware. Dunno.
- FChE
|