Closed RaidelRoss closed 1 year ago
In this thread, I see replies stating that Firebase push notifications are not designed to work if the application is closed. Does this make sense?
If so, what is the value of the com.google.firebase.messaging
package? Is it intended for another function?
issues:146
Expected behavior in FCM is for the notification to appear in the system tray, but your Activity itself has to create the local notification to pop up a message when the remote notification comes in.
More info: https://firebase.google.com/docs/cloud-messaging/android/receive
I'm adding something important for users who are encountering the same problem. After trying many things, we simply created scheduled messages and suddenly, on some mobiles, notifications started to come through even if the app was closed.
In conclusion, there are mobiles where this simply does not occur, like mine for example :( , no magic needs to be done, just follow what the documentation says and assume it's correct.
I hope this helps, regards.
[REQUIRED] Please fill in the following fields:
[REQUIRED] Please describe the issue here:
Notifications are not received when the application is closed. When the application is open, notifications are received, I get the notification id in OnMessageReceived When the application is minimized, notifications are received.
I've searched in forums and in issues but in none of them do I see that there is a solution. Reference is made to the documentation but I don't see that the people reporting the problem have resolved it.
Relevant Code:
This is how I register for events after Firebase is initialized.
Installing the package and subscribing to the events is not enough to receive messages when the application is closed, so my manifest ends up like this.