Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion example_config_proxy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,6 @@ proxy:
us2: us2-conduit
- match:
host: conduit.de.sentry.io
path: /organizations/{organization}/*
action:
to: de-conduit

Expand Down
10 changes: 4 additions & 6 deletions proxy/src/route_actions.rs
Original file line number Diff line number Diff line change
Expand Up @@ -112,10 +112,9 @@ impl TryFrom<RouteConfig> for Route {
s.strip_prefix('{').and_then(|s| s.strip_suffix('}'))
{
if is_static_action {
return Err(ProxyError::InvalidRoute(
"Dynamic path parameters are not allowed with static actions"
.to_string(),
));
return Err(ProxyError::InvalidRoute(format!(
"Dynamic path parameters are not allowed with static actions in route: {path_str}"
)));
}
let is_valid = stripped.chars().all(|ch| ch.is_ascii_lowercase() || ch == '_' );
if !is_valid {
Expand All @@ -136,8 +135,7 @@ impl TryFrom<RouteConfig> for Route {

if !is_valid {
return Err(ProxyError::InvalidRoute(format!(
"Invalid static segment: {}",
s
"Invalid static segment: {s} in route: {path_str}"
)));
}

Expand Down