admin api: new router_v2 with unified path syntax

This commit is contained in:
Alex Auvolat
2025-01-28 15:12:03 +01:00
parent 831f2b0207
commit c99bfe69ea
16 changed files with 451 additions and 292 deletions
+3 -2
View File
@@ -1,3 +1,4 @@
use std::borrow::Cow;
use std::sync::Arc;
use async_trait::async_trait;
@@ -181,8 +182,8 @@ impl ApiHandler for K2VApiServer {
}
impl ApiEndpoint for K2VApiEndpoint {
fn name(&self) -> &'static str {
self.endpoint.name()
fn name(&self) -> Cow<'_, str> {
Cow::borrowed(self.endpoint.name())
}
fn add_span_attributes(&self, span: SpanRef<'_>) {