From 43df87a377ac1ea773b9b86c685880e11e20ce3e Mon Sep 17 00:00:00 2001 From: lovehunter9 Date: Tue, 4 Mar 2025 15:50:41 +0800 Subject: [PATCH] add StreamRequestBody for fiber --- cmd/upload/app/server.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cmd/upload/app/server.go b/cmd/upload/app/server.go index 272de87..df1ea5a 100644 --- a/cmd/upload/app/server.go +++ b/cmd/upload/app/server.go @@ -37,7 +37,8 @@ type Server struct { func (server *Server) Init() error { server.getEnvAppInfo() server.app = fiber.New(fiber.Config{ - BodyLimit: math.MaxInt, // this is the default limit of 10MB + BodyLimit: math.MaxInt, // this is the default limit of 10MB + StreamRequestBody: true, }) // middleware to allow all clients to communicate using http and allow cors server.app.Use(cors.New(cors.Config{