MCPcopy Create free account
hub / github.com/astercloud/aster / notifyWorkflowRegistered

Method notifyWorkflowRegistered

pkg/asteros/asteros.go:349–358  ·  view source on GitHub ↗

notifyWorkflowRegistered 通知所有 Interfaces Workflow 已注册

(wf workflow.Agent)

Source from the content-addressed store, hash-verified

347
348// notifyWorkflowRegistered 通知所有 Interfaces Workflow 已注册
349func (os *AsterOS) notifyWorkflowRegistered(wf workflow.Agent) {
350 os.ifMu.RLock()
351 defer os.ifMu.RUnlock()
352
353 for _, iface := range os.interfaces {
354 if err := iface.OnWorkflowRegistered(wf); err != nil {
355 fmt.Printf("Warning: interface %s OnWorkflowRegistered: %v\n", iface.Name(), err)
356 }
357 }
358}
359
360// corsMiddleware CORS 中间件
361func corsMiddleware() gin.HandlerFunc {

Callers 1

RegisterWorkflowMethod · 0.95

Calls 3

PrintfMethod · 0.80
OnWorkflowRegisteredMethod · 0.65
NameMethod · 0.65

Tested by

no test coverage detected