GCMBroadcastReceiver not register using manifest or dynamically
<receiver
android:name="com.ee.nowmedia.core.pushnotification.PushBroadcastReceiver"
android:permission="com.google.android.c2dm.permission.SEND">
<intent-filter><!-- Receives the actual messages. -->
<action android:name="com.google.android.c2dm.intent.RECEIVE" /><!-- Receives the registration id. -->
<action android:name="com.google.android.c2dm.intent.REGISTRATION" />
<category android:name="com.ee.nowmedia.core.pushnotification" />
</intent-filter>
</receiver>
As of April 10, 2018, Google has deprecated GCM. The GCM server and client APIs are deprecated and will be removed as soon as April 11, 2019. Migrate GCM apps to Firebase Cloud Messaging (FCM), which inherits the reliable and scalable GCM infrastructure, plus many new features. See the migration guide to learn more. Read more at Google Cloud Messaging -- DEPRECATED 4/10/2018 documentation
So the code
<receiver
android:name="com.google.android.gms.gcm.GcmReceiver"
android:exported="true"
android:permission="com.google.android.c2dm.permission.SEND" >
<intent-filter>
......
</intent-filter>
</receiver>
is useless since 8.0 and also after 11Apr2019 for each API.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With