Added support for query string parameters in upstream path template (#467)

This commit is contained in:
Tom Pallister
2018-07-12 19:26:23 +01:00
committed by GitHub
parent 19ea93d10e
commit 8f4ae03290
24 changed files with 664 additions and 143 deletions

View File

@ -599,7 +599,7 @@
.WithDownstreamPathTemplate("/products/{productId}")
.WithUpstreamPathTemplate("/api/products/{productId}")
.WithUpstreamHttpMethod(new List<string> {"Get"})
.WithUpstreamTemplatePattern(new UpstreamPathTemplate("(?i)/api/products/.*/$", 1))
.WithUpstreamTemplatePattern(new UpstreamPathTemplate("(?i)/api/products/.*/$", 1, false))
.WithLoadBalancerKey("/api/products/{productId}|Get|")
.Build();
@ -628,7 +628,7 @@
.WithDownstreamReRoute(downstreamReRoute)
.WithUpstreamPathTemplate("/api/products/{productId}")
.WithUpstreamHttpMethod(new List<string> { "Get" })
.WithUpstreamTemplatePattern(new UpstreamPathTemplate("(?i)/api/products/.*/$", 1))
.WithUpstreamTemplatePattern(new UpstreamPathTemplate("(?i)/api/products/.*/$", 1, false))
.Build()
}))
.BDDfy();
@ -922,7 +922,7 @@
{
_upstreamTemplatePatternCreator
.Setup(x => x.Create(It.IsAny<FileReRoute>()))
.Returns(new UpstreamPathTemplate(pattern, 1));
.Returns(new UpstreamPathTemplate(pattern, 1, false));
}
private void ThenTheRequestIdKeyCreatorIsCalledCorrectly()