Release date of Custom Domains and CORS

155 views
Skip to first unread message

Antoine Couette

unread,
Feb 2, 2021, 11:27:21 AM2/2/21
to api-gateway-users
Hello,

Thank you for your work on the gateway, it looks promising !

Do you have any update on the release date of the following features : 
- CORS support
- Custom domains

We might have to make a decision shortly on whether to keep trying with the gateway or not. It would be greate to have those features released :)

Thank you 

Antoine

Jamie Ferguson

unread,
Feb 2, 2021, 8:26:16 PM2/2/21
to Antoine Couette, Nandan Sridhar, Josh Einhorn, api-gateway-users

--
You received this message because you are subscribed to the Google Groups "api-gateway-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to api-gateway-us...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/api-gateway-users/f84d4fcd-0d0b-4b3e-9516-e9dd8eece3e6n%40googlegroups.com.


--
Jamie Ferguson | Technical Program Manager | jamief...@google.com | 720.235.3982


Josh Einhorn

unread,
Feb 3, 2021, 1:23:31 PM2/3/21
to Antoine Couette, api-gateway-users, Nandan Sridhar
Hi Antoine,

Thanks for your inquiry! Technically, you can use API Gateway with CORS by implementing CORS in your backend application using the x-google-endpoint OpenAPI extensions. However I am guessing what you meant was for the API Gateway itself to return the CORS headers instead of passing through the OPTIONS requests to your application.

I can't give an exact release date, but I can tell you we're currently working on both of those features since they're clear requirements for many applications that would use an API Gateway. Both features should be available sometime in Q2 this year (this is just an estimate).

-Josh

On Tue, Feb 2, 2021 at 9:27 AM Antoine Couette <a.j.c...@gmail.com> wrote:
--
You received this message because you are subscribed to the Google Groups "api-gateway-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to api-gateway-us...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/api-gateway-users/f84d4fcd-0d0b-4b3e-9516-e9dd8eece3e6n%40googlegroups.com.


--
Josh Einhorn | Software Engineer | joshe...@google.com | 1-215-837-1102

Antoine Couette

unread,
Feb 4, 2021, 7:52:16 AM2/4/21
to Josh Einhorn, api-gateway-users, Nandan Sridhar
Hi Josh,

Thank you for your quick reply and your estimates.

I was not aware that I could use the x-google-endpoint OpenAPI extensions, it is not specified in the Api Gateway documentation, only in cloud endpoints. Actually, it would be acceptable for us to have this feature. How I understand this is that it is supposed to let through all the preflight OPTIONS requests matching the endpoints defined in the openapi spec right ? I tried to set it up on my api gateway but without any success... The options methods are still inaccessible : 

My Gateway config :
  "host": "mydomain.dev",
  "x-google-backend": {
    "address": "https://tnow-transfer-staging-kroqpgvuva-ew.a.run.app"
  },
  "x-google-endpoints": [
    {
      "name": "mydomain.dev",
      "allowCors": true
    }
  ],
  "paths": {
    "/transfers/{transferId}/files/{fileId}": {
      "delete": {


curl -X OPTIONS https://mydomain.dev/transfers/mytransfer/files/myfile
{"message":"NOT_FOUND:Request `OPTIONS /transfers/mytransfer/files/myfile` is not defined by this API.","code":404}

Maybe I got the feature wrong ? Or maybe it works only on Cloud Endpoints ?
The only solution at this point would be to define all the OPTIONS methods in the openapi spec file but it seems wrong.

Antoine

Josh Einhorn

unread,
Feb 4, 2021, 8:28:07 PM2/4/21
to Antoine Couette, api-gateway-users, Nandan Sridhar
Assuming that is the actual contents of your config, I believe the name field of the endpoints section must match the actual domain you're using to access the gateway (i.e. your *.gateway.dev sub-domain).

-Josh
Reply all
Reply to author
Forward
0 new messages