TobiasBuchholz / Plugin.Firebase

Wrapper around the native Android and iOS Firebase Xamarin SDKs
MIT License
220 stars 49 forks source link

Cloud Messaging - Isn't FirebaseInstanceService Depreciated in Favor of FirebaseMessagingService? #171

Closed Thomr77 closed 1 year ago

Thomr77 commented 1 year ago

Hi,

I have just been working through the Cloud Messaging documentation and noticed that there are receiver definitions for the AndroidManifest (which you also find in the (old) Xamarin documentation):

  <receiver
    android:name="com.google.firebase.iid.FirebaseInstanceIdInternalReceiver"
    android:exported="false" />
  <receiver
    android:name="com.google.firebase.iid.FirebaseInstanceIdReceiver"
    android:exported="true"
    android:permission="com.google.android.c2dm.permission.SEND">
    <intent-filter>
      <action android:name="com.google.android.c2dm.intent.RECEIVE" />
      <action android:name="com.google.android.c2dm.intent.REGISTRATION" />
      <category android:name="${applicationId}" />
    </intent-filter>
  </receiver>

Isn't the FirebaseInstanceIdService depreciated and replaced with the FirebaseMessagingService - so these receiver definitions are no longer necessary?

Google's FirebaseInstanceIdService Reference (where this is mentioned)

Xamarin FCM Reference

Please let me know - thanks!

TobiasBuchholz commented 1 year ago

Hey @Thomr77, the plugin is using the newer FirebaseMessagingService already and the other code you are referring to in the AndroidManifest.xml are other receiver definitions and should still be necessary as fas as I know.

Thomr77 commented 1 year ago

Hey @TobiasBuchholz - Okay excellent. Thank you for clearing this up! Vielen Dank!