Push notification on Mobile App using WebSockets?(Without APN & GCM)
Asked Answered
W

1

6

I am building a Hybrid Mobile Application using IONIC Framework. My problem is that my client is septic of using GCM and APN and asks to get a solution for PUSH notification independent of these two. So something inhouse needs to be build. I have two problem and a few questions about the same.

  1. Can web sockets help in giving the same functionlities that APN & GCM provide.
  2. If I use websockets in some fachion can I achieve PUSH Notification on the mobile application even if the app is closed but user's session persists.
  3. Can we build a PUSH server inhouse? If yes where can I find the specs according to OS of the Phone.
  4. I am well aware of Web Sockets, can it help for the above purpose?
  5. Point me to the specs required to Build such a server and how would I go ahead to configure with Ionic if possible.
  6. I would be using NodeJS, Mongo/Redis with web sockets.Thats what I am thinking please let me know if its otherwise and how to achieve.

Thanks

Wideman answered 27/8, 2016 at 10:14 Comment(1)
I'm thinking of the same thing too. Probably just need to find a way for the app to remain active such as reconnect when the connection is disconnected or when the phone restartEuhemerus
J
2

It's a lot of push service system that some of them is free and some of them are not

Also, you can implement by yourself, you need to have the server to support WebSocket then In application layer you need to connect to server (e.g, Service in android) and create your own broadcast to handle data came from WebSocket

Some point you need to remember : - Your application always needs to connect to your WebSocket link (battery life issue and network listener) - You must be sure that application always runs (e.g, when the device restarted [use android.permission.RECEIVE_BOOT_COMPLETED])

Jerold answered 27/8, 2016 at 10:50 Comment(2)
Sounds good. Even I would be looking for the same. Is there a Plugin for the same. I do have it for cordova but how to manage the websocket in hybrid appsWideman
sorry about that I don't think you find any plugin for that, you may need to create a custom plugin to handle it with javascript bridge for youJerold

© 2022 - 2024 — McMap. All rights reserved.