Skip to content

Commit 121a527

Browse files
authored
feat(http/prom): introduce MkWithLabels::new() (#4418)
#4251 introduced a suite of MkStreamLabel components that can be used to inspect and label traffic. MkWithLabels offers a way to construct this type externally, now that we will have use for it in the inbound proxy. Signed-off-by: katelyn martin <kate@buoyant.io>
1 parent 2dfd671 commit 121a527

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

  • linkerd/http/prom/src/stream_label

linkerd/http/prom/src/stream_label/with.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,12 @@ pub struct WithLabels<L> {
2121

2222
// === impl MkWithLabels ===
2323

24+
impl<L> MkWithLabels<L> {
25+
pub fn new(labels: L) -> Self {
26+
Self { labels }
27+
}
28+
}
29+
2430
impl<L> MkStreamLabel for MkWithLabels<L>
2531
where
2632
L: Clone + Send + 'static,

0 commit comments

Comments
 (0)