performancecopilot / speed

A Go implementation of the PCP instrumentation API
MIT License
37 stars 6 forks source link

add custom metric types #23

Closed suyash closed 8 years ago

suyash commented 8 years ago

Potential types to consider

Derive Rate (Meter)

Rate and Derive are supported implicitly by PCP, just set the reporting rate at the time unit (seconds, minutes, hours...) and set semantics to InstantSemantics to get Rate and CounterSemantics to get Derived. Gauge is a shorthand to get a float64 metric with InstantSemantics, while Counter implements a uint64 metric with CounterSemantics.

Histogram Summary

to be considered after #28

Reservoir

couldn't find a real world example of applying reservoir sampling on metric values, why add a value if the probability of it having any real impact just keeps diminishing

see:

natoscott commented 8 years ago

@suyash looks OK, just one issue. In PCP counter semantics, and in system performance analysis in general, counter (MMV_SEM_COUNTER) values never go backwards. I'd recommend dropping all decrement operations, because the PCP client tools will interpret this as an error (counter wrap) and report no value for that sample, which will be very confusing to the user.

Any value that can go backwards should be modeled as a gauge - in PCP, these map to instantaneous metrics (MMV_SEM_INSTANT), and then the client tools know what to do with 'em.

coveralls commented 8 years ago

Coverage Status

Coverage decreased (-1.9%) to 83.124% when pulling cd16c8a21c264c6665739f47df4079aee3942365 on custom-metric-types into b6f56db1c50361c39b81089bacc10c3a462ccbf8 on master.

coveralls commented 8 years ago

Coverage Status

Coverage decreased (-0.2%) to 86.767% when pulling 6190476e7fb08eae42fe33f2ba74573566ce88d5 on custom-metric-types into b8cc339e2adfdd7d4b23e21f495ca301a255fe3e on master.

coveralls commented 8 years ago

Coverage Status

Coverage decreased (-0.04%) to 86.957% when pulling de1d63c20ef5c31b3d9ce3e9aa1ee7508aea2f6a on custom-metric-types into b8cc339e2adfdd7d4b23e21f495ca301a255fe3e on master.

coveralls commented 8 years ago

Coverage Status

Coverage decreased (-0.5%) to 86.477% when pulling dda4a043fade40c19b607581e143891b3c14d03f on custom-metric-types into b8cc339e2adfdd7d4b23e21f495ca301a255fe3e on master.

coveralls commented 8 years ago

Coverage Status

Coverage decreased (-0.5%) to 86.477% when pulling b1d3a2e83ae6d8be33eecb7f0891832fb3f68030 on custom-metric-types into b8cc339e2adfdd7d4b23e21f495ca301a255fe3e on master.

coveralls commented 8 years ago

Coverage Status

Coverage decreased (-1.4%) to 85.576% when pulling f2cdd0119ec75041d06174e9d5e22026dce26e54 on custom-metric-types into b8cc339e2adfdd7d4b23e21f495ca301a255fe3e on master.

coveralls commented 8 years ago

Coverage Status

Coverage decreased (-1.6%) to 85.439% when pulling a340c000e34d316f1c76dfe016ad79c47988e980 on custom-metric-types into b8cc339e2adfdd7d4b23e21f495ca301a255fe3e on master.

coveralls commented 8 years ago

Coverage Status

Coverage decreased (-1.6%) to 85.439% when pulling b865013c49ebec0094f3f737d8fad68bb35d0c70 on custom-metric-types into b8cc339e2adfdd7d4b23e21f495ca301a255fe3e on master.

coveralls commented 8 years ago

Coverage Status

Coverage decreased (-1.6%) to 85.439% when pulling 07df09182665f329605707abc0753805c086e6f1 on custom-metric-types into b8cc339e2adfdd7d4b23e21f495ca301a255fe3e on master.

coveralls commented 8 years ago

Coverage Status

Coverage decreased (-2.7%) to 84.307% when pulling 24abff64e7d572b6163e7092c107e18def22a65b on custom-metric-types into b8cc339e2adfdd7d4b23e21f495ca301a255fe3e on master.

coveralls commented 8 years ago

Coverage Status

Coverage decreased (-2.8%) to 84.237% when pulling 7fef6d92e12737b0c3cf1907e19de111bbde892a on custom-metric-types into b8cc339e2adfdd7d4b23e21f495ca301a255fe3e on master.

coveralls commented 8 years ago

Coverage Status

Coverage decreased (-3.2%) to 83.775% when pulling a33f652baac2f30e3282eb421014f24f399c18ec on custom-metric-types into b8cc339e2adfdd7d4b23e21f495ca301a255fe3e on master.

coveralls commented 8 years ago

Coverage Status

Coverage decreased (-2.7%) to 84.337% when pulling ec80fee7d5372f0db091e3f0e61a0db34f9f5baa on custom-metric-types into b8cc339e2adfdd7d4b23e21f495ca301a255fe3e on master.