- Sort Score
- Result 10 results
- Languages All
Results 1 - 8 of 8 for convertServices (0.21 sec)
-
pilot/pkg/serviceregistry/serviceentry/conversion.go
// TODO: ClusterExternalAddresses - for LB types, per cluster. Populated from K8S, missing // in SE. Used for multi-network support. return cfg } // convertServices transforms a ServiceEntry config to a list of internal Service objects. func convertServices(cfg config.Config) []*model.Service { serviceEntry := cfg.Spec.(*networking.ServiceEntry) creationTime := cfg.CreationTimestamp var resolution model.Resolution
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Wed May 29 02:03:58 UTC 2024 - 16.9K bytes - Viewed (0) -
pilot/pkg/serviceregistry/serviceentry/conversion_test.go
} // nolint: unparam func makeTarget(cfg *config.Config, address string, port int, svcPort *networking.ServicePort, svcLabels map[string]string, mtlsMode MTLSMode, ) model.ServiceTarget { services := convertServices(*cfg) svc := services[0] // default for _, s := range services { if string(s.Hostname) == address { svc = s break } } if mtlsMode == MTLS { if svcLabels == nil {
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Thu May 23 21:07:03 UTC 2024 - 39K bytes - Viewed (0) -
pilot/pkg/serviceregistry/serviceentry/controller_test.go
for i, svc := range services { ret[i] = svc.Hostname } return ret } for _, tt := range cases { t.Run(tt.name, func(t *testing.T) { as := convertServices(*tt.current) bs := convertServices(*tt.new) added, deleted, updated, unchanged := servicesDiff(as, bs) for i, item := range []struct { hostnames []host.Name services []*model.Service }{
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Wed May 29 15:31:09 UTC 2024 - 92.9K bytes - Viewed (0) -
pilot/pkg/serviceregistry/serviceentry/controller.go
log.Debugf("Handle event %s for service entry %s/%s", event, curr.Namespace, curr.Name) currentServiceEntry := curr.Spec.(*networking.ServiceEntry) cs := convertServices(curr) configsUpdated := sets.New[model.ConfigKey]() key := curr.NamespacedName() s.mutex.Lock() // If it is add/delete event we should always do a full push. If it is update event, we should do full push,
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Wed May 29 15:31:09 UTC 2024 - 36.8K bytes - Viewed (0) -
pilot/pkg/serviceregistry/kube/conversion_test.go
Port: 8080, Protocol: corev1.ProtocolTCP, }, { Name: "https", Protocol: corev1.ProtocolTCP, Port: 443, }, }, }, } service := ConvertService(localSvc, domainSuffix, clusterID, &meshconfig.MeshConfig{TrustDomain: domainSuffix}) if service == nil { t.Fatalf("could not convert service") } if service.CreationTime != tnow {
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Thu May 23 21:07:03 UTC 2024 - 12.7K bytes - Viewed (0) -
pilot/pkg/serviceregistry/kube/conversion.go
return &model.Port{ Name: port.Name, Port: int(port.Port), Protocol: kube.ConvertProtocol(port.Port, port.Name, port.Protocol, port.AppProtocol), } } func ConvertService(svc corev1.Service, domainSuffix string, clusterID cluster.ID, mesh *meshconfig.MeshConfig) *model.Service { addrs := []string{constants.UnspecifiedIP} resolution := model.ClientSideLB externalName := ""
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Thu May 23 21:07:03 UTC 2024 - 9.4K bytes - Viewed (0) -
pilot/pkg/serviceregistry/kube/controller/controller.go
namespaceDiscoveryHandlers []func(ns string, event model.Event) // This is only used for test stop chan struct{} sync.RWMutex // servicesMap stores hostname ==> service, it is used to reduce convertService calls. servicesMap map[host.Name]*model.Service // nodeSelectorsForServices stores hostname => label selectors that can be used to // refine the set of node port IPs for a service.
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Thu May 23 21:07:03 UTC 2024 - 41.2K bytes - Viewed (0) -
pilot/pkg/serviceregistry/kube/controller/controller_test.go
curr: &updatedSvc, prevConv: kube.ConvertService(svc, constants.DefaultClusterLocalDomain, "", nil), currConv: kube.ConvertService(updatedSvc, constants.DefaultClusterLocalDomain, "", nil), expect: true, }, testcase{ name: "target ports unchanged", prev: &svc, curr: &svc, prevConv: kube.ConvertService(svc, constants.DefaultClusterLocalDomain, "", nil),
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Thu May 23 21:07:03 UTC 2024 - 85K bytes - Viewed (0)