mirror of
https://github.com/Rain-kl/OpenFlare.git
synced 2026-10-12 18:26:36 +08:00
feat(proxy-route): allow disabling HTTP/2 per route
This commit is contained in:
@@ -113,6 +113,14 @@ func populateProxyRouteFields(
|
||||
route.UpstreamType = upstreamType
|
||||
}
|
||||
|
||||
func applyProxyRouteHTTP2(route *model.ProxyRoute, input Input) {
|
||||
if input.EnableHTTP2 != nil {
|
||||
route.EnableHTTP2 = *input.EnableHTTP2
|
||||
} else if route.ID == 0 {
|
||||
route.EnableHTTP2 = true
|
||||
}
|
||||
}
|
||||
|
||||
func applyProxyRouteUpstreamType(ctx context.Context, route *model.ProxyRoute, upstreamType string, input Input) error {
|
||||
switch upstreamType {
|
||||
case proxyRouteUpstreamTypeTunnel:
|
||||
|
||||
Reference in New Issue
Block a user