Da Documenti di Apple:
In iOS 8 and later, voice-over-IP (VoIP) apps register for registerForRemoteNotifications remote notifications instead of using this method. Using remote notifications eliminates the need for a timeout handler to check in with the VoIP service. Instead, when a calls arrives for the user, the VoIP service sends a VoIP remote notification to the user’s device. Upon receiving this notification, the device launches or wakes the app as needed so that it can handle the incoming call.
In passato, la chiamata setKeepAliveTimeout utilizzato per consentire un gestore di essere chiamato un tempo della fine e avrebbe un massimo di 10 secondi per uscire o essere costretto a terminare, anche le chiamate al gestore non sono garantite entro il valore di timeout.
Il nuovo (registerForRemoteNotifications) potrebbe funzionare correttamente poiché il gestore è interno (a IOS) e invierà l'app a chiamata quando si verifica un evento remoto (questo potrebbe anche riattivare l'app se è in-sleep).
In entrambi i casi, entrambi dovrebbero fare la stessa cosa, la versione precedente che gestireste il codice e quella nuova, ricevereste una notifica (anche gestirla da qualche parte), ma non controllerete più il timeout.
Da docs Apple:
Call this method to initiate the registration process with Apple Push Notification service. If registration succeeds, the app calls your app delegate object’s application:didRegisterForRemoteNotificationsWithDeviceToken: method and passes it a device token. You should pass this token along to the server you use to generate remote notifications for the device. If registration fails, the app calls its app delegate’s application:didFailToRegisterForRemoteNotificationsWithError: method instead.
Se si desidera che le notifiche remote della tua app per visualizzare avvisi, riprodurre suoni, o eseguire altre azioni dell'utente rivolto, è necessario chiamare il registerUserNotificationSettings: metodo per richiedere i tipi di notifiche tu vuoi usare. Se non chiami quel metodo, il sistema invia tutte le notifiche remote alla tua app in modo silenzioso. Poiché il processo di registrazione tiene conto delle impostazioni di notifica preferite dall'utente, anche la richiesta di accesso ai tipi di notifica rivolti all'utente non garantisce che vengano concesse. Per scoprire quali sono le impostazioni di notifica disponibili, utilizzare il metodo currentUserNotificationSettings.
e infine (per Un-registrazione):
You should call this method in rare circumstances only, such as when a new version of the app removes support for all types of remote notifications. Users can temporarily prevent apps from receiving remote notifications through the Notifications section of the Settings app. Apps unregistered through this method can always re-register.
Non sono sicuro, ma spero che questo aiuta.
saluti,
Heider Sati
Ho lo stesso problema. La mia app VoIP registra la registrazione sul timeout KeepAlive. Dovrebbe funzionare in ambiente lan anche senza connettività internet, il che significa nessuna notifica remota. La mia app funziona in questo momento con questa API obsoleta ma non sono sicuro di quanto tempo ci vorrà. – Phani2013