Android push notification without Google service

I am from the world of Apple, so I do not have much experience with Android.

But what I'm looking for is the way that Android devices receive push notification without using third-party servers. The notification should be a standard Android notification (appearance)

I need this because I need it in a room that does not have access to the outside world. (I can not connect to any server). But I have my own WiFi, so users can receive push notifications from my server via my Wi-Fi.

I know this is not possible on iOS, but what about Android?

+4
source share
1 answer

You can use the Service remaining in the system (background) after the application exits. some samples HERE , you should be interested in the flag START_STICKY

you need to save some connection (socket?) or request an interval (not so good, but possible) inside your Service . Google services (including Firebase) do this on their own and "redeliver" receive push messages for a properly declared (in the manifest) application

+5
source

Source: https://habr.com/ru/post/1013840/


All Articles