Gateway API HttpRoute with URLRewrite
of type: ReplacePrefixMatch
ignores other matches conditions like method
or headers
#6554
Labels
bug
Something isn't working
Is there an existing issue for this?
Current Behavior
I noticed that Gateway API HTTPRoutes that use
URLRewrite
filter with type:ReplacePrefixMatch
is silently ignoring matches conditions other thanpath
, for examplemethod
orheaders
, maybe others too.When I change the type of
URLRewrite
toReplaceFullPath
then everything is OK.Here is affected config example:
http_route-prefix_rewrite.yml.txt
and json fragment of configuration dumps from KIC obtained by
as described in https://docs.konghq.com/kubernetes-ingress-controller/latest/reference/troubleshooting/#dumping-generated-kong-configuration
dump_prefix_rewrite.json
Notice, that expression does not contain any condition related to the
method
match.Same happens with
headers
and maybe others too.Expected Behavior
For comparison see the correct behaviour for
URLRewrite
typeReplaceFullPath
:The crucial difference is in the
expression
, wheremethod
condition is included, as expected.Steps To Reproduce
Kong Ingress Controller version
Kubernetes version
Anything else?
No response
The text was updated successfully, but these errors were encountered: