fix: 批处理设置超时

This commit is contained in:
npc0-hue
2026-03-18 11:30:11 +08:00
parent 1d6e41829a
commit 892a5f9127
+2 -2
View File
@@ -363,8 +363,8 @@ func (s *BatchWorkflowService) callDifyAPI(
}
// Extend End: 添加CSRF token支持
// 发送请求
client := &http.Client{}
// 发送请求(设置超时,避免 Dify 卡住时 goroutine 与连接长期占用不释放)
client := &http.Client{Timeout: 5 * time.Minute}
resp, err := client.Do(req)
if err != nil {
return "", err