Hei,
We're looking to migrate from Cloud Endpoints to API Gateway, but there is one thing we're having a hard time figuring out - regional routing with a global HTTPS Load Balancer.
The
documentation simply states that
"You then configure a load balancer to handle requests to the API and forward the request to the appropriate region.", without giving any clues on how to achieve this.
Using Cloud Endpoints I would simply deploy the ESPv2 as Cloud Run instances in various regions, then use Serverless NEGs to connect those instances to the HTTPS Load Balancer.
But AFAIK it is not possible to connect a serverless NEG to an API Gateway, and normal zonal NEGs is not possible to use with serverless components.
I have a discussion with a support agent who claims that I should be able to use Global/Internet NEGs to connect my (regional) API Gateways to the Load Balancer, and that the LB will be able to figure out the region of the backends based on the URL to the API Gateways. However, it is not possible to:
1. Connect two (or more) global NEGs to the same load balancer, or
2. Connect two endpoints to the same global NEG
So I'm having a really hard time figuring out how to provide regional routing for API Gateway. So if anyone have any ideas, I'd love to hear them.. :)
Thanks!
Best regards,
Henrik