mirror of
http://git.haproxy.org/git/haproxy.git/
synced 2024-12-26 22:52:13 +00:00
eb2128723a
In this patch we add a registration mechanism for modules. To do so, a module must defined the "promex_module" structure. The dump itself will be based on 2 contexts. One for all the dump and another one for each metric time-series. These contexts are used as restart points when the dump is interrupted. Modules must also implement 6 callback functions: * start_metric_dump(): It is an optional callback function. If defined, it is responsible to initialize the dump context use as the first restart point. * stop_metric_dump(): It is an optional callback function. If defined, it is responsible to deinit the dump context. * metric_info(): This one is mandatory. It returns the info about the metric: name, type and flags and descrition. * start_ts(): This one is mandatory, it initializes the context for a time series for a given metric. This context is the second restart point. * next_ts(): This one is mandatory. It interates on time series for a given metrics. It is also responsible to handle end of a time series and deinit the context. * fill_ts(): It fills info on the time series for a given metric : the labels and the value. In addition, a module must set its name and declare the number of metrics is exposed. |
||
---|---|---|
.. | ||
51degrees | ||
deviceatlas | ||
ot | ||
promex | ||
wurfl |