mirror of
https://github.com/nsnail/Ocelot.git
synced 2025-06-19 22:48:15 +08:00
auth options builders
This commit is contained in:
@ -47,7 +47,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamPort = _downstreamServicePort,
|
||||
DownstreamHost = _downstreamServiceHost,
|
||||
DownstreamScheme = _downstreamServiceScheme,
|
||||
UpstreamTemplate = "/",
|
||||
UpstreamPathTemplate = "/",
|
||||
UpstreamHttpMethod = "Post",
|
||||
AuthenticationOptions = new FileAuthenticationOptions
|
||||
{
|
||||
@ -85,7 +85,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamPort = _downstreamServicePort,
|
||||
DownstreamHost = _downstreamServiceHost,
|
||||
DownstreamScheme = _downstreamServiceScheme,
|
||||
UpstreamTemplate = "/",
|
||||
UpstreamPathTemplate = "/",
|
||||
UpstreamHttpMethod = "Post",
|
||||
AuthenticationOptions = new FileAuthenticationOptions
|
||||
{
|
||||
@ -123,7 +123,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamPort = _downstreamServicePort,
|
||||
DownstreamHost = _downstreamServiceHost,
|
||||
DownstreamScheme = _downstreamServiceScheme,
|
||||
UpstreamTemplate = "/",
|
||||
UpstreamPathTemplate = "/",
|
||||
UpstreamHttpMethod = "Get",
|
||||
AuthenticationOptions = new FileAuthenticationOptions
|
||||
{
|
||||
@ -163,7 +163,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamPort = _downstreamServicePort,
|
||||
DownstreamHost = _downstreamServiceHost,
|
||||
DownstreamScheme = _downstreamServiceScheme,
|
||||
UpstreamTemplate = "/",
|
||||
UpstreamPathTemplate = "/",
|
||||
UpstreamHttpMethod = "Post",
|
||||
AuthenticationOptions = new FileAuthenticationOptions
|
||||
{
|
||||
@ -203,7 +203,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamPort = _downstreamServicePort,
|
||||
DownstreamHost = _downstreamServiceHost,
|
||||
DownstreamScheme = _downstreamServiceScheme,
|
||||
UpstreamTemplate = "/",
|
||||
UpstreamPathTemplate = "/",
|
||||
UpstreamHttpMethod = "Post",
|
||||
AuthenticationOptions = new FileAuthenticationOptions
|
||||
{
|
||||
|
@ -41,7 +41,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamPort = 51876,
|
||||
DownstreamScheme = "http",
|
||||
DownstreamHost = "localhost",
|
||||
UpstreamTemplate = "/",
|
||||
UpstreamPathTemplate = "/",
|
||||
UpstreamHttpMethod = "Get",
|
||||
AuthenticationOptions = new FileAuthenticationOptions
|
||||
{
|
||||
@ -98,7 +98,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamPort = 51876,
|
||||
DownstreamScheme = "http",
|
||||
DownstreamHost = "localhost",
|
||||
UpstreamTemplate = "/",
|
||||
UpstreamPathTemplate = "/",
|
||||
UpstreamHttpMethod = "Get",
|
||||
AuthenticationOptions = new FileAuthenticationOptions
|
||||
{
|
||||
|
@ -35,7 +35,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamPort = 51879,
|
||||
DownstreamScheme = "http",
|
||||
DownstreamHost = "localhost",
|
||||
UpstreamTemplate = "/",
|
||||
UpstreamPathTemplate = "/",
|
||||
UpstreamHttpMethod = "Get",
|
||||
FileCacheOptions = new FileCacheOptions
|
||||
{
|
||||
@ -71,7 +71,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamPort = 51879,
|
||||
DownstreamScheme = "http",
|
||||
DownstreamHost = "localhost",
|
||||
UpstreamTemplate = "/",
|
||||
UpstreamPathTemplate = "/",
|
||||
UpstreamHttpMethod = "Get",
|
||||
FileCacheOptions = new FileCacheOptions
|
||||
{
|
||||
|
@ -34,7 +34,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamPort = 51879,
|
||||
DownstreamScheme = "http",
|
||||
DownstreamHost = "localhost",
|
||||
UpstreamTemplate = "/products/{productId}",
|
||||
UpstreamPathTemplate = "/products/{productId}",
|
||||
UpstreamHttpMethod = "Get"
|
||||
}
|
||||
}
|
||||
@ -61,7 +61,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamPort = 51879,
|
||||
DownstreamScheme = "http",
|
||||
DownstreamHost = "localhost",
|
||||
UpstreamTemplate = "/products/{productId}",
|
||||
UpstreamPathTemplate = "/products/{productId}",
|
||||
UpstreamHttpMethod = "Get",
|
||||
ReRouteIsCaseSensitive = false
|
||||
}
|
||||
@ -89,7 +89,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamPort = 51879,
|
||||
DownstreamScheme = "http",
|
||||
DownstreamHost = "localhost",
|
||||
UpstreamTemplate = "/products/{productId}",
|
||||
UpstreamPathTemplate = "/products/{productId}",
|
||||
UpstreamHttpMethod = "Get",
|
||||
ReRouteIsCaseSensitive = true
|
||||
}
|
||||
@ -117,7 +117,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamPort = 51879,
|
||||
DownstreamScheme = "http",
|
||||
DownstreamHost = "localhost",
|
||||
UpstreamTemplate = "/PRODUCTS/{productId}",
|
||||
UpstreamPathTemplate = "/PRODUCTS/{productId}",
|
||||
UpstreamHttpMethod = "Get",
|
||||
ReRouteIsCaseSensitive = true
|
||||
}
|
||||
@ -145,7 +145,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamPort = 51879,
|
||||
DownstreamScheme = "http",
|
||||
DownstreamHost = "localhost",
|
||||
UpstreamTemplate = "/products/{productId}",
|
||||
UpstreamPathTemplate = "/products/{productId}",
|
||||
UpstreamHttpMethod = "Get",
|
||||
ReRouteIsCaseSensitive = true
|
||||
}
|
||||
@ -173,7 +173,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamPort = 51879,
|
||||
DownstreamScheme = "http",
|
||||
DownstreamHost = "localhost",
|
||||
UpstreamTemplate = "/PRODUCTS/{productId}",
|
||||
UpstreamPathTemplate = "/PRODUCTS/{productId}",
|
||||
UpstreamHttpMethod = "Get",
|
||||
ReRouteIsCaseSensitive = true
|
||||
}
|
||||
|
@ -55,7 +55,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamPort = 52876,
|
||||
DownstreamScheme = "http",
|
||||
DownstreamHost = "localhost",
|
||||
UpstreamTemplate = "/",
|
||||
UpstreamPathTemplate = "/",
|
||||
UpstreamHttpMethod = "Get",
|
||||
AuthenticationOptions = new FileAuthenticationOptions
|
||||
{
|
||||
|
@ -55,7 +55,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamPort = 57876,
|
||||
DownstreamScheme = "http",
|
||||
DownstreamHost = "localhost",
|
||||
UpstreamTemplate = "/",
|
||||
UpstreamPathTemplate = "/",
|
||||
UpstreamHttpMethod = "Get",
|
||||
AuthenticationOptions = new FileAuthenticationOptions
|
||||
{
|
||||
|
@ -49,7 +49,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamPort = 41879,
|
||||
DownstreamScheme = "http",
|
||||
DownstreamHost = "localhost",
|
||||
UpstreamTemplate = "/",
|
||||
UpstreamPathTemplate = "/",
|
||||
UpstreamHttpMethod = "Get",
|
||||
}
|
||||
}
|
||||
@ -86,7 +86,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamPort = 41879,
|
||||
DownstreamScheme = "http",
|
||||
DownstreamHost = "localhost",
|
||||
UpstreamTemplate = "/",
|
||||
UpstreamPathTemplate = "/",
|
||||
UpstreamHttpMethod = "Get",
|
||||
}
|
||||
}
|
||||
@ -123,7 +123,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamPort = 41879,
|
||||
DownstreamScheme = "http",
|
||||
DownstreamHost = "localhost",
|
||||
UpstreamTemplate = "/",
|
||||
UpstreamPathTemplate = "/",
|
||||
UpstreamHttpMethod = "Get",
|
||||
}
|
||||
}
|
||||
@ -160,7 +160,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamPort = 41879,
|
||||
DownstreamScheme = "http",
|
||||
DownstreamHost = "localhost",
|
||||
UpstreamTemplate = "/",
|
||||
UpstreamPathTemplate = "/",
|
||||
UpstreamHttpMethod = "Get",
|
||||
}
|
||||
}
|
||||
@ -197,7 +197,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamPort = 41879,
|
||||
DownstreamScheme = "http",
|
||||
DownstreamHost = "localhost",
|
||||
UpstreamTemplate = "/",
|
||||
UpstreamPathTemplate = "/",
|
||||
UpstreamHttpMethod = "Get",
|
||||
}
|
||||
}
|
||||
@ -234,7 +234,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamPort = 41879,
|
||||
DownstreamScheme = "http",
|
||||
DownstreamHost = "localhost",
|
||||
UpstreamTemplate = "/",
|
||||
UpstreamPathTemplate = "/",
|
||||
UpstreamHttpMethod = "Get",
|
||||
}
|
||||
}
|
||||
|
@ -37,7 +37,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamPort = 51879,
|
||||
DownstreamScheme = "http",
|
||||
DownstreamHost = "localhost",
|
||||
UpstreamTemplate = "/",
|
||||
UpstreamPathTemplate = "/",
|
||||
UpstreamHttpMethod = "Get",
|
||||
RequestIdKey = _steps.RequestIdKey
|
||||
}
|
||||
@ -65,7 +65,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamPort = 51879,
|
||||
DownstreamScheme = "http",
|
||||
DownstreamHost = "localhost",
|
||||
UpstreamTemplate = "/",
|
||||
UpstreamPathTemplate = "/",
|
||||
UpstreamHttpMethod = "Get",
|
||||
RequestIdKey = _steps.RequestIdKey
|
||||
}
|
||||
@ -95,7 +95,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamPort = 51879,
|
||||
DownstreamScheme = "http",
|
||||
DownstreamHost = "localhost",
|
||||
UpstreamTemplate = "/",
|
||||
UpstreamPathTemplate = "/",
|
||||
UpstreamHttpMethod = "Get",
|
||||
}
|
||||
},
|
||||
|
@ -30,7 +30,7 @@ namespace Ocelot.AcceptanceTests
|
||||
new FileReRoute
|
||||
{
|
||||
DownstreamPathTemplate = "http://localhost:53876/",
|
||||
UpstreamTemplate = "/",
|
||||
UpstreamPathTemplate = "/",
|
||||
UpstreamHttpMethod = "Get"
|
||||
}
|
||||
}
|
||||
|
@ -44,7 +44,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamScheme = "http",
|
||||
DownstreamHost = "localhost",
|
||||
DownstreamPort = 51879,
|
||||
UpstreamTemplate = "/",
|
||||
UpstreamPathTemplate = "/",
|
||||
UpstreamHttpMethod = "Get",
|
||||
}
|
||||
}
|
||||
@ -72,7 +72,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamScheme = "http",
|
||||
DownstreamHost = "localhost",
|
||||
DownstreamPort = 51879,
|
||||
UpstreamTemplate = "/",
|
||||
UpstreamPathTemplate = "/",
|
||||
UpstreamHttpMethod = "Get",
|
||||
}
|
||||
}
|
||||
@ -100,7 +100,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamScheme = "http",
|
||||
DownstreamHost = "localhost/",
|
||||
DownstreamPort = 51879,
|
||||
UpstreamTemplate = "/",
|
||||
UpstreamPathTemplate = "/",
|
||||
UpstreamHttpMethod = "Get",
|
||||
}
|
||||
}
|
||||
@ -128,7 +128,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamScheme = "http",
|
||||
DownstreamHost = "localhost",
|
||||
DownstreamPort = 51879,
|
||||
UpstreamTemplate = "/products/",
|
||||
UpstreamPathTemplate = "/products/",
|
||||
UpstreamHttpMethod = "Get",
|
||||
}
|
||||
}
|
||||
@ -156,7 +156,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamScheme = "http",
|
||||
DownstreamHost = "localhost",
|
||||
DownstreamPort = 51879,
|
||||
UpstreamTemplate = "/products",
|
||||
UpstreamPathTemplate = "/products",
|
||||
UpstreamHttpMethod = "Get",
|
||||
}
|
||||
}
|
||||
@ -184,7 +184,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamScheme = "http",
|
||||
DownstreamHost = "localhost",
|
||||
DownstreamPort = 51879,
|
||||
UpstreamTemplate = "/products/{productId}",
|
||||
UpstreamPathTemplate = "/products/{productId}",
|
||||
UpstreamHttpMethod = "Get",
|
||||
}
|
||||
}
|
||||
@ -211,7 +211,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamScheme = "http",
|
||||
DownstreamHost = "localhost",
|
||||
DownstreamPort = 51879,
|
||||
UpstreamTemplate = "/products/{productId}",
|
||||
UpstreamPathTemplate = "/products/{productId}",
|
||||
UpstreamHttpMethod = "Get"
|
||||
}
|
||||
}
|
||||
@ -239,7 +239,7 @@ namespace Ocelot.AcceptanceTests
|
||||
DownstreamHost = "localhost",
|
||||
DownstreamPort = 51879,
|
||||
DownstreamScheme = "http",
|
||||
UpstreamTemplate = "/",
|
||||
UpstreamPathTemplate = "/",
|
||||
UpstreamHttpMethod = "Post"
|
||||
}
|
||||
}
|
||||
@ -264,7 +264,7 @@ namespace Ocelot.AcceptanceTests
|
||||
new FileReRoute
|
||||
{
|
||||
DownstreamPathTemplate = "/newThing",
|
||||
UpstreamTemplate = "/newThing",
|
||||
UpstreamPathTemplate = "/newThing",
|
||||
DownstreamScheme = "http",
|
||||
DownstreamHost = "localhost",
|
||||
DownstreamPort = 51879,
|
||||
|
@ -68,7 +68,7 @@ namespace Ocelot.AcceptanceTests
|
||||
{
|
||||
DownstreamPathTemplate = "/",
|
||||
DownstreamScheme = "http",
|
||||
UpstreamTemplate = "/",
|
||||
UpstreamPathTemplate = "/",
|
||||
UpstreamHttpMethod = "Get",
|
||||
ServiceName = serviceName,
|
||||
LoadBalancer = "LeastConnection",
|
||||
|
@ -1 +1 @@
|
||||
{"ReRoutes":[{"DownstreamPathTemplate":"41879/","UpstreamTemplate":"/","UpstreamHttpMethod":"Get","AuthenticationOptions":{"Provider":null,"ProviderRootUrl":null,"ScopeName":null,"RequireHttps":false,"AdditionalScopes":[],"ScopeSecret":null},"AddHeadersToRequest":{},"AddClaimsToRequest":{},"RouteClaimsRequirement":{},"AddQueriesToRequest":{},"RequestIdKey":null,"FileCacheOptions":{"TtlSeconds":0},"ReRouteIsCaseSensitive":false,"ServiceName":null,"DownstreamScheme":"http","DownstreamHost":"localhost","DownstreamPort":41879,"LoadBalancer":null}],"GlobalConfiguration":{"RequestIdKey":null,"ServiceDiscoveryProvider":{"Provider":null,"Host":null,"Port":0}}}
|
||||
{"ReRoutes":[{"DownstreamPathTemplate":"41879/","UpstreamPathTemplate":"/","UpstreamHttpMethod":"Get","AuthenticationOptions":{"Provider":null,"ProviderRootUrl":null,"ScopeName":null,"RequireHttps":false,"AdditionalScopes":[],"ScopeSecret":null},"AddHeadersToRequest":{},"AddClaimsToRequest":{},"RouteClaimsRequirement":{},"AddQueriesToRequest":{},"RequestIdKey":null,"FileCacheOptions":{"TtlSeconds":0},"ReRouteIsCaseSensitive":false,"ServiceName":null,"DownstreamScheme":"http","DownstreamHost":"localhost","DownstreamPort":41879,"LoadBalancer":null}],"GlobalConfiguration":{"RequestIdKey":null,"ServiceDiscoveryProvider":{"Provider":null,"Host":null,"Port":0}}}
|
Reference in New Issue
Block a user