diff --git a/component/outbound/filter.go b/component/outbound/filter.go index 3a16a6d..94265d7 100644 --- a/component/outbound/filter.go +++ b/component/outbound/filter.go @@ -78,7 +78,10 @@ func (s *DialerSet) filterHit(dialer *dialer.Dialer, filters []*config_parser.Fu break } case "": - return false, fmt.Errorf(`key of "filter: %v()" cannot be empty`, filter.Name) + if dialer.Name() == param.Val { + subFilterHit = true + break + } default: return false, fmt.Errorf(`unsupported filter key "%v" in "filter: %v()"`, param.Key, filter.Name) } diff --git a/example.dae b/example.dae index 7079ae6..9674102 100644 --- a/example.dae +++ b/example.dae @@ -68,7 +68,7 @@ group { group2 { # Filter nodes from global node pool defined by subscription and node section above. # Pass node names as input of keyword/regex filter. - filter: subtag(regex: '^my_', another_sub) && name(keyword: netflix) + filter: subtag(regex: '^my_', another_sub) && !name(keyword: 'ExpireAt:') # Select the node with min average of the last 10 latencies from the group for every connection. policy: min_avg10