|
30 | 30 | // matches /download/* and routes to "allClusterProps" |
31 | 31 | "ClusterId": "allClusterProps", // Name of one of the clusters |
32 | 32 | "Order": 0, // Lower numbers have higher precidence, default is 0 |
33 | | - "Authorization Policy": "Anonymous", // Name of the policy or "Default", "Anonymous" |
| 33 | + "AuthorizationPolicy": "Anonymous", // Name of the policy or "Default", "Anonymous" |
34 | 34 | "CorsPolicy": "disable", // Name of the CorsPolicy to apply to this route or "default", "disable" |
35 | 35 | "Match": { // Rules that have to be met for the route to match the request |
36 | 36 | "Path": "/download/{**remainder}", // The path to match using ASP.NET syntax. |
|
53 | 53 | } |
54 | 54 | ] |
55 | 55 | }, |
56 | | - "MetaData": { // List of key value pairs that can be used by custom extensions |
| 56 | + "Metadata": { // List of key value pairs that can be used by custom extensions |
57 | 57 | "MyName": "MyValue" |
58 | 58 | }, |
59 | 59 | "Transforms": [ // List of transforms. See ReverseProxy.Transforms.Sample for more details |
|
80 | 80 | }, |
81 | 81 | "another_destination": { |
82 | 82 | "Address": "https://10.20.30.40", |
83 | | - "Health": "https://10.20.30.40:12345" // override for active health checks |
| 83 | + "Health": "https://10.20.30.40:12345", // override for active health checks |
| 84 | + "Host": "contoso", |
| 85 | + "Metadata": { |
| 86 | + "SomeKey": "SomeValue" |
| 87 | + } |
84 | 88 | } |
85 | 89 | }, |
86 | 90 | "LoadBalancingPolicy": "PowerOfTwoChoices", // Alternatively "First", "Random", "RoundRobin", "LeastRequests" |
87 | 91 | "SessionAffinity": { // Ensures subsequent requests from a client go to the same destination server |
88 | 92 | "Enabled": true, // Defaults to 'false' |
89 | 93 | "Policy": "HashCookie", // Default, alternatively "Cookie" or "CustomHeader" |
90 | 94 | "FailurePolicy": "Redistribute", // default, alternatively "Return503Error" |
91 | | - "AffinityKeyName": "MySessionCookieName" // Required, no default |
| 95 | + "AffinityKeyName": "MySessionCookieName", // Required, no default |
| 96 | + "Cookie": { // Options for cookie based session affinity |
| 97 | + "Path": "/", |
| 98 | + "SameSite": "None", |
| 99 | + "HttpOnly": true, |
| 100 | + "Expiration": "00:30:00", |
| 101 | + "Domain": "example.com", |
| 102 | + "MaxAge": "08:00:00", |
| 103 | + "SecurePolicy": "Always", |
| 104 | + "IsEssential": true |
| 105 | + } |
92 | 106 | }, |
93 | 107 | "HealthCheck": { // Ways to determine which destinations should be filtered out due to unhealthy state |
94 | 108 | "Active": { // Makes API calls to validate the health of each destination |
95 | | - "Enabled": "true", |
| 109 | + "Enabled": true, |
96 | 110 | "Interval": "00:00:10", // How often to query for health data |
97 | 111 | "Timeout": "00:00:10", // Timeout for the health check request/response |
98 | 112 | "Policy": "ConsecutiveFailures", // Or other custom policy that has been registered |
99 | | - "Path": "/favicon.ico" // API endpoint to query for health state. Looks for 2XX response codes to indicate healthy state |
| 113 | + "Path": "/favicon.ico", // API endpoint to query for health state. Looks for 2XX response codes to indicate healthy state |
100 | 114 | // Typically something like "/api/health" but used favicon to enable sample to run |
| 115 | + "Query": "?healthCheck=true" // Query string to append to the health check request |
101 | 116 | }, |
102 | 117 | "Passive": { // Disables destinations based on HTTP response codes for proxy requests |
103 | 118 | "Enabled": true, // Defaults to false |
104 | 119 | "Policy": "TransportFailureRate", // Or other custom policy that has been registered |
105 | 120 | "ReactivationPeriod": "00:00:10" // how long before the destination is re-enabled |
106 | | - } |
| 121 | + }, |
| 122 | + "AvailableDestinationsPolicy": "HealthyOrPanic" // Policy for which destinations can be used when sending requests |
107 | 123 | }, |
108 | 124 | "HttpClient": { // Configuration of HttpClient instance used to contact destinations |
109 | | - "SSLProtocols": "Tls13", |
| 125 | + "SslProtocols": [ "Tls13" ], |
110 | 126 | "DangerousAcceptAnyServerCertificate": true, // Disables destination cert validation |
111 | 127 | "MaxConnectionsPerServer": 1024, // Destination server can further limit this number |
112 | 128 | "EnableMultipleHttp2Connections": true, |
113 | 129 | "RequestHeaderEncoding": "Latin1", // How to interpret non ASCII characters in proxied request's header values |
114 | | - "ResponseHeaderEncoding": "Latin1" // How to interpret non ASCII characters in proxied request's response header values |
| 130 | + "ResponseHeaderEncoding": "Latin1", // How to interpret non ASCII characters in proxied request's response header values |
| 131 | + "WebProxy": { // Optinal proxy configuration for outgoing requests |
| 132 | + "Address": "127.0.0.1", |
| 133 | + "BypassOnLocal": true, |
| 134 | + "UseDefaultCredentials": false |
| 135 | + } |
115 | 136 | }, |
116 | 137 | "HttpRequest": { // Options for sending request to destination |
117 | | - "Timeout": "00:02:00", // Timeout for the HttpRequest |
| 138 | + "ActivityTimeout": "00:02:00", // Activity timeout for the request |
118 | 139 | "Version": "2", // Http Version that should be tried first |
119 | | - "VersionPolicy": "RequestVersionOrLower" // Policy for which other versions can be be used |
| 140 | + "VersionPolicy": "RequestVersionOrLower", // Policy for which other versions can be be used |
| 141 | + "AllowResponseBuffering": false |
120 | 142 | }, |
121 | | - "MetaData": { // Custom Key/value pairs for extensibility |
| 143 | + "Metadata": { // Custom Key/value pairs for extensibility |
122 | 144 | "TransportFailureRateHealthPolicy.RateLimit": "0.5", // Used by Passive health policy |
123 | 145 | "MyKey": "MyValue" |
124 | 146 | } |
|
0 commit comments