- Sort Score
- Result 10 results
- Languages All
Results 1 - 4 of 4 for GetLabelSelector (0.28 sec)
-
pkg/kube/krt/filter.go
return false } } // Rest is expensive if f.selects != nil && !labels.Instance(getLabelSelector(object)).SubsetOf(f.selects) { if log.DebugEnabled() { log.Debugf("no match selects: %q vs %q", f.selects, getLabelSelector(object)) } return false } if f.selectsNonEmpty != nil && !labels.Instance(getLabelSelector(object)).Match(f.selectsNonEmpty) { if log.DebugEnabled() {
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Fri May 10 23:33:56 UTC 2024 - 4.8K bytes - Viewed (0) -
pkg/kube/krt/internal.go
if ok { return ac.Labels } panic(fmt.Sprintf("No Labels, got %T", a)) } // getLabelSelector returns the labels for an object, if possible. // Warning: this will panic if the labelSelectors is not available. func getLabelSelector(a any) map[string]string { ak, ok := a.(LabelSelectorer) if ok { return ak.GetLabelSelector() } val := reflect.ValueOf(a) if val.Kind() == reflect.Ptr { val = val.Elem()
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Fri May 10 23:33:56 UTC 2024 - 5.6K bytes - Viewed (0) -
pkg/kube/krt/bench_test.go
) type Workload struct { krt.Named ServiceNames []string IP string } // GetLabelSelector defaults to using Reflection which is slow. Provide a specialized implementation that does it more efficiently. type ServiceWrapper struct{ *v1.Service } func (s ServiceWrapper) GetLabelSelector() map[string]string { return s.Spec.Selector } var _ krt.LabelSelectorer = ServiceWrapper{}
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Tue Apr 09 19:55:53 UTC 2024 - 7K bytes - Viewed (0) -
pkg/kube/krt/core.go
} // LabelSelectorer is an optional interface that can be implemented by collection types. // If implemented, this will be used to determine an objects' LabelSelectors type LabelSelectorer interface { GetLabelSelector() map[string]string } // Labeler is an optional interface that can be implemented by collection types. // If implemented, this will be used to determine an objects' Labels type Labeler interface {
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Fri May 10 23:33:56 UTC 2024 - 6.9K bytes - Viewed (0)