We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f12a30d commit 53e2401Copy full SHA for 53e2401
engine/api/workflow_run.go
@@ -814,14 +814,18 @@ func (api *API) getWorkflowRunArtifactsHandler() Handler {
814
return runs[i].SubNumber > runs[j].SubNumber
815
})
816
817
+ wg := &sync.WaitGroup{}
818
for i := range runs[0].Artifacts {
- a := &runs[0].Artifacts[i]
819
- url, _ := objectstore.FetchTempURL(a)
820
- if url != "" {
821
- a.TempURL = url
822
- }
+ wg.Add(1)
+ go func(a *sdk.WorkflowNodeRunArtifact) {
+ defer wg.Done()
+ url, _ := objectstore.FetchTempURL(a)
823
+ if url != "" {
824
+ a.TempURL = url
825
+ }
826
+ }(&runs[0].Artifacts[i])
827
}
-
828
+ wg.Wait()
829
arts = append(arts, runs[0].Artifacts...)
830
831
0 commit comments