[优化] 将 OpenRestyProxyRequestBufferingEnabled 设置为 false,并更新相关文档

This commit is contained in:
ryan
2026-03-13 17:16:08 +08:00
parent 8f38041af3
commit 2756178355
4 changed files with 19 additions and 6 deletions
+12
View File
@@ -318,6 +318,18 @@ func TestOpenRestyCommonRequestOptionsRender(t *testing.T) {
}
}
func TestOpenRestyProxyRequestBufferingDefaultsToOff(t *testing.T) {
setupServiceTestDB(t)
preview, err := PreviewConfigVersion()
if err != nil {
t.Fatalf("PreviewConfigVersion failed: %v", err)
}
if !strings.Contains(preview.MainConfig, "proxy_request_buffering off;") {
t.Fatal("expected preview main config to default proxy_request_buffering to off")
}
}
func setupServiceTestDB(t *testing.T) {
t.Helper()
common.SQLitePath = filepath.Join(t.TempDir(), "service.db")