- Sort Score
- Result 10 results
- Languages All
Results 1 - 7 of 7 for ExtractLoadAssignments (0.28 sec)
-
pilot/pkg/xds/xds_test.go
ConfigTemplateInput: SidecarTestConfig{ ImportedNamespaces: []string{"./*", "included/*"}, Resolution: "STATIC", }, }) proxy := s.SetupProxy(baseProxy()) endpoints := xdstest.ExtractLoadAssignments(s.Endpoints(proxy)) if !slices.EqualUnordered(endpoints["outbound|80||app.com"], []string{"1.1.1.1:80"}) { t.Fatalf("expected 1.1.1.1, got %v", endpoints["outbound|80||app.com"]) }
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Wed Mar 27 16:59:05 UTC 2024 - 13.8K bytes - Viewed (0) -
pilot/test/xdstest/extract.go
got := map[string][]*endpoint.LocalityLbEndpoints{} for _, cla := range cla { if cla == nil { continue } got[cla.ClusterName] = cla.Endpoints } return got } func ExtractLoadAssignments(cla []*endpoint.ClusterLoadAssignment) map[string][]string { got := map[string][]string{} for _, cla := range cla { if cla == nil { continue }
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Tue Dec 19 22:42:42 UTC 2023 - 13.9K bytes - Viewed (0) -
pilot/pkg/xds/ads_test.go
ResourceNames: []string{clusterName}, VersionInfo: version, ResponseNonce: nonce, }) version = res.VersionInfo nonce = res.Nonce got := xdstest.MapKeys(xdstest.ExtractLoadAssignments(xdstest.UnmarshalClusterLoadAssignment(t, res.Resources))) if len(got) != 1 { t.Fatalf("expected 1 response, got %v", len(got)) } if got[0] != clusterName {
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Tue Jan 30 17:25:17 UTC 2024 - 30.3K bytes - Viewed (0) -
pilot/pkg/xds/delta_test.go
ResponseNonce: nonce, ResourceNamesSubscribe: add, ResourceNamesUnsubscribe: remove, }) nonce = res.Nonce got := xdstest.MapKeys(xdstest.ExtractLoadAssignments(xdstest.UnmarshalClusterLoadAssignment(t, xdsserver.ResourcesToAny(res.Resources)))) if !reflect.DeepEqual(expect, got) { t.Fatalf("expected clusters %v got %v", expect, got) } }
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Thu Jun 13 01:56:28 UTC 2024 - 15.2K bytes - Viewed (0) -
pilot/pkg/xds/mesh_network_test.go
if w.expectations == nil { return } t.Run("unweighted", func(t *testing.T) { // wait for eds cache update retry.UntilSuccessOrFail(t, func() error { eps := xdstest.ExtractLoadAssignments(s.Endpoints(w.proxy)) for c, want := range w.expectations { got := eps[c] if !slices.EqualUnordered(got, want) { err := fmt.Errorf("cluster %s, expected %v, but got %v", c, want, got)
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Wed Mar 27 16:59:05 UTC 2024 - 24.6K bytes - Viewed (0) -
pilot/pkg/serviceregistry/serviceregistry_test.go
} func expectEndpoints(t *testing.T, s *xds.FakeDiscoveryServer, cluster string, expected []string, metadata *model.NodeMetadata) { t.Helper() retry.UntilSuccessOrFail(t, func() error { got := xdstest.ExtractLoadAssignments(s.Endpoints(s.SetupProxy(&model.Proxy{Metadata: metadata}))) sort.Strings(got[cluster]) sort.Strings(expected) if !reflect.DeepEqual(got[cluster], expected) {
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Thu May 23 21:07:03 UTC 2024 - 51.2K bytes - Viewed (0) -
pilot/pkg/networking/core/sidecar_simulation_test.go
t.Errorf("expected clusters: %v, got: %v", xdstest.MapKeys(tt.clusters), got) } for cname, c := range cmap { // Check the upstream endpoints match got := xdstest.ExtractLoadAssignments([]*endpoint.ClusterLoadAssignment{c.GetLoadAssignment()})[cname] if !reflect.DeepEqual(tt.clusters[cname], got) { t.Errorf("%v: expected endpoints %v, got %v", cname, tt.clusters[cname], got) }
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Thu Jun 13 01:56:28 UTC 2024 - 84.7K bytes - Viewed (0)