From 9c9019cb227ed8cc5371dfe3667ada5ebed2fc77 Mon Sep 17 00:00:00 2001 From: GoEdgeLab Date: Fri, 30 Dec 2022 11:43:53 +0800 Subject: [PATCH] =?UTF-8?q?=E9=BB=98=E8=AE=A4=E6=83=85=E5=86=B5=E4=B8=8B?= =?UTF-8?q?=E5=86=85=E5=AE=B9=E5=8E=8B=E7=BC=A9=E4=B8=8D=E6=94=AF=E6=8C=81?= =?UTF-8?q?Partial=20Content?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pkg/serverconfigs/http_compression_config.go | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/pkg/serverconfigs/http_compression_config.go b/pkg/serverconfigs/http_compression_config.go index fb6cb75..6682d6e 100644 --- a/pkg/serverconfigs/http_compression_config.go +++ b/pkg/serverconfigs/http_compression_config.go @@ -33,11 +33,12 @@ type HTTPCompressionConfig struct { Deflate *HTTPDeflateCompressionConfig `yaml:"deflate" json:"deflate"` Brotli *HTTPBrotliCompressionConfig `yaml:"brotli" json:"brotli"` - MinLength *shared.SizeCapacity `yaml:"minLength" json:"minLength"` // 最小压缩对象比如4m, 24k - MaxLength *shared.SizeCapacity `yaml:"maxLength" json:"maxLength"` // 最大压缩对象 - MimeTypes []string `yaml:"mimeTypes" json:"mimeTypes"` // 支持的MimeType,支持image/*这样的通配符使用 - Extensions []string `yaml:"extensions" json:"extensions"` // 文件扩展名,包含点符号,不区分大小写 - Conds *shared.HTTPRequestCondsConfig `yaml:"conds" json:"conds"` // 匹配条件 + MinLength *shared.SizeCapacity `yaml:"minLength" json:"minLength"` // 最小压缩对象比如4m, 24k + MaxLength *shared.SizeCapacity `yaml:"maxLength" json:"maxLength"` // 最大压缩对象 + MimeTypes []string `yaml:"mimeTypes" json:"mimeTypes"` // 支持的MimeType,支持image/*这样的通配符使用 + Extensions []string `yaml:"extensions" json:"extensions"` // 文件扩展名,包含点符号,不区分大小写 + Conds *shared.HTTPRequestCondsConfig `yaml:"conds" json:"conds"` // 匹配条件 + EnablePartialContent bool `yaml:"enablePartialContent" json:"enablePartialContent"` // 支持PartialContent压缩 minLength int64 maxLength int64