What is remote push notification
Is the notification that is pushed from the remote server to the client this operation requires networking
Remote Push service, also known as APNs (Apple push Notification services)
Why do I need remote push notifications?
Limitations of traditional data acquisition:
As you can see, Zhang San if you want to send a message to John Doe you first need to send a message to the server, and then the server pushes the message to John Doe instead
But there is a problem is: If Zhang three to send a message to John Doe must first send to the server server and then push to John Doe that is to say Li four to correctly receive Zhang San send the message must and the server to establish a long connection, but if John Doe this side of QQ to shut down, so also means there is no relationship with the server, The server will not be able to communicate with the client.
With the above explanation, we found the limitations of traditional data acquisition, so in order to solve this problem in iOS, we need to use Apple's APNs server to see:
It is not difficult to understand through the above simplification, we send the message is not directly through the QQ server sent to John Doe, but first sent to you Apple's APNs server and pushed by the APNS server to send the message to John Doe
Of course, the bottom operation must not be so simple. I'm here to make it easy, so the picture is simple.
If you still don't understand, remember that all Apple devices will automatically connect to Apple's servers in a networked state
What is a long connection: Connect as long as you are connected
Effects of long connections:
- Time Calibration
- System upgrade
- Find My iphone
Benefits of long connections:
- Fast data transfer speed
- Keep your data up to date
Remote push Notifications