Domanda

I have a web service application and i fetch my data using GET request from my server. I wanted to activate APNS on my application and read some good tutorials on this topic. And i discovered we can send about 200bytes of data inside a push. My question is, will it be true to pass al my app's data through push notifications instead of sending GET request at specified times?

Note: For the moment, when any tables from my database changes i push a notification and as response my user open the application. During this launch, i create a GET request to my server to fetch the new data

È stato utile?

Soluzione

It is not guaranteed for push notification to even arrive every time. So you should not use it for your data. It should be used as notification as is intended.

Here is what apple says about push notification in their docs:

Important: Because delivery is not guaranteed, you should not depend on the remote-notifications facility for delivering critical data to an application via the payload. And never include sensitive data in the payload. You should use it only to notify the user that new data is available.

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top