diff options
author | Alex Auvolat <lx@deuxfleurs.fr> | 2025-01-28 15:12:03 +0100 |
---|---|---|
committer | Alex Auvolat <lx@deuxfleurs.fr> | 2025-01-29 19:26:16 +0100 |
commit | c99bfe69ea19497895d32669fd15c689b86035d8 (patch) | |
tree | fd70d3d92c45de20f28c078b902c083cee91a037 /src/api/k2v/api_server.rs | |
parent | 831f2b0207f128d67f061e6f7084337b1cbfefa4 (diff) | |
download | garage-c99bfe69ea19497895d32669fd15c689b86035d8.tar.gz garage-c99bfe69ea19497895d32669fd15c689b86035d8.zip |
admin api: new router_v2 with unified path syntax
Diffstat (limited to 'src/api/k2v/api_server.rs')
-rw-r--r-- | src/api/k2v/api_server.rs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/api/k2v/api_server.rs b/src/api/k2v/api_server.rs index de6e5f06..35931914 100644 --- a/src/api/k2v/api_server.rs +++ b/src/api/k2v/api_server.rs @@ -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<'_>) { |