How to optimize the heartbeat mechanism

Source: Internet
Author: User
Keywords Micro-letters mobile Internet micro-credit charges

The micro-letter signaling that storms can make people's eyes guide the heartbeat mechanism, then why does the heartbeat mechanism occur? Why would it bring a signaling storm to the mobile communications network?

Early heartbeat mechanism is used for the server's security backup mechanism, the purpose is to prevent the server from sudden panic, so the use of dedicated ports and lines between the server, short information through the periodic transmission, so the image of the analogy into a heartbeat. Once the other person's heartbeat message is not received , the server can take over the other's business and avoid business stagnation. The heartbeat information sent by the server can be very frequent, making the business unimpeded .

This mechanism is borrowed by the Internet application on the mobile phone, whether it is the native application of Android, QQ, Weibo and micro-letter, all adopt the heartbeat mechanism, that is, the terminal sends short information to the application server at regular intervals. But there are some differences compared to the heartbeat mechanism between servers:

1. Heartbeat information is a single direction, only the terminal to the application server;

2. Heartbeat information cycle is relatively long, such as the old version of the QQ Heartbeat cycle of 30s, the new version of QQ 180s, micro-letter for 300s,google native application for 1680s.

In addition, the Internet application of heartbeat packet in addition to declaring the terminal online, there is an important task is to provide a terminal instant address, user-friendly application server addressing.

With the application of the Internet heartbeat mechanism, application server can be issued in a timely manner (Push) user-related information, such as micro-letters in the short message, pictures or voice.

Heartbeat packs can also have a lot of side effects, such as a terminal that costs more electricity, and may also bring signaling storms to mobile communications networks.

Why does it seem like the perfect heartbeat mechanism brings signaling storms to mobile networks?

Originally, the Mobile communication network because of numerous users, scarce resources, each user is dynamic consumption of resources, such as IP address and wireless channel. Every time the heartbeat packet is sent, the mobile communication network is required to allocate resources to the user, and the distribution process is embodied in the sending and receiving of the signaling. The process of sending a heartbeat packet, involving as many as dozens of signaling.

With the popularity of Internet apps, a large number of terminals send periodic heartbeat packets, the effect is similar to the IP network of DDoS (distributed denial of service attacks, a commonly used hacker attacks), the inevitable impact on mobile communication network equipment, causing congestion and other situations, this phenomenon is a signaling storm. The signaling storm not only exists in China Mobile's GPRS network, but also exists in the WCDMA network and the CDMA network. Because of the huge number of subscribers to the China Mobile, the impact of the storm is more pronounced, in short, the difference between 50 and 100 steps.

Internet app's heartbeat mechanism to the mobile network's impact is very big, then what method can alleviate even solve this problem?

From the Internet app point of view, should distinguish between mobile network access or WLAN access, intelligent adjustment heartbeat packet Send frequency. When mobile network access, reduce the heartbeat packet send frequency, so although the server push information will have some delay, but the terminal more power, mobile network more robust. For example, the old version of QQ Heartbeat cycle of 30s, the new version of the QQ 180s, micro-letter for 300s, has shown a gradual extension of the trend, can be adjusted until close to Google's original application of 1680s around.

At present, the Internet app heartbeat packet sent frequency by the app single-handedly, which is unreasonable, should be open to users to set up, allowing users to save electricity and in a timely manner, such as switching between scenarios.

Now everyone's mobile phone has a number of Internet apps, such as QQ, micro-letter, micro-blog and Taobao, and so on, if each app sends a heartbeat packet, heartbeat packet send frequency will increase significantly. such as micro-mail, QQ and other apps, you can consider a joint heartbeat packet, so you can reduce a lot of heartbeat packets. In addition, if you unify the heartbeat pack from the operating system level, the effect will be better. Apple's iOS has made a good attempt to set up a position register APNs that will unite all the apps to send the heartbeat uniformly. The Android system can also do the same thing, said the millet phone is intended to do so, such as Ali OS should also be able to do. The OS that operators develop themselves should be an example.

The terminal side of these practices will be able to effectively reduce the heartbeat packets sent, thereby alleviating the signaling storm.

From the angle of the network side, if the terminal to send a heartbeat packet is a fait accompli, timely expansion of equipment is imperative. At present, the base station controller and the core network equipment is believed to be the impact of the storm, the need for priority expansion. Of course, operators have the difficulties, that is to help the app job. However, operators must also understand the importance of homeopathy, rather than passively take, as early as planned.

What's the plan? It's propaganda. From the point of view of the mobile network, the heartbeat pack is not necessary. The use of short message and app depth integration, without heartbeat packet can also easily realize the push of app message, and save the power of the terminal, and avoid the impact of the mobile network, the Le of both worlds?

In this way, the impact of the heartbeat mechanism on the mobile network will be controllable.

Related Article

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.