mirror of
https://github.com/falcosecurity/falco.git
synced 2025-06-26 06:42:08 +00:00
fix(falco_metrics): make duration_sec a count and not a timestamp
The output will thus be a total which is what this metrics is. Signed-off-by: Samuel Gaist <samuel.gaist@idiap.ch>
This commit is contained in:
parent
2ae6103ab6
commit
82c914c11d
@ -117,7 +117,7 @@ std::string falco_metrics::to_text(const falco::app::state& state)
|
||||
static_metrics.push_back(libs_metrics_collector.new_metric("duration_sec",
|
||||
METRICS_V2_MISC,
|
||||
METRIC_VALUE_TYPE_U64,
|
||||
METRIC_VALUE_UNIT_TIME_TIMESTAMP_NS,
|
||||
METRIC_VALUE_UNIT_TIME_S_COUNT,
|
||||
METRIC_VALUE_METRIC_TYPE_NON_MONOTONIC_CURRENT,
|
||||
(uint64_t)((now - agent_info->start_ts_epoch) / ONE_SECOND_IN_NS)));
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user