Network processing details for iOS

Source: Internet
Author: User

(1) When cut into the background, the network is already running.

(2) When WiFi is turned off, the network will already be running and the iOS system will not handle anything.

(3) When the screen is locked, the iOS system recycles the network resources used by the app.

From the network:

iphone is via WiFi or GPRS internet, then when the socket connection is idle for a period of time, the connection may be shut down by the router, in order to maintain the connection, we need to constantly send heartbeat packets.

Since the iphone program will be suspended after it has been cut into the background, the heartbeat packet cannot be sent regularly, so this problem can only be solved by the server. The common approach is for the server to send a heartbeat packet to each client at regular intervals to maintain the connection. Each time the client receives a heartbeat packet, the client wakes up with iOS, gets a short CPU time, and then enters the pending state again.

Network processing details for iOS

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.