// GenerateIngressPaths generates the ingress paths
GenerateIngressPaths generates the ingress paths
// GenerateIngressPaths generates the ingress paths
func GenerateIngressPaths(m *wso2v1alpha2.Integration) []networking.HTTPIngressPath {
	var ingressPaths []networking.HTTPIngressPath
	httpPath := "/" + nameForService(m) + "(/|$)(.*)"
	pathType := networking.PathTypeImplementationSpecific
	httpIngressPath := networking.HTTPIngressPath{
		Path:     httpPath,
		PathType: &pathType,
		Backend: networking.IngressBackend{
			Service: &networking.IngressServiceBackend{
				Name: nameForService(m),
				Port: networking.ServiceBackendPort{
					Number: m.Spec.Expose.PassthroPort,
				},
			},
		},
	}
	ingressPaths = append(ingressPaths, httpIngressPath)
	for _, port := range m.Spec.Expose.InboundPorts {
		inboundPath := "/" + nameForInboundService(m) +
			"/" + strconv.Itoa(int(port)) + "(/|$)(.*)"
		inboundIngressPath := networking.HTTPIngressPath{
			Path: inboundPath,
			PathType: &pathType,
			Backend: networking.IngressBackend{
				Service: &networking.IngressServiceBackend{
					Name: nameForService(m),
					Port: networking.ServiceBackendPort{
						Number: port,
					},
				},
			},
		}
		ingressPaths = append(ingressPaths, inboundIngressPath)
	}
	return ingressPaths
}
func GenerateIngressPaths ( m * wso2v1alpha2 . Integration ) [ ] networking . HTTPIngressPath { var ingressPaths [ ] networking . HTTPIngressPath httpPath := " " + nameForService ( m ) + " " pathType := networking . PathTypeImplementationSpecific httpIngressPath := networking . HTTPIngressPath { Path : httpPath , PathType : & pathType , Backend : networking . IngressBackend { Service : & networking . IngressServiceBackend { Name : nameForService ( m ) , Port : networking . ServiceBackendPort { Number : m . Spec . Expose . PassthroPort , } , } , } , } ingressPaths = append ( ingressPaths , httpIngressPath ) for _ , port := range m . Spec . Expose . InboundPorts { inboundPath := " " + nameForInboundService ( m ) + " " + strconv . Itoa ( int ( port ) ) + " " inboundIngressPath := networking . HTTPIngressPath { Path : inboundPath , PathType : & pathType , Backend : networking . IngressBackend { Service : & networking . IngressServiceBackend { Name : nameForService ( m ) , Port : networking . ServiceBackendPort { Number : port , } , } , } , } ingressPaths = append ( ingressPaths , inboundIngressPath ) } return ingressPaths }
GenerateIngressPaths generates the ingress paths
GenerateIngressPaths generates the ingress paths
//Set HTTP ingress path // check inbound endpoint port is exist and update the ingress path