有没有通过dispatch.yaml文件的方式来分派到基于版本和服务名称的权利服务的请求?
我的意思是,我有这样的要求:https://va4-0-0-dot-api-acceptance-dot-myapp.appspot.com/auth/user
它是由我api-acceptance
服务发送的,但我想它去我auth-acceptance
服务。
我已经写在我的派遣这些规则,但它不工作...
- url: "va4-0-0.myapp.appspot.com/auth/*"
service: auth-acceptance
- url: "api-acceptance.myapp.appspot.com/auth/*"
service: auth-acceptance
按照documentation,您使用的URL模式:
https://[VERSION_ID]-dot-[SERVICE_ID]-dot-[MY_PROJECT_ID].appspot.com
将由dispatch.yaml文件被旁路,所以它不可能重新路由请求这种方式。
使用您想将请求路由到哪个服务和版本,你已经是非常具体的,以上述模式。
因此,无论您更改URL,以https://[VERSION_ID]-dot-auth-acceptance-dot-[MY_PROJECT_ID].appspot.com/auth/user
或使用default routing以后可以overriden by a dispatch.yaml。