feat(router_env): making metric flow as a trait for extensibility (#797)

This commit is contained in:
Nishant Joshi
2023-03-23 14:52:57 +05:30
committed by GitHub
parent 699ca4f6f8
commit da5a89bc3d
3 changed files with 11 additions and 2 deletions

View File

@ -164,6 +164,12 @@ pub enum Flow {
ApiKeyList,
}
///
/// Trait for providing generic behaviour to flow metric
///
pub trait FlowMetric: ToString + std::fmt::Debug {}
impl FlowMetric for Flow {}
/// Category of log event.
#[derive(Debug)]
pub enum Category {