Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

voip app ios8: is pushkit still best practice?

I am working on an app that needs reliable push messages (like any voip) under ios9. Here it says, that with IOS8+ one should use apns (registerForRemoteNotifications):

https://developer.apple.com/library/ios/documentation/UIKit/Reference/UIApplication_Class/index.html#//apple_ref/occ/instm/UIApplication/setKeepAliveTimeout:handler:

In the Optimize VOIP Apps document, Pushkit is preferred:

https://developer.apple.com/library/ios/documentation/Performance/Conceptual/EnergyGuide-iOS/OptimizeVoIP.html#//apple_ref/doc/uid/TP40015243-CH30-SW1

Does anybody have a clue on this? Or do they run the same code in the background?

like image 347
Werner Kratochwil Avatar asked Sep 24 '15 11:09

Werner Kratochwil


People also ask

Does firebase cloud messaging support VoIP PushKit services?

So, FCM can be used (theoretically) with PushKit but not with APNs at the same time. Although Apple specifies that PushKit uses APNs underneath, but it uses different authentication. We can either create two different project (very difficult to manage) or use other services for PushKit.

What is iOS PushKit?

Overview. The PushKit framework supports specialized notifications for updating your watchOS complications, responding to file provider changes, and receiving incoming Voice-over-IP (VoIP) calls. PushKit notifications differ from the ones you handle with the User Notifications framework.

What is iOS VoIP Swift?

A Voice over Internet Protocol (VoIP) app lets the user make and receive phone calls using an Internet connection instead of the device's cellular services.


1 Answers

From the documentation for VoIP Push Notifications:

  • The device is woken only when VoIP pushes occur, saving energy.
  • Unlike standard push notifications, which the user must respond to before your app can perform an action, VoIP pushes go straight to your app for processing.
  • VoIP pushes are considered high-priority notifications and are delivered without delay.
  • VoIP pushes can include more data than what is provided with standard push notifications.
  • Your app is automatically relaunched if it’s not running when a VoIP push is received.
  • Your app is given runtime to process a push, even if your app is operating in the background.

The biggest advantage of VoIP Push Notifications over regular ones is in my opinion, that the app gets relaunched if it was force-closed.

In general, if you wan't to use the push notifications for VoIP functionality, e.g. to notify about an incoming call, use PushKit. It was developed for this purpose. For all other cases, use regular push notifications. Your app won't go through the review if you use PushKit for an app without VoIP functionality anyways.

like image 175
Baris Akar Avatar answered Nov 15 '22 03:11

Baris Akar