pmrep: add support for specifying instances
Specifying instances to report is hugely helpful with many metrics, the
best example is probably proc.* metrics where there's lots of instances
and the user might be interested in only one or two of them.
This commit adds support to pmrep(1) for specifying the instances to
report, either using a globally defined list or instances per metric.
The implementation is relatively straightforward, a bit of gymnastics
needed to parse the command line vs config file right and to pass more
than one parameter to pmTraversePMNS().
QA updated with lots of tests, all current and new QA passing, shell
completions updated while at it, man pages updated as well.
There are two things that might require further thought:
1) Instance specification can actually be a regex but I'm not yet 100%
sure it's a good idea so for now I've left it undocumented, I think
it's best we gather a bit of experience and then either document it or
remove the regex support.
2) Reporting to archive ignore this in the spirit of pmlogger(1) but it
might make sense to respect the instance specification with archives as
well. There's been some discussion about this wrt pmlogger earlier,
perhaps we could try to find a common consensus for both:
https://bugzilla.redhat.com/show_bug.cgi?id=
1345821