--- apiVersion: apisix.apache.org/v2 kind: ApisixUpstream metadata: labels: app: test-service name: test-service namespace: crm spec: scheme: http loadbalancer: type: roundrobin timeout: connect: 10s send: 15s read: 15s discovery: args: group_name: namespace_id: type: eureka serviceName: service-test --- kind: ApisixRoute apiVersion: apisix.apache.org/v2 metadata: labels: app: test-service name: test-service namespace: crm spec: http: - match: hosts: - www.xxxx.com paths: - /service-test/* name: sroute plugins: - enable: true name: proxy-rewrite config: regex_uri: - "^/service-test/(.*)" - "/$1" timeout: connect: 10s send: 15s read: 15s upstreams: - name: test-service websocket: true
标签:15s,name,service,示例,namespace,eureka,test,apisix From: https://www.cnblogs.com/lfhblog/p/18215119