From e475e2850125d61c5b856765f4ec8db76762871e Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Tue, 22 Sep 2026 22:34:16 +0000 Subject: [PATCH] [dotnet-code] Route workflow edges by kind Align edge delivery internals around the existing edge kind helper so future .NET-to-Go workflow ports can map more directly to the .NET Edge.Kind structure. No public API or behavior changes are intended. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- workflow/internal/execution/edgerunner.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/workflow/internal/execution/edgerunner.go b/workflow/internal/execution/edgerunner.go index c04ab373..7b5a8404 100644 --- a/workflow/internal/execution/edgerunner.go +++ b/workflow/internal/execution/edgerunner.go @@ -211,6 +211,7 @@ func (em *EdgeRunner) PrepareDeliveryForEdge(ctx context.Context, edge workflow. span.SetDeliveryStatus(observability.DeliveryStatusDroppedConditionFalse) return nil, nil } + kind := kindOfEdge(edge) targetIDs := selectedTargetIDs(edge, envelope) if len(targetIDs) == 0 { span.SetDeliveryStatus(observability.DeliveryStatusDroppedTargetMismatch) @@ -218,7 +219,7 @@ func (em *EdgeRunner) PrepareDeliveryForEdge(ctx context.Context, edge workflow. } var envelopes []*MessageEnvelope - if len(edge.Connection.SourceIDs) == 1 { + if kind != fanInEdge { envelopes = []*MessageEnvelope{envelope} } else { // Stateful edge - track source messages. @@ -243,7 +244,7 @@ func (em *EdgeRunner) PrepareDeliveryForEdge(ctx context.Context, edge workflow. span.SetDeliveryStatus(observability.DeliveryStatusDroppedTargetMismatch) return nil, nil } - if len(edge.Connection.SourceIDs) == 1 { + if kind != fanInEdge { // Filter targets that can handle the message type. runtimeType, err := em.messageRuntimeType(ctx, envelope) if err != nil {