feat: batch STRM tree generation

This commit is contained in:
ShukeBta
2026-07-02 21:35:50 +08:00
parent d11f784438
commit 87928cfa4d
6 changed files with 117 additions and 4 deletions
+2
View File
@@ -119,6 +119,7 @@ type generateSTRMTreeReq struct {
Overwrite bool `json:"overwrite"`
Cleanup bool `json:"cleanup"`
DryRun bool `json:"dry_run"`
BatchLimit int `json:"batch_limit"`
}
func generateSTRMHandler(svc *service.Container) gin.HandlerFunc {
@@ -191,6 +192,7 @@ func generateSTRMFromTreeHandler(svc *service.Container) gin.HandlerFunc {
Overwrite: req.Overwrite,
Cleanup: req.Cleanup,
DryRun: req.DryRun,
BatchLimit: req.BatchLimit,
})
if err != nil {
c.JSON(http.StatusBadRequest, gin.H{"error": err.Error()})