Google recently announced that it would be deprecating Google Cloud Messaging (GCM) in favor of Firebase Cloud Messaging (FCM). As a result, we are advising all customers to update their Android apps from using GCM to using FCM if necessary.
Your developers should be able to tell you if your Android app is currently using GCM or FCM.
Alternatively, you can use Rapid Push Verification to see which service your app currently uses. To do this, go to Settings in the Localytics Dashboard, find the app you are interested in and click the blue button that says Test Push Integration. Once you get to Step 3 and scan the QR code, you should see a screen that looks like the image below. The push service your app currently uses can be found in the bottom left corner:
Generally, Google’s migration guide should be followed. However, we will add a few additional notes to ensure your Localytics integration should still be compliant.
- Ensure that your app is integrated with SDK v5 or higher.
- Follow steps 1 and 2 of the Google Migration guide.
- NOTE: It is vital that you follow Step 2 of Google's instructions—you must select your existing GCM project from the list of existing Google Cloud Projects and add it to Firebase. If you just create a new Firebase project and don't move the GCM project over, you will lose the ability to send pushes to all existing users.
- Follow step 3, but please don’t remove the wake lock block as suggested by Google:
<uses-permission android:name "android.permission.WAKE_LOCK" />
- Update your push receivers (this step assumes SDK 5+):
a. Remove the
ll_gcm_sender_idkey from your
b. For customers who use Localytics push receivers and services set
c. For customers who use custom push receivers, update your old receivers to extend the Firebase push services
Google provides migration guides on these steps here and here.
This integration covers Native Android integrations, in addition to the React-Native and Cordova wrappers. For Xamarin, please consult Microsoft’s documentation.
Firebase continues to support GCM Server API keys. If you still have an active GCM Server key as provided by Google, that key should continue to work in the Localytics system, and it is not required to upload anything new to the Localytics dashboard.
Once you have a new build of the app, please take a moment to use Rapid Push Verification to ensure your push integration is behaving properly. Once again, Rapid Push Verification relies on proper test mode integration.