Skip to content

Commit

Permalink
convert metrics to lowercase in router.
Browse files Browse the repository at this point in the history
  • Loading branch information
Rachelint committed Dec 2, 2022
1 parent 61b03dc commit 4ec38d1
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions server/src/grpc/storage_service/route.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,15 @@ pub async fn handle_route<Q>(
ctx: &HandlerContext<'_, Q>,
req: RouteRequest,
) -> Result<RouteResponse> {
let normalized_metrics = req
.metrics
.into_iter()
.map(|metric| metric.to_ascii_lowercase())
.collect();
let req = RouteRequest {
metrics: normalized_metrics,
};

let routes = ctx.router.route(ctx.tenant(), req).await?;

let resp = RouteResponse {
Expand Down

0 comments on commit 4ec38d1

Please sign in to comment.