diff --git a/pkg/apis/workflow/v1alpha1/workflow_types.go b/pkg/apis/workflow/v1alpha1/workflow_types.go index 4cd74e2450e5..7b36fd0b6e99 100644 --- a/pkg/apis/workflow/v1alpha1/workflow_types.go +++ b/pkg/apis/workflow/v1alpha1/workflow_types.go @@ -3024,6 +3024,8 @@ func (tmpl *Template) GetNodeType() NodeType { return NodeTypeSteps case TemplateTypeSuspend: return NodeTypeSuspend + case TemplateTypeHTTP: + return NodeTypeHTTP case TemplateTypePlugin: return NodeTypePlugin } diff --git a/workflow/controller/http_template.go b/workflow/controller/http_template.go index 0bbd9fcbfde2..de6a7048c1c6 100644 --- a/workflow/controller/http_template.go +++ b/workflow/controller/http_template.go @@ -8,6 +8,8 @@ func (woc *wfOperationCtx) executeHTTPTemplate(nodeName string, templateScope st node, err := woc.wf.GetNodeByName(nodeName) if err != nil { node = woc.initializeExecutableNode(nodeName, wfv1.NodeTypeHTTP, templateScope, tmpl, orgTmpl, opts.boundaryID, wfv1.NodePending, opts.nodeFlag) + } + if !node.Fulfilled() { woc.taskSet[node.ID] = *tmpl } return node