fix error handling/short-circuiting in multi route matching

This commit is contained in:
Joel Wetzell
2025-12-28 11:30:37 -06:00
parent b639a5c786
commit a994286402
3 changed files with 98 additions and 26 deletions

View File

@@ -20,13 +20,15 @@ type RouteError struct {
}
type RouteIOError struct {
Index int
Error error
Index int
OutputErrors []error
ProcessError error
InputError error
}
type RouteIO interface {
HandleInput(sourceId string, payload any) []RouteIOError
HandleOutput(ctx context.Context, destinationId string, payload any) error
HandleInput(sourceId string, payload any) (bool, []RouteIOError)
HandleOutput(ctx context.Context, destinationId string, payload any) []error
}
type Route interface {