New issue
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
Hosting doesn't execute function if function region is not default #842
Comments
Also example repo https://github.com/istarkov/firebase-hosting-error |
Hi, this is expected behavior, please see https://firebase.google.com/docs/functions/locations#http_and_client_callable_functions, the blue box indicates that all functions that serve as hosting redirects must be in 'us-central1', this is due to the fact that that's where the hosting origin is. |
Thank you, any chance that this expected behaviour will be changed in near future or at least in a future? |
Hi, it will change in a future, but not in the near future. It depends on when Firebase Hosting launch origins in other geographies. |
Hello, |
Would love to see this implemented. My visitors are from Europe, and the TTFB from |
Hi @laurenzlong , does that mean that when Hosting will be available through other locations that I need that feature for my application. So, the sooner, the better :)! Thanks a lot for all this. |
A warning in bold should be written until this is fixed. I've spent too much time until I realized what happens. |
Hope cloud function for Firebase support |
Hi @laurenzlong , do you have any (good)? news about this ? I agree that as @wangchou said, cloud run would be an alternative, but it adds stack of services / technology. Hoping to read you soon. Thanks! |
We're still looking into this but right now our origin infrastructure is concentrated in
This means that the round trip time actually does something like doubling. We are investigating expanding the locations of our origin infrastructure, but until then we're wary about adding this capability as it is more likely to cause harm than good. |
@mbleigh - Please could you give us any estimates when Hosting origin will be located outside of US? The whole Firebase environment is amazing, but this make us think twice before switching to it. Thank you |
Really don't know why this issue has been closed if it has been not resolved, bumping +1. |
Second this, Firebase is amazing, but for European users this is a major caveat. |
Sorry, we can't comment on timelines as they are a little too subject to change. I appreciate the ongoing voice for supporting this as a feature, that's definitely something we take into account as we plan and build the product. |
I have an issue that might be related to this, but I do not fully understand this so I do not know. If someone who knows better and have time wants to comment on that, please see this question: https://stackoverflow.com/questions/57367131/403-from-deployed-firebase-function |
Would be a great thing to have this, we could finally add a hosting rewrite to our functions already living in europe-west1. |
Would be great indeed. For now, also using redirects as @hgghyxo mentioned: Function name firebase.json
|
@mcoevert commented on Aug 19, 2019, 10:36 AM GMT+2:
Redirects won't solve the CORS issues though. |
Would like to see europe-region support too. |
It seems that a rewrite can now be made with a Cloud Run service hosted on |
Sorry but a tiny blue box is easily missed. We've wasted too many hours on this problem, thinking it was a configuration problem in our end. |
Why is this closed - it's an issue for us in europe. Is there any explanation why it's only working for region us ? |
This issue is closed because it's a feature request for Firebase Hosting that can't be addressed directly in the Firebase CLI. Feature requests are tracked internally and I'd encourage you to request support for additional regions via this form. We are definitely aware that many of you want this feature, thanks for the feedback! |
Feature requests are only tracked internally? Doesn't that bring a lot of duplicate requests? I'd like to show support for these features to include non-US regions. |
Yes -- if you send a feature request, we will deduplicate it against other ones for our internal tracking (and it definitely helps to show more support for requests!). |
You could use Cloud Run instead of a Cloud Function if you don't need a VPC. Cloud Run (fully managed) cannot connect to VPC network currently. A workaround I've tested to use the VPC + custom domain + Cloud Function is to use a Cloud Run with a custom domain which is a proxy to the Cloud Function. It adds a bit of overhead but if your Cloud Run and Cloud Function are in the same region then, in theory, it shouldn't be much latency. That being said, I've monitored it over a month and Cloud Run beta is not 100% that stable: This is a repo with the proxy I've used if you want to deploy it to Cloud Run and give it a try https://github.com/reactgraphqlacademy/cloud-run-proxy I've tested a Cloudflare worker with a proxy in the same region that the Cloud Function and monitored it over the same period. It was slower than the Cloud Run, although it was 100% reliable. You can use this code if you want to test the Cloudflare worker https://gist.github.com/alexlbr/814446f03cf12e22f07ccaa580eb1154. @wangchou If I'm not mistaken, you could run the Cloudflare worker in Tokio, so it can be closer to the edge where the user is since Cloud Run is not supported yet in that region. The following monitors the Cloud Function directly without any proxy during the same period. I've used https://uptimerobot.com for the monitoring. Cloud Run looks very promising to me, I can't wait to the full release |
Any updates on this ? Why it's closed ? |
Impossible? |
@abdellahaski @l2aelba We definitely hear the pain point here. As @mbleigh said earlier, filing it as a feature request (see below) is the best way to help this gain traction for us internally. Thanks!
|
Would like to see asia-east2 support too. |
I'm close to giving up on firebase because of the bad documentation. An absolute minimum would be to issue a warning if there is no function in us-central matching the function in the redirect! I suggest the firebase team tries to let someone develop a project where the users are outside the US. It's crazy that we don't get warnings for this kind of stuff. |
Lets help each other out by doing as they ask - post a feature request: Here's a draft for you to copy/paste from - just get it done :)
|
Here hoping for this feature soon! |
Has anyone researched into using cloud run instead of cloud functions ? Cloud run provides functionalities in other regions also |
Two years after and this is still a problem.. Why is this closed by the way? |
Paging @laurenzlong
|
I choosed eur3 (europe-west) because it was in top of the list together with us-central1, and separeted from other locations. Thought these two are default. What should I do , is there any fix on this? |
Why????? |
Hi folks, thanks for all the feedback on this. We definitely hear you that you'd like to see Firebase Hosting support functions outside of We've heard about this quite often as a feature request, and it's on our roadmap though I can't comment on specific timelines. This repository is not the correct place to post feature requests for the Firebase Hosting product as a whole -- if you are interested in this feature, please submit a feature request so that we can continue to track the interest in this internally and prioritize the work that needs to happen to enable it. Thanks all! |
Hi, I think noone cares where you host, we want just a simple fix so that error won't show. This fix can be done in your code, nothing to do where you do your hosting.. And this is not request for a feature, the removal of a bug doesn't become a feature. Just remove that bug Thanks.. |
Version info
4.00
Platform Information
OS X
Steps to reproduce
function deployed to
europe-west1
Expected behavior
https://blablabla.firebaseapp.com
will get data fromhelloIvanA
Actual behavior
https://blablabla.firebaseapp.com
redirects tohttps://us-central1-yushkarala.cloudfunctions.net/helloIvanA/
and gives
Error: Forbidden Your client does not have permission to get URL /helloIvanA/ from this server.
The text was updated successfully, but these errors were encountered: