mirror of
https://github.com/alibaba/higress.git
synced 2026-06-06 11:17:29 +08:00
upgrade to istio 1.19 (#1211)
Co-authored-by: CH3CHO <ch3cho@qq.com> Co-authored-by: rinfx <893383980@qq.com>
This commit is contained in:
@@ -310,7 +310,7 @@ func (w *watcher) getSubscribeCallback(serviceName string) func(idx uint64, data
|
||||
}
|
||||
|
||||
func (w *watcher) generateServiceEntry(host string, services []*consulapi.ServiceEntry) *v1alpha3.ServiceEntry {
|
||||
portList := make([]*v1alpha3.Port, 0)
|
||||
portList := make([]*v1alpha3.ServicePort, 0)
|
||||
endpoints := make([]*v1alpha3.WorkloadEntry, 0)
|
||||
|
||||
for _, service := range services {
|
||||
@@ -329,7 +329,7 @@ func (w *watcher) generateServiceEntry(host string, services []*consulapi.Servic
|
||||
protocol = common.ParseProtocol(metaData["protocol"])
|
||||
}
|
||||
|
||||
port := &v1alpha3.Port{
|
||||
port := &v1alpha3.ServicePort{
|
||||
Name: protocol.String(),
|
||||
Number: uint32(service.Service.Port),
|
||||
Protocol: protocol.String(),
|
||||
|
||||
@@ -143,8 +143,8 @@ func (w *watcher) generateServiceEntry(host string) *v1alpha3.ServiceEntry {
|
||||
log.Errorf("empty endpoints will not be pushed, host:%s", host)
|
||||
return nil
|
||||
}
|
||||
var ports []*v1alpha3.Port
|
||||
ports = append(ports, &v1alpha3.Port{
|
||||
var ports []*v1alpha3.ServicePort
|
||||
ports = append(ports, &v1alpha3.ServicePort{
|
||||
Number: w.Port,
|
||||
Name: "http",
|
||||
Protocol: string(protocol.HTTP),
|
||||
|
||||
@@ -251,7 +251,7 @@ func convertMap(m map[string]interface{}) map[string]string {
|
||||
}
|
||||
|
||||
func generateServiceEntry(app *fargo.Application) (*v1alpha3.ServiceEntry, error) {
|
||||
portList := make([]*v1alpha3.Port, 0)
|
||||
portList := make([]*v1alpha3.ServicePort, 0)
|
||||
endpoints := make([]*v1alpha3.WorkloadEntry, 0)
|
||||
|
||||
for _, instance := range app.Instances {
|
||||
@@ -261,7 +261,7 @@ func generateServiceEntry(app *fargo.Application) (*v1alpha3.ServiceEntry, error
|
||||
return nil, fmt.Errorf("unsupported protocol %v", val)
|
||||
}
|
||||
}
|
||||
port := &v1alpha3.Port{
|
||||
port := &v1alpha3.ServicePort{
|
||||
Name: protocol.String(),
|
||||
Number: uint32(instance.Port),
|
||||
Protocol: protocol.String(),
|
||||
|
||||
@@ -435,7 +435,7 @@ func (w *watcher) getSubscribeCallback(groupName string, serviceName string) fun
|
||||
}
|
||||
|
||||
func (w *watcher) generateServiceEntry(host string, services []model.Instance) *v1alpha3.ServiceEntry {
|
||||
portList := make([]*v1alpha3.Port, 0)
|
||||
portList := make([]*v1alpha3.ServicePort, 0)
|
||||
endpoints := make([]*v1alpha3.WorkloadEntry, 0)
|
||||
|
||||
for _, service := range services {
|
||||
@@ -443,7 +443,7 @@ func (w *watcher) generateServiceEntry(host string, services []model.Instance) *
|
||||
if service.Metadata != nil && service.Metadata["protocol"] != "" {
|
||||
protocol = common.ParseProtocol(service.Metadata["protocol"])
|
||||
}
|
||||
port := &v1alpha3.Port{
|
||||
port := &v1alpha3.ServicePort{
|
||||
Name: protocol.String(),
|
||||
Number: uint32(service.Port),
|
||||
Protocol: protocol.String(),
|
||||
|
||||
@@ -322,7 +322,7 @@ func (w *watcher) getSubscribeCallback(groupName string, serviceName string) fun
|
||||
}
|
||||
|
||||
func (w *watcher) generateServiceEntry(host string, services []model.SubscribeService) *v1alpha3.ServiceEntry {
|
||||
portList := make([]*v1alpha3.Port, 0)
|
||||
portList := make([]*v1alpha3.ServicePort, 0)
|
||||
endpoints := make([]*v1alpha3.WorkloadEntry, 0)
|
||||
|
||||
for _, service := range services {
|
||||
@@ -332,7 +332,7 @@ func (w *watcher) generateServiceEntry(host string, services []model.SubscribeSe
|
||||
} else {
|
||||
service.Metadata = make(map[string]string)
|
||||
}
|
||||
port := &v1alpha3.Port{
|
||||
port := &v1alpha3.ServicePort{
|
||||
Name: protocol.String(),
|
||||
Number: uint32(service.Port),
|
||||
Protocol: protocol.String(),
|
||||
|
||||
@@ -251,7 +251,7 @@ func (r *Reconciler) getAuthOption(registry *apiv1.RegistryConfig) (AuthOption,
|
||||
return authOption, nil
|
||||
}
|
||||
|
||||
authSecret, err := r.client.CoreV1().Secrets(r.namespace).Get(context.Background(), authSecretName, metav1.GetOptions{})
|
||||
authSecret, err := r.client.Kube().CoreV1().Secrets(r.namespace).Get(context.Background(), authSecretName, metav1.GetOptions{})
|
||||
if err != nil {
|
||||
return authOption, errors.New(fmt.Sprintf("get auth secret %s in namespace %s error:%v", authSecretName, r.namespace, err))
|
||||
}
|
||||
|
||||
@@ -622,7 +622,7 @@ func (w *watcher) DubboChildToServiceEntry(serviceEntry map[string]InterfaceConf
|
||||
}
|
||||
|
||||
func (w *watcher) generateServiceEntry(config InterfaceConfig) *v1alpha3.ServiceEntry {
|
||||
portList := make([]*v1alpha3.Port, 0)
|
||||
portList := make([]*v1alpha3.ServicePort, 0)
|
||||
endpoints := make([]*v1alpha3.WorkloadEntry, 0)
|
||||
|
||||
for _, service := range config.Endpoints {
|
||||
@@ -631,7 +631,7 @@ func (w *watcher) generateServiceEntry(config InterfaceConfig) *v1alpha3.Service
|
||||
protocol = common.ParseProtocol(service.Metadata[PROTOCOL])
|
||||
}
|
||||
portNumber, _ := strconv.Atoi(service.Port)
|
||||
port := &v1alpha3.Port{
|
||||
port := &v1alpha3.ServicePort{
|
||||
Name: protocol.String(),
|
||||
Number: uint32(portNumber),
|
||||
Protocol: protocol.String(),
|
||||
|
||||
Reference in New Issue
Block a user