We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
1、软件环境版本: consul: 1.8.4 istio: 1.11.4
2、情形描述: 以下是该组件同步自动生成的serviceEntry的完整内容:
apiVersion: networking.istio.io/v1beta1 kind: ServiceEntry metadata: creationTimestamp: "2022-02-10T08:23:43Z" generation: 3 labels: manager: Aeraki registry: consul name: demo555.service.consul namespace: istio-system resourceVersion: "86920747" uid: fac9b44c-7bf3-40e6-b069-35c112743248 spec: endpoints:
当我在k8s上其他istio集群的应用里调用该外部服务时,会报"502 gateway", 错误。 但是当我参照官网,自己写serviceEntry的内容,如下:
apiVersion: networking.istio.io/v1alpha3 kind: ServiceEntry metadata: name: demo555.service.consul spec: endpoints:
调用就可以成功,不知道是哪里的原因?怎么样修改源代码,来生成正确的serviceEntry定义?
The text was updated successfully, but these errors were encountered:
我似乎找到答案了,consul上的服务定义里需要加入meta信息,指明服务的协议类型,生成的serviceEntry就不会是默认的tcp协议的了。
Sorry, something went wrong.
No branches or pull requests
1、软件环境版本:
consul: 1.8.4
istio: 1.11.4
2、情形描述:
以下是该组件同步自动生成的serviceEntry的完整内容:
apiVersion: networking.istio.io/v1beta1
kind: ServiceEntry
metadata:
creationTimestamp: "2022-02-10T08:23:43Z"
generation: 3
labels:
manager: Aeraki
registry: consul
name: demo555.service.consul
namespace: istio-system
resourceVersion: "86920747"
uid: fac9b44c-7bf3-40e6-b069-35c112743248
spec:
endpoints:
labels: {}
locality: dc2
ports:
tcp: 9093
hosts:
location: MESH_INTERNAL
ports:
number: 9093
protocol: TCP
targetPort: 9093
resolution: STATIC
当我在k8s上其他istio集群的应用里调用该外部服务时,会报"502 gateway", 错误。
但是当我参照官网,自己写serviceEntry的内容,如下:
apiVersion: networking.istio.io/v1alpha3
kind: ServiceEntry
metadata:
name: demo555.service.consul
spec:
endpoints:
hosts:
ports:
name: http
protocol: HTTP
resolution: STATIC
location: MESH_INTERNAL
调用就可以成功,不知道是哪里的原因?怎么样修改源代码,来生成正确的serviceEntry定义?
The text was updated successfully, but these errors were encountered: