From c59ddc1df6083275ae4f6896c0c8779049007c7a Mon Sep 17 00:00:00 2001 From: yusing Date: Fri, 10 Oct 2025 09:53:08 +0800 Subject: [PATCH] refactor: add ShouldExclude() bool to Route interface --- internal/types/routes.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/internal/types/routes.go b/internal/types/routes.go index 37832f8e..7dfa680d 100644 --- a/internal/types/routes.go +++ b/internal/types/routes.go @@ -24,6 +24,7 @@ type ( HealthMonitor() HealthMonitor SetHealthMonitor(m HealthMonitor) References() []string + ShouldExclude() bool Started() <-chan struct{} @@ -60,6 +61,7 @@ type ( Start(task.Parent) gperr.Error LoadRoutes() gperr.Error GetRoute(alias string) (r Route, ok bool) + // should be used like `for _, r := range p.IterRoutes` (no braces), not calling it directly IterRoutes(yield func(alias string, r Route) bool) NumRoutes() int FindService(project, service string) (r Route, ok bool)