Quickstart-android: Firebase Database not receiving messages on china

Created on 16 Jul 2018  路  9Comments  路  Source: firebase/quickstart-android

I have a messaging App with Firebase Database and Firebase Auth. The same features work fine California, but not in China.

Environment

Both iOS and Android

iOS
Using Firebase (4.8.2)
Using FirebaseAnalytics (4.0.9)
Using FirebaseAuth (4.4.2)
Using FirebaseCore (4.0.14)
Using FirebaseDatabase (4.1.4)
Using FirebaseInstanceID (2.0.8)
Using FirebaseMessaging (2.0.8)
Using FirebaseStorage (2.1.2)

Step 3: Describe the problem:

Observed Results:

https://lh3.googleusercontent.com/8nlWD7iNlc7ClGezrhyiMd2Der-8EnRNZZrTsLv3Ds4jmjO99FE5V6_cxepYD_49rMz95H98zMeY8CIEU448CFvyFUiB9VpOk5Ry-EwkjB3PBPYXwXMhiRYUNFsPJJ0qDxNjKwFkmvWVsQ2M3g

Most helpful comment

It appears China has targeted mostly Google Domains and not Google IPs. As such, AppEngine works with custom domains utilising A and AAAA dns records (not CNAME as ghs.googlehosted.com is blocked) according to tests done with http://www.chinafirewalltest.com/ anyway. I'm wondering if the same trick would work for FCM. i.e. instead of using fcm.googleapis.com, allow any domain pointing to the same IPs or custom domain like appengine does. Seems far less costly than proxying or leaving FCM altogether...

Thoughts?

All 9 comments

All Google Services have been blocked in China, as mentioned here.

@jeffayan thanks for reporting this. While we'd love for Firebase to work everywhere, right now we can't guarantee the availability of any of our services in China. I apologize for the bad experience, but there's nothing we can do here.

@samtstern : https://github.com/urish/firebase-server/issues/56 will this solution work. This was posted long back and would like to know if there is still a way around to support for china.

hello any news about that ?
I heard that its now not blocked anymore in China, any confirmation ?

thanks

Any updates on this feature ? Should we have to move AWS instead ?

yes i checked, its blocked in China

FYI, still blocked as of July 2019

It appears China has targeted mostly Google Domains and not Google IPs. As such, AppEngine works with custom domains utilising A and AAAA dns records (not CNAME as ghs.googlehosted.com is blocked) according to tests done with http://www.chinafirewalltest.com/ anyway. I'm wondering if the same trick would work for FCM. i.e. instead of using fcm.googleapis.com, allow any domain pointing to the same IPs or custom domain like appengine does. Seems far less costly than proxying or leaving FCM altogether...

Thoughts?

yes i checked, its blocked in China

just to clarify, on our side we are using some services, and it depends on what you're talking about inside Firebase. Firebase Crashlytics, and Firebase Analytics work for us. However Firebase In-app messaging is blocked. So you might want to customize the SDK and put the domain behind your own to direct it to a server outside the country then route the data to the actual real Firebase domain.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

charlizesmith picture charlizesmith  路  5Comments

DenLangeKilde picture DenLangeKilde  路  5Comments

tekinarslan picture tekinarslan  路  5Comments

ksachdeva11 picture ksachdeva11  路  4Comments

fisache picture fisache  路  4Comments