CN106685748A - Heartbeat information sending methods, server and terminal - Google Patents

Heartbeat information sending methods, server and terminal Download PDF

Info

Publication number
CN106685748A
CN106685748A CN201510751434.XA CN201510751434A CN106685748A CN 106685748 A CN106685748 A CN 106685748A CN 201510751434 A CN201510751434 A CN 201510751434A CN 106685748 A CN106685748 A CN 106685748A
Authority
CN
China
Prior art keywords
server
heart beating
terminal
heartbeat message
time
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201510751434.XA
Other languages
Chinese (zh)
Other versions
CN106685748B (en
Inventor
陈宽
陈阁
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
China Mobile Communications Group Co Ltd
China Mobile Hangzhou Information Technology Co Ltd
Original Assignee
China Mobile Communications Group Co Ltd
China Mobile Hangzhou Information Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by China Mobile Communications Group Co Ltd, China Mobile Hangzhou Information Technology Co Ltd filed Critical China Mobile Communications Group Co Ltd
Priority to CN201510751434.XA priority Critical patent/CN106685748B/en
Publication of CN106685748A publication Critical patent/CN106685748A/en
Application granted granted Critical
Publication of CN106685748B publication Critical patent/CN106685748B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/55Push-based network services
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/10Active monitoring, e.g. heartbeat, ping or trace-route

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Health & Medical Sciences (AREA)
  • Cardiology (AREA)
  • General Health & Medical Sciences (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

The invention discloses a heartbeat information sending method applied to a server. The method comprises that a terminal whose heartbeat information sending time needs adjusting is determined; and first heartbeat feedback information which comprises a heartbeat offset is sent to the terminal, so that the terminal adjusts next heartbeat information sending time according to the heartbeat offset. The invention also discloses a heartbeat information sending method applied to a terminal as well as the server and the terminal.

Description

A kind of heartbeat message sending method, server and terminal
Technical field
The present invention relates to the interconnection technique of the communications field, more particularly to a kind of heartbeat message sending method, service Device and terminal.
Background technology
With the continuous development of development of Mobile Internet technology, the application species installed in terminal is also more and more, with As a example by mobile terminal, such as mobile phone QQ, microblogging, wechat etc..Because certain applications belong to instant messaging class Keep being connected with the various servers of network side using, it is therefore desirable to mobile terminal long-time stable, so as to Meet the tendency of in the interaction for carrying out miscellaneous service data, therefore always online (always online) business of mobile terminal And give birth to.
In this modes of always online, in order to maintain the always online state of mobile terminal, interconnection Both sides need to detect whether also online in the case where temporarily not communicating by heartbeat mechanism.If service Device side detects a certain terminal and has currently gone offline, it is necessary to the resource that the terminal takes is discharged, in order to other Terminal is used, if mobile terminal detects server and currently gone offline, it is necessary to re-connect.
Existing heartbeat mechanism may be referred to shown in Fig. 1:
Step 101, when network side server receive mobile terminal transmission connection request after, start first Overtime timer.
Step 102, after mobile terminal connection server success, heart beating is set and sends cycle timer, Time-out time is heart beat cycle T.
Step 103, mobile terminal heart beating send cycle timer record the time exceed heart beat cycle T after, Mobile terminal to server sends a heartbeat message, and arranges second overtime timer.
Step 104, server are received after heartbeat message, reset the first overtime timer of server side, And respond a heart beating and feed back to mobile terminal.
If step 105, server long-time does not receive heartbeat message, cause the first overtime timer time-out, Illustrate that mobile terminal goes offline, need to discharge the resource that the mobile terminal takes.
If step 106, mobile terminal receive the heart beating feedback information of server, illustrate that server is normally online, Delete overtime timer.
If step 107, mobile terminal long-time does not receive heart beating feedback information, cause the second overtime timer Time-out, illustrates that server goes wrong, and mobile terminal needs to initiate connection request again.
If step 108, mobile terminal reconnection requests fail, after waiting Preset Time, then request is initiated again.
Step 109, mobile terminal are reconnected successfully, return to step 102.
It follows that mobile terminal is to send heartbeat message to maintain forever to server by default time interval Far away from line states.But in actual applications it is possible that because server is restarted, or network It is abnormal, cause a large amount of mobile terminals while situation about going offline, if the mobile terminal quantity for currently going offline is more, The waiting time reconnected after being gone offline due to each mobile terminal is identical, so causing meeting in the same time period There are a large amount of mobile terminals to be reconnected, it is excessive to easily cause server instantaneous pressure, in turn results in server dead Machine is restarted again;Simultaneously after the mobile terminal for going offline reconnects success, due to each mobile terminal Heart beat cycle is identical, so also result in a large amount of mobile terminals sends at short notice heartbeat message simultaneously, no But server stress can be increased, but also network data periodicity congestion can be caused, and then affect other networks Business.
The content of the invention
To solve above-mentioned technical problem, the embodiment of the present invention is expected to provide a kind of heartbeat message sending method, clothes Business device and terminal, are prevented from great amount of terminals at short notice simultaneously to server transmission heartbeat message, and then Reduce the instantaneous pressure of server, it is to avoid network data periodicity congestion.
The technical scheme is that what is be achieved in that:
In a first aspect, the embodiment of the present invention provides a kind of heartbeat message sending method, for server, including:
It is determined that needing to adjust the terminal that heartbeat message sends the time;
The first heart beating feedback information is sent to the terminal, the first heart beating feedback information includes that heart beating is inclined Shifting amount, in order to the transmission time that the terminal adjusts heartbeat message next time according to the heart beating side-play amount.
Optionally, before the determination needs to adjust the terminal that heartbeat message sends the time, methods described is also Including:
Whether the instantaneous heart beating density for judging reference time section is more than or equal to the maximum number of concurrent of the server With the product with reference to coefficient;The instantaneous heart beating density is the heartbeat message received in the reference time section The ratio of quantity and the reference time section;The reference coefficient is more than 0, less than or equal to 1;
The determination needs the terminal for adjusting the heartbeat message transmission time to include:
When the instantaneous heart beating density is more than or equal to the maximum number of concurrent and the product with reference to coefficient, really Surely need to adjust the terminal that heartbeat message sends the time.
Optionally, before the determination needs to adjust the terminal that heartbeat message sends the time, methods described is also Including:
It is determined that needing the quantity for adjusting the terminal that heartbeat message sends the time.
Second aspect, the embodiment of the present invention provides a kind of heartbeat message sending method, for terminal, including:
The first heart beating feedback information that the reception server sends, the first heart beating feedback information includes heart beating Side-play amount;
According to the heart beating side-play amount, adjustment sends the transmission time of heartbeat message to server next time.
Optionally, before the first heart beating feedback information that the reception server sends, methods described is also wrapped Include:
After establishing a connection with the server, the random time in a heart beat cycle is to server Send heartbeat message first.
Optionally, the random time in a heart beat cycle is sent after heartbeat message first to server, Methods described also includes:
If not receiving the first heart beating feedback information or second that the server sends in the first Preset Time Heart beating feedback information, does not include the heart beating side-play amount, when waiting random in the second heart beating feedback information Between after, to the server send connection request.
The third aspect, the embodiment of the present invention provides a kind of server, including:
Determining unit, needs to adjust the terminal that heartbeat message sends the time for determining;
Transmitting element, for sending the first heart beating feedback information, the first heart beating feedback letter to the terminal Breath includes heart beating side-play amount, and the letter of heart beating next time is adjusted according to the heart beating side-play amount in order to the terminal The transmission time of breath.
Optionally, the server also includes:
Judging unit, for judging the instantaneous heart beating density of reference time section whether more than or equal to the service The maximum number of concurrent of device and the product with reference to coefficient;The instantaneous heart beating density is to connect in the reference time section The ratio of the heartbeat message quantity for receiving and the reference time section;The reference coefficient be more than 0, less than or Equal to 1;
The determining unit specifically for:When the instantaneous heart beating density is more than or equal to the maximum number of concurrent During with product with reference to coefficient, it is determined that needing to adjust the terminal that heartbeat message sends the time.
Optionally, the determining unit is additionally operable to:
It is determined that needing the quantity for adjusting the terminal that heartbeat message sends the time.
Fourth aspect, the embodiment of the present invention provides a kind of terminal, including:
Receiving unit, for the first heart beating feedback information that the reception server sends, the first heart beating feedback Information includes heart beating side-play amount;
Adjustment unit, for according to the heart beating side-play amount, adjustment to send heartbeat message to server next time The transmission time.
Optionally, the terminal also includes:
Transmitting element, after establishing a connection with the server, in a heart beat cycle with Machine time to server sends heartbeat message first.
Optionally, the transmitting element is additionally operable to:
If not receiving the first heart beating feedback information or second that the server sends in the first Preset Time Heart beating feedback information, does not include the heart beating side-play amount, when waiting random in the second heart beating feedback information Between after, to the server send connection request.
A kind of heartbeat message sending method, server and terminal are embodiments provided, wherein for taking The heartbeat message sending method of business device includes:It is determined that needing to adjust the terminal that heartbeat message sends the time; The first heart beating feedback information is sent to the terminal, the first heart beating feedback information includes heart beating side-play amount, In order to the transmission time that the terminal adjusts heartbeat message next time according to the heart beating side-play amount.Compared to Prior art, if server receives at short notice more heartbeat message, can be offset by heart beating Amount adjustment terminal sends the time of heartbeat message next time, by the adjustment that the time is sent to terminal heartbeat message, So that the distribution of heartbeat message that heart beat cycle server is received tends to uniform, therefore can prevent Great amount of terminals simultaneously to the situation of server transmission heartbeat message, reduces the instantaneous of server at short notice Pressure, it is to avoid network data periodicity congestion.
Description of the drawings
Fig. 1 is the flow chart of heartbeat message sending method in prior art;
Fig. 2 is a kind of flow chart of heartbeat message sending method provided in an embodiment of the present invention;
Fig. 3 is the flow chart of another kind of heartbeat message sending method provided in an embodiment of the present invention;
Fig. 4 is the flow chart of another heartbeat message sending method provided in an embodiment of the present invention;
Fig. 5 is a kind of structural representation of server provided in an embodiment of the present invention;
Fig. 6 is the structural representation of another kind of server provided in an embodiment of the present invention;
Fig. 7 is the structural representation of another server provided in an embodiment of the present invention;
Fig. 8 is a kind of structural representation of terminal provided in an embodiment of the present invention;
Fig. 9 is the structural representation of another kind of terminal provided in an embodiment of the present invention;
Figure 10 is the structural representation of another terminal provided in an embodiment of the present invention;
Figure 11 is the structural representation that a kind of heartbeat message provided in an embodiment of the present invention sends system.
Specific embodiment
Below in conjunction with the accompanying drawing in the embodiment of the present invention, the technical scheme in the embodiment of the present invention is carried out clearly Chu, it is fully described by.
The embodiment of the present invention provides a kind of heartbeat message sending method, as shown in Fig. 2 it is used for server, bag Include:
Step 201, determination need to adjust the terminal that heartbeat message sends the time.
Example, a heart beat cycle can be divided into multiple time periods by server, count each time period The quantity of the heartbeat message for receiving, when the quantity of the heartbeat message received in certain time period is more, Can using the corresponding terminal of heartbeat message received in the time period as need adjust heartbeat message send when Between terminal.Wherein, the terminal not only includes mobile terminal, can also include Internet of Things, car networking In applications client, or wearable device, end of all application high concurrents such as PC in line service End.
Optionally, illustrate by taking reference time section as an example, the reference time section is the plurality of time period In any one.First server can respectively obtain instantaneous heart beating density and heart beating of reference time section The average heart beating density in cycle, then judges whether instantaneous heart beating density exceedes average heart beating density N times, when When the instantaneous heart beating density exceedes average heart beating density N times, illustrate what is received in reference time section The quantity of heartbeat message is more, and the transmission time for needing the heartbeat message to terminal is adjusted, therefore can be with It is defined as needing to adjust the end that heartbeat message sends the time in the terminal that heartbeat message is sent from reference time section End;When instantaneous heart beating density is not less than average heart beating density N times, illustrate to be received in reference time section The negligible amounts of the heartbeat message for arriving, can not be adjusted.Wherein, the N is more than 1, preferred N 2 can be equal to;The instantaneous heart beating density be the heartbeat message quantity that receives in the reference time section with The ratio of the reference time section;The average heart beating density is the heart beating letter received in the heart beat cycle Cease the ratio of quantity and the heart beat cycle.Specifically, it is assumed that reference time section is Ts, is received in the Ts seconds Heartbeat message number is M, then heartbeat message transmission density P is in reference time section:P=M/Ts;Assume to work as The front terminal number with server holding connection status is G, then the heartbeat message in a heart beat cycle sends Density PIt is flat=G/T;If P is more than PIt is flatDuring twice, illustrate that the heartbeat message in the reference time section is overstocked, need The heartbeat message transmission time of terminal that will be to heartbeat message is sent to server in reference time section is adjusted.
Optionally, because the processing speed of server is limited so that server has the restriction of maximum number of concurrent, Therefore in order to avoid the instantaneous pressure of server is excessive, it is also desirable to which the instantaneous heart beating density of reference time section is at least Less than maximum number of concurrent.Preferably, server can also first obtain the instantaneous heart beating density of reference time section, Then whether instantaneous heart beating density is judged more than or equal to J*E, wherein E is that server is corresponding maximum concurrent Number, J is the coefficient less than or equal to 1, when the instantaneous heart beating density is more than or equal to J*E, explanation The quantity of the heartbeat message received in reference time section is more, when needing the transmission to the heartbeat message of terminal Between be adjusted, therefore can send from reference time section be defined as in the terminal of heartbeat message need adjustment Heartbeat message sends the terminal of time;When instantaneous heart beating density is less than J*E, illustrate to be connect in reference time section The negligible amounts of the heartbeat message for receiving, can not be adjusted.
In practical application, or each time period pre-sets amount threshold, and server first can be obtained The quantity of the heartbeat message received in reference time section is taken, then judges the quantity whether more than or equal to ginseng Time period corresponding predetermined number threshold value is examined, when the quantity is more than or equal to the corresponding present count of reference time section During amount threshold value, illustrate that the quantity of heartbeat message received in reference time section is more, need the heart to terminal The transmission time of hop-information is adjusted, therefore can send in the terminal of heartbeat message from reference time section It is determined that needing to adjust the terminal that heartbeat message sends the time;Preset when the quantity is corresponding less than reference time section During amount threshold, the negligible amounts of heartbeat message received in reference time section are illustrated, can not be adjusted It is whole.Preferably, the corresponding predetermined number threshold value of reference time section can be E*Ts*J, wherein, E is service The corresponding maximum number of concurrent of device, J is the coefficient less than or equal to 1, and Ts is reference time section.Practical application In, each time period, corresponding amount threshold can be set as the case may be, and the present invention does not do to this Limit.
Step 202, to the terminal send the first heart beating feedback information, in the first heart beating feedback information Including heart beating side-play amount, heartbeat message next time is adjusted according to the heart beating side-play amount in order to the terminal The transmission time.
After it is determined that needing to adjust the terminal that heartbeat message sends the time, first heart can be sent to the terminal Jump feedback information, the first heart beating feedback information includes heart beating side-play amount, when terminal receive this first During heart beating feedback information, heart beating side-play amount is obtained, then adjusted next time to service according to the movement side-play amount Device sends the time of heartbeat message.
Example, heart beating side-play amount W can be calculated according to formula (2), wherein, formula (2) is W=Ts+H, the H are 0 to the random integers between (T-Ts).The heart beating calculated by formula (2) Side-play amount is adjusted to the transmission time of the heartbeat message of terminal, can cause to be received in a heart beat cycle To the distribution of heartbeat message tend to uniform.
So, if server receives at short notice more heartbeat message, heart beating can be passed through Side-play amount adjustment terminal sends the time of heartbeat message next time, by sending the time to terminal heartbeat message Adjustment so that the distribution of the heartbeat message that heart beat cycle server is received tends to uniform, therefore can To prevent great amount of terminals at short notice simultaneously to the situation of server transmission heartbeat message, server is reduced Instantaneous pressure, it is to avoid network data periodicity congestion.
Optionally, before the determination needs to adjust the terminal that heartbeat message sends the time, it may also be determined that Need the quantity for adjusting the terminal that heartbeat message sends the time.
The quantity of the heartbeat message that server is received in reference time section may be more, is not each end The transmission time of the heartbeat message at end is required for being adjusted, and generally only needs to adjust minority terminal The transmission time of heartbeat message can so that the heartbeat message received in reference time section negligible amounts to Suitable level, therefore the quantity for needing to adjust the terminal that heartbeat message sends the time is can determine first.Show Example, quantity Q for needing to adjust the terminal that heartbeat message sends the time, institute can be determined according to formula (1) Formula (1) is stated for Q=(Ts*P-Ts*PIt is flat) * 100/ (Ts*P) * M, wherein, the Ts is the reference time Section;The P is the instantaneous heart beating density of reference time section;The PIt is flatAverage heart beating for heart beat cycle is close Degree;The M is the quantity of the heartbeat message received in the reference time section.
A kind of heartbeat message sending method is embodiments provided, methods described includes:It is determined that needing to adjust Whole heartbeat message sends the terminal of time;The first heart beating feedback information, first heart are sent to the terminal Jumping feedback information includes heart beating side-play amount, adjusts next according to the heart beating side-play amount in order to the terminal The transmission time of secondary heartbeat message.Compared to prior art, if server receive at short notice it is more Heartbeat message, terminal can be adjusted by heart beating side-play amount and send time of heartbeat message next time, pass through The adjustment of time is sent to terminal heartbeat message so that the heart beating letter that a heart beat cycle server is received The distribution of breath tends to uniform, therefore can prevent great amount of terminals at short notice simultaneously to server transmission heart beating The situation of information, reduces the instantaneous pressure of server, it is to avoid network data periodicity congestion.
The embodiment of the present invention provides another kind of heartbeat message sending method, and for terminal, the terminal includes moving Dynamic terminal, also including Internet of Things, the applications client in car networking, or also include wearable device, it is individual People's computer etc. is all can to apply high concurrent in the terminal of line service.As shown in figure 3, the heartbeat message is sent out Delivery method includes:
The first heart beating feedback information that step 301, the reception server send, the first heart beating feedback information Include heart beating side-play amount.
When server determines the terminal that the terminal is the transmission time for needing adjustment heartbeat message, can be to the end End sends the first heart beating feedback information, and the first heart beating feedback information includes heart beating side-play amount.
Step 302, according to the heart beating side-play amount, adjustment sends sending out for heartbeat message to server next time Send the time.
Example, it is assumed that the heart beating side-play amount that the first heart beating feedback information that dynamic terminal is received includes is W, The time of this terminal transmission heartbeat message is the T in this heart beat cycle T1Moment, then terminal next time The time for sending heartbeat message is T1+ W, i.e., the time that next time terminal sends heartbeat message is the next heart T in the T of hop cycle2, shown T2Moment is T2=T1+W。
So, if server receives at short notice more heartbeat message, terminal can basis The heart beating side-play amount adjustment that the first heart beating feedback information that server sends includes sends heartbeat message next time Time, by the adjustment that the time is sent to heartbeat message so that send to server in heart beat cycle The distribution of heartbeat message tend to uniform, therefore can prevent great amount of terminals at short notice simultaneously to server The situation of heartbeat message is sent, the instantaneous pressure of server is reduced, it is to avoid network data periodicity congestion.
Optionally, before the first heart beating feedback information that the reception server sends, methods described is also wrapped Include:After establishing a connection with the server, the random time in a heart beat cycle is to server Send heartbeat message first.
Example, if server is restarted due to technical reason, great amount of terminals can simultaneously with service Device establishes a connection, therefore also can send heartbeat message to server simultaneously, therefore can cause server Instantaneous pressure is excessive, server can be also again led to when serious and is restarted so that server was absorbed in due to wink When pressure it is excessive and do not stop in the vicious cycle restarted, therefore, when terminal and server establish a connection it Afterwards, the time first to server transmission heartbeat message can be between random number.Specifically, in terminal and institute State after server establishes a connection, can send to server in the random time in a heart beat cycle Heartbeat message first.So because each terminal to server sends the time for sending heartbeat message first not Together, therefore the instantaneous power of server can be avoided excessive.
Optionally, the random time in a heart beat cycle is sent after heartbeat message first to server, If not receiving the first heart beating feedback information or the second heart beating that the server sends in the first Preset Time Feedback information, does not include the heart beating side-play amount in the second heart beating feedback information, after waiting random time, Connection request is sent to the server.
Common, server needs to send heart beating to terminal after the heartbeat message for receiving terminal transmission Feedback information, the heart beating feedback information can be the first heart beating feedback information for including heart beating side-play amount, also may be used Be not including heart beating side-play amount the second heart beating feedback information.Therefore in practical application, terminal is to service Device is sent after heartbeat message, it may be determined that whether receive what the server sent in the first Preset Time The first heart beating feedback information or the second heart beating feedback information, if terminal is not received in the first Preset Time The the first heart beating feedback information sent to server or the second heart beating feedback information, then illustrate that server falls Line, it is impossible to maintain the state that terminal is always online, therefore terminal to need to be re-connected with server,
But, if server is because that technology goes offline caused by restarting, can cause to be connected with the server All terminals need to be re-connected with server that server may be received at short notice greatly simultaneously Amount connection request, it is larger to be so easily caused server instantaneous pressure, therefore determines in terminal and need and service When device is reconnected, can wait after random event, then connection request is sent to server.Such one Come, due to time that each terminal to server sends connection request it is different, it is to avoid in the server short time The situation of a large amount of connection requests is received, prevents server instantaneous pressure excessive.
Optionally, the random time X can be calculated according to formula (3), formula (3) is X=A+B, The A is the set time;The B be 0 to (S/ (R*J)) in random integers;The S is described The maximum number of user amount of server;The R is the server treatable connection request number per second, described J is the coefficient more than 0, less than or equal to 1.Wherein, A can be the reboot time of server, that is, Say that all terminals send connection request after Server Restart to server, in case terminal is in Server Restart When go offline due to detecting server, and constantly send connection request to server, can so avoid resource Waste.S/R illustrates the number of times of the server connection request that can be processed for each terminal per second, by The quantity of the connection request that can be processed is likely less than in the quantity of the server heartbeat message that can be processed per second, Therefore a coefficient less than 1 can be multiplied by R, represents that server is per second by (S/ (R*J)) and be directed to The number of times of the heartbeat message that each terminal can be processed.Random Waiting Time is arranged by the method, effectively Avoid causes network and server stress excessive because a large amount of clients are instantaneously reconnected, and improves system stability.
The embodiment of the present invention provides another kind of heartbeat message sending method, including:The reception server send the One heart beating feedback information, the first heart beating feedback information includes heart beating side-play amount, then according to the heart Side-play amount is jumped, adjustment sends the transmission time of heartbeat message to server next time.Compared to prior art, If server receives at short notice more heartbeat message, terminal can be sent according to server the The heart beating side-play amount adjustment that one heart beating feedback information includes sends the time of heartbeat message next time, by right Heartbeat message sends the adjustment of time so that the heartbeat message sent to server in heart beat cycle point Cloth tends to uniform, therefore can prevent great amount of terminals at short notice simultaneously to server transmission heartbeat message Situation, reduces the instantaneous pressure of server, it is to avoid network data periodicity congestion.
The embodiment of the present invention provides a kind of heartbeat message sending method, as shown in figure 4, including:
After step 401, terminal and server establish a connection, during random in a heart beat cycle Between to server send heartbeat message.
Common, terminal needs to establish a connection with server first, and specifically, terminal to server is sent out Connection request is sent, server sends connection feedback after the connection request is received to terminal, if eventually Termination receives the connection feedback of server transmission, illustrates to have been set up annexation between terminal and server.
After terminal and server establish a connection, in order to maintain always online state, need to service Device sends heartbeat message.Optionally, terminal receive server transmission connection feedback after, Ke Yishe Heart beating transmission timer first is put, is regularly the random time in a heart beat cycle T, the heart first is set Timing is immediately begun to when jumping transmission timer, when the timing of the intervalometer meets or exceeds the timing, terminal Send heartbeat message first to server first.For example, it is assumed that the timing of heart beating transmission timer first is T0, That is terminal when being separated by T0, sends first after the connection feedback for receiving server transmission to server Heartbeat message, T0 can be calculated by formula T0=rand () % (T+1), wherein, rand () For equally distributed random function, the integer between 0~RAND_MAX can be produced, therefore Rand () % (T+1) can produce the random integers in 0 to T.
Step 402, after terminal and server establish a connection, server judges whether pre- second If receiving the heartbeat message of terminal transmission in the time;If receiving the heart beating of terminal transmission in the second Preset Time Information, execution step 403;If not receiving the heartbeat message of terminal transmission in the second Preset Time, perform Step 414.
After connection feedback is sent to terminal, server waits the heartbeat message of receiving terminal to server, but It is because server needs to reserve resource for the terminal when the heartbeat message of terminal is waited, so server is simultaneously It is not unconfined wait, and is to wait for the second Preset Time, if server does not have in the second Preset Time The heartbeat message of terminal transmission is received, then illustrates that terminal has currently gone offline, server can discharge the terminal The resource of occupancy.
Example, server can arrange a connection overtime timer after to the reversed feedback of terminal send chain, The timing of the connection overtime timer be the second Preset Time, if server do not have the second Preset Time it Heartbeat message is inside received, terminal disconnection is illustrated, server can discharge the resource that the terminal takes, for example Delete the connection overtime timer arranged for the terminal;If server is received within the second Preset Time Heartbeat message, connection overtime timer is deleted, and restarts timing.
Step 403, server generate the second heart beating feedback information according to the heartbeat message, and by described the Two heart beating feedback informations are sent to terminal.
Server can generate second after the heartbeat message for receiving terminal transmission according to the heartbeat message Heart beating feedback information, because now terminal has just just established a connection with server, server can't be true The fixed time for whether needing to send heartbeat message to terminal is adjusted, so server is to what terminal sent Not including the second heart beating feedback information of heart beating side-play amount.Server sends the second heart beating feedback information To terminal, for notifying that terminal current server is online, always online state keeps.
The second heart beating whether step 404, terminal judges receive server transmission in the first Preset Time is anti- Feedforward information;If receiving the second heart beating feedback information of server transmission, execution step in the first Preset Time 405;If not receiving the second heart beating feedback information of server transmission, execution step in the first Preset Time 415。
It is to notify that server present terminal, in presence, is sending that terminal to server sends heartbeat message After heartbeat message, whether terminal also needs to determine server currently in presence.Example, terminal May determine whether second heart that server transmission is received in the first Preset Time after heartbeat message is sent Jump feedback information.Specifically, after heartbeat message is sent, terminal can arrange feedback overtime timer, The timing of the feedback overtime timer is the first Preset Time, and after terminal sends heartbeat message timing is started, If receiving the second heart beating feedback information of server transmission in the timing of feedback overtime timer, service is illustrated Device is currently online, and feedback overtime timer is deleted;If also not receiving clothes more than the timing of feedback overtime timer The second heart beating feedback information that business device sends, illustrates that server has currently gone offline, and terminal needs to carry out again Connection.
Step 405, terminal send heartbeat message, execution step 406 according to heart beat cycle to server.
If terminal receives the heart beating feedback information of server transmission in the first Preset Time, illustrate that server exists Line, the annexation between terminal and server is present always, in order to ensure the normal phase presence of terminal, Terminal needs to send heartbeat message to server according to heart beat cycle T, because the heartbeat message first of terminal is Send at random, so even afterwards each terminal periodically sends according to heart beat cycle T to server Heartbeat message, do not result in the situation that short time server receives multiple heartbeat messages yet, it is to avoid service Device instantaneous pressure is excessive.
Whether step 406, the instantaneous heart beating density of server detection reference time section are more than or equal to the clothes The maximum number of concurrent of business device and the product with reference to coefficient;When the instantaneous heart beating density with reference to the time period is more than or waits When the maximum number of concurrent of the server is with the product for referring to coefficient, execution step 407;Work as the reference time When the instantaneous heart beating density of section is less than the maximum number of concurrent of the server with the product with reference to coefficient, step is performed Rapid 413.
In practical application, a heart beat cycle can be divided into multiple time periods, due to being connected with server Terminal quantity it is more, in fact it could happen that the more situation of heartbeat message that certain time period server is received, But the processing speed of server is limited, the restriction that there is maximum number of concurrent, if the instantaneous heart beating of server Density is larger, may result in that server instantaneous pressure is excessive, and then causes the feelings of Server Restart or deadlock Condition.Therefore server can first obtain the instantaneous heart beating density of reference time section, then judge instantaneous heart beating Whether density be more than or equal to J*E, and wherein E is the corresponding maximum number of concurrent of server, J be more than 0, it is little In or coefficient equal to 1, when the instantaneous heart beating density is more than or equal to J*E, illustrate reference time section The quantity of the heartbeat message for inside receiving is more, and the transmission time for needing the heartbeat message to terminal is adjusted, Therefore it is defined as needing to adjust heartbeat message transmission in the terminal that heartbeat message can be sent from reference time section The terminal of time;When instantaneous heart beating density is less than J*E, the heart beating letter received in reference time section is illustrated The negligible amounts of breath, can not be adjusted.The instantaneous heart beating density is to receive in the reference time section The ratio of the heartbeat message quantity for arriving and the reference time section.The embodiment of the present invention is as a example by reference time section Illustrate, the reference time section is any one in multiple time periods.
Step 407, server determine the quantity of the terminal for needing to carry out heart beating adjustment, execution step 408.
If the quantity of the heartbeat message that server is received in reference time section is larger, illustrate to need to reference The heartbeat message transmission time for sending the terminal of heartbeat message in time period to server is adjusted, and then subtracts The quantity of the heartbeat message received in little reference time section.First server determines and needs to carry out heartbeat message The quantity of the terminal of transmission time adjustment, example, the computational methods of the Selecting All Parameters of terminal are, K=(Ts*P-Ts*PIt is flat) * 100/ (Ts*P), after calculating the Selecting All Parameters of terminal, it may be determined that needs are carried out Heartbeat message sends quantity Q of the terminal of time adjustment:Q=K%*M, the K% represents percent K, For the selection ratio of terminal, the M is the quantity of the heartbeat message received in reference time section.
Step 408, server select the terminal for needing to carry out heart beating adjustment, execution step 409.
After the quantity of terminal for needing to be adjusted is determined, server also need to select it is concrete which Terminal is the terminal for needing to carry out heart beating adjustment, because if the front M*K% that arbitrarily will be received in reference time section The heartbeat message transmission time of individual terminal is adjusted or whole by latter M*K% received in reference time section The heartbeat message transmission time at end is adjusted, and still can cause the heart beating that the second half section of reference time section receives The density of information is larger, or the density of heartbeat message that the front half section of reference time section is received is larger, or Easily cause server instantaneous pressure larger, it is therefore desirable to randomly select needs in reference time section and adjusted Whole terminal.
Example, can determine that the corresponding terminal of currently received heartbeat message is by simple random algorithm No is the terminal for needing to be adjusted.Specifically, illustrate by taking reference terminal as an example, when referring to the time period Server is received after the heartbeat message of reference terminal transmission, the value of rand () %100 is calculated, if the value is little In K, then reference terminal is defined as the terminal for needing to be adjusted, is otherwise defined as reference terminal being not required to The terminal to be adjusted, wherein, rand () %100 can produce the random integers between 0 to 99.
Step 409, after server receives the heartbeat message that the terminal that needs to carry out heart beating adjustment sends, to The terminal sends the first heart beating feedback information, and the first heart beating feedback information includes the heart of the terminal Jump side-play amount, execution step 410.
Example, since it is determined reference terminal is the terminal for needing to be adjusted, therefore when server is received After the heartbeat message that reference terminal sends, according to the first heart beating feedback information that the heartbeat message is generated, should First heart beating feedback information includes the heart beating side-play amount of reference terminal, wherein, heart beating side-play amount can basis Concrete condition is configured in advance, and for example, heart beating side-play amount W can pass through formula (2) W=Ts+rand () % (T-Ts+1) is calculated, and the heart beating side-play amount calculated by the algorithm is adjusted terminal and sent The time of heartbeat message, the distribution that can cause the heartbeat message in a heart beat cycle tends to uniform.
Step 410, the terminal for carrying out heart beating adjustment is needed to receive the first heart beating feedback letter that server is sent to After breath, the heart beating side-play amount in the first heart beating feedback information, execution step 411 are obtained.
Example, after the first heart beating feedback information that reference terminal receives including heart beating side-play amount, can To obtain the heart beating side-play amount, specifically, reference terminal parses the first heart beating feedback information, according to this The mark of one heart beating feedback information determines in the first heart beating feedback information whether include heart beating side-play amount, if When determining that the first heart beating feedback information includes heart beating side-play amount, obtain in the first heart beating feedback information and wrap The heart beating side-play amount for including.
, according to the heart beating side-play amount, adjustment sends the time of heartbeat message next time for step 411, terminal, Execution step 412.
Example, the first heart beating feedback information that reference terminal is received includes heart beating side-play amount W, it is assumed that The time of this reference terminal transmission heartbeat message is the T in this heart beat cycle T1Moment, then next time The time of reference terminal transmission heartbeat message is T1+ W, i.e., next time reference terminal send heartbeat message when Between be next heart beat cycle T in T2Moment is T2=T1+ W, while can be by heartbeat message correspondence Serial number be set to 1.
Step 412, terminal send next heartbeat message according to the time after adjustment to server, terminate This process step.
Example, reference terminal in next heart beat cycle, according to the heartbeat message after adjustment transmission when Between to server send heartbeat message, specifically, reference terminal can wait T1After+W, to server Send next heartbeat message.
Step 413, server are that each heartbeat message for receiving generates the second heart beating feedback information, and The heart beating feedback information is sent to into corresponding terminal, process ends step.
The quantity of the heartbeat message received in reference time section when server illustrate to join less than reference threshold The quantity for examining the heartbeat message that time period server is received is few, it is not necessary to which terminal is adjusted, because This server normally can send the second heart beating feedback information for the heartbeat message that each terminal sends, Heart beating side-play amount is not included in the second heart beating feedback information.
Step 414, terminal to be waited and send reconnection requests, execution step 401 to server after random time.
If terminal does not receive the second heart beating feedback information of server transmission, explanation in the first Preset Time Current server has gone offline, if terminal also needs to be established a connection with server, and is kept for the normal phase exist Line states, then need to send reconnection requests to server.But if due to Server Restart or power-off etc. Reason, causes great amount of terminals while situation about going offline, in order to ensure that great amount of terminals will not be sent out to server simultaneously Connection request is played, the terminal can be waited and send reconnection requests to server after random time.
Example, the random time X can be calculated according to formula (3), formula (3) is X=A+B, The A is the set time;The B be 0 to (S/ (R*J)) in random integers;The S is described The maximum number of user amount of server;The R is the server treatable connection request number per second, and J is Coefficient more than 0, less than or equal to 1.Wherein, A can be the reboot time of server, that is to say, that All terminals send connection request after Server Restart to server, in case terminal is in Server Restart Go offline due to detecting server, and constantly send connection request to server, can so avoid resource Waste.Random Waiting Time is arranged by the method, is effectively avoided because a large amount of clients are instantaneously reconnected Cause network and server stress excessive, improve system stability.
Step 415, server discharge the resource that the terminal takes, process ends step.
If server does not receive the heartbeat message of terminal transmission in the second Preset Time, illustrate that the terminal is worked as Front to have gone offline, i.e., the terminal currently will not carry out again data interaction with server, therefore server can be released The resource for changing terminal occupancy is put, is used in order to other-end.
The embodiment of the present invention provides another kind of heartbeat message sending method, if server is received at short notice To the heart that more heartbeat message, the first heart beating feedback information that terminal can send according to server include The time that side-play amount adjustment sends heartbeat message next time is jumped, by the adjustment that the time is sent to heartbeat message, So that the distribution of the heartbeat message sent to server in a heart beat cycle tends to uniform, therefore can prevent Great amount of terminals simultaneously to the situation of server transmission heartbeat message, reduces the instantaneous of server at short notice Pressure, it is to avoid network data periodicity congestion.
The embodiment of the present invention provides a kind of server 50, as shown in figure 5, including:
Determining unit 501, needs to adjust the terminal that heartbeat message sends the time for determining.
Transmitting element 502, for sending the first heart beating feedback information to the terminal, first heart beating is anti- Feedforward information includes heart beating side-play amount, and the heart next time is adjusted according to the heart beating side-play amount in order to the terminal The transmission time of hop-information.
So, if server receives at short notice more heartbeat message, heart beating can be passed through Side-play amount adjustment terminal sends the time of heartbeat message next time, by sending the time to terminal heartbeat message Adjustment so that the distribution of the heartbeat message that heart beat cycle server is received tends to uniform, therefore can To prevent great amount of terminals at short notice simultaneously to the situation of server transmission heartbeat message, server is reduced Instantaneous pressure, it is to avoid network data periodicity congestion.
Optionally, as shown in fig. 6, the server 50 also includes:Judging unit 503, for judging ginseng Whether the instantaneous heart beating density for examining the time period is more than or equal to the maximum number of concurrent of the server and refers to coefficient Product;The instantaneous heart beating density be the heartbeat message quantity that receives in the reference time section with it is described The ratio of reference time section;The reference coefficient is more than 0, less than or equal to 1.The determining unit 501 Specifically for:When the instantaneous heart beating density is more than or equal to the maximum number of concurrent and the product with reference to coefficient When, it is determined that needing to adjust the terminal that heartbeat message sends the time.
Optionally, the determining unit 501 is additionally operable to:It is determined that needing to adjust the end that heartbeat message sends the time The quantity at end.
Optionally, the determining unit 501 specifically for:Being determined according to formula (1) needs to adjust heart beating letter Quantity Q of the terminal of breath transmission time, the formula (1) is Q=(Ts*P-Ts*PIt is flat)*100/(Ts* P) * M, wherein, the Ts is the reference time section;The P is close for the instantaneous heart beating of reference time section Degree;The PIt is flatFor the average heart beating density of heart beat cycle;The M is to receive in the reference time section Heartbeat message quantity.
Optionally, as shown in fig. 7, the server 50 also includes:Computing unit 504, for according to public affairs Formula (2) calculates heart beating side-play amount W, and the formula (1) is W=Ts+H.Wherein, the H is 0 to the random integers between (T-Ts).
A kind of server is embodiments provided, including:Determining unit, needs to adjust the heart for determining Hop-information sends the terminal of time.Transmitting element, for sending the first heart beating feedback information to the terminal, The first heart beating feedback information includes heart beating side-play amount, is offset according to the heart beating in order to the terminal Amount adjusts the transmission time of heartbeat message next time.Compared to prior art, if server is at short notice More heartbeat message is received, can be by sending heart beating side-play amount to terminal so that terminal adjustment is next The secondary time for sending heartbeat message, by the adjustment that the time is sent to terminal heartbeat message so that a heart beating The distribution of the heartbeat message that cycle server is received tends to uniform, therefore can prevent great amount of terminals short The instantaneous pressure of server is reduced in time to the situation of server transmission heartbeat message simultaneously, it is to avoid Network data periodicity congestion.
The embodiment of the present invention provides a kind of terminal 80, as shown in figure 8, including:
Receiving unit 801, for the first heart beating feedback information that the reception server sends, first heart beating Feedback information includes heart beating side-play amount.
Adjustment unit 802, for according to the heart beating side-play amount, adjustment to send heart beating to server next time The transmission time of information.
So, if server receives at short notice more heartbeat message, terminal can basis The heart beating side-play amount adjustment that the first heart beating feedback information that server sends includes sends heartbeat message next time Time, by the adjustment that the time is sent to heartbeat message so that send to server in heart beat cycle The distribution of heartbeat message tend to uniform, therefore can prevent great amount of terminals at short notice simultaneously to server The situation of heartbeat message is sent, the instantaneous pressure of server is reduced, it is to avoid network data periodicity congestion.
Optionally, as shown in figure 9, the terminal 80 also includes:Transmitting element 803, for the clothes After business device establishes a connection, the random time in a heart beat cycle to server sends heart beating first Information.
Optionally, the transmitting element 803 is additionally operable to:If not receiving the server in the first Preset Time The the first heart beating feedback information for sending or the second heart beating feedback information, in the second heart beating feedback information Do not include the heart beating side-play amount, after waiting random time, to the server connection request is sent.
Optionally, as shown in Figure 10, the terminal 80 also includes:Computing unit 804, for according to public affairs Formula (3) calculates the random time, and the formula (3) is X=A+B, wherein, the A is fixation Time;The B be 0 to (S/ (R*J)) in random integers;The S is the maximum of the server Number of users;The R is the server treatable connection request number per second.
The embodiment of the present invention provides a kind of terminal, including:Receiving unit, the sent for the reception server One heart beating feedback information, the first heart beating feedback information includes heart beating side-play amount.Adjustment unit, is used for According to the heart beating side-play amount, adjustment sends the transmission time of heartbeat message to server next time.Compared to Prior art, if server receives at short notice more heartbeat message, terminal can be according to service Device send the first heart beating feedback information include heart beating side-play amount adjustment next time send heartbeat message when Between, by the adjustment that the time is sent to heartbeat message so that the heart sent to server in a heart beat cycle The distribution of hop-information tends to uniform, therefore can prevent great amount of terminals at short notice simultaneously to server transmission The situation of heartbeat message, reduces the instantaneous pressure of server, it is to avoid network data periodicity congestion.
A kind of heartbeat message of the embodiment of the present invention sends system 110, as shown in figure 11, including server 110A With terminal 110B, terminal 110B illustrates by taking mobile phone as an example.
The server 110A is used to determine to be needed to adjust terminal 110B that heartbeat message sends the time;To institute State terminal 110B and send the first heart beating feedback information, the first heart beating feedback information includes that heart beating offsets Amount, when adjusting the transmission of heartbeat message next time according to the heart beating side-play amount in order to terminal 110B Between;
The first heart beating feedback information that terminal 110B sends for the reception server 110A, described first Heart beating feedback information includes heart beating side-play amount;According to the heart beating side-play amount, adjust next time to server 110A sends the transmission time of heartbeat message;It is additionally operable to establishing a connection it with the server 110A Afterwards, the random time in a heart beat cycle sends heartbeat message first to server 110A;It is additionally operable to If not receiving the first heart beating feedback information that the server 110A sends or the in the first Preset Time Two heart beating feedback informations, do not include the heart beating side-play amount in the second heart beating feedback information, wait random After time, to the server 110A connection request is sent.
So, if server receives at short notice more heartbeat message, terminal can basis The heart beating side-play amount adjustment that the first heart beating feedback information that server sends includes sends heartbeat message next time Time, by the adjustment that the time is sent to heartbeat message so that send to server in heart beat cycle The distribution of heartbeat message tend to uniform, simultaneously because terminal sends first the time of heartbeat message and sends out again The time for sending connection request is random time, therefore can prevent great amount of terminals at short notice simultaneously to clothes Business device sends the situation of heartbeat message, reduces the instantaneous pressure of server, it is to avoid network data is periodically Congestion.
It should be noted that first, the priority of heartbeat message sending method step provided in an embodiment of the present invention Order can be adjusted suitably, and step according to circumstances can also accordingly be increased and decreased, any to be familiar with this technology The technical staff in field the invention discloses technical scope in, the method that can readily occur in change all should be contained Cover within protection scope of the present invention, therefore repeat no more.
Second, those skilled in the art can be understood that, for convenience and simplicity of description, on The specific work process of the system, apparatus, and unit of description is stated, it is right in preceding method embodiment to may be referred to Process is answered, be will not be described here.
3rd, in addition, each functional unit in each embodiment of the invention can be integrated in one processes single In unit, or the independent physics of unit includes, it is also possible to which two or more units are integrated in one In individual unit.Above-mentioned integrated unit both can be realized in the form of hardware, it would however also be possible to employ hardware adds soft The form of part functional unit is realized.
The above, only presently preferred embodiments of the present invention is not intended to limit the protection model of the present invention Enclose.

Claims (12)

1. a kind of heartbeat message sending method, it is characterised in that for server, including:
It is determined that needing to adjust the terminal that heartbeat message sends the time;
The first heart beating feedback information is sent to the terminal, the first heart beating feedback information includes that heart beating is inclined Shifting amount, in order to the transmission time that the terminal adjusts heartbeat message next time according to the heart beating side-play amount.
2. method according to claim 1, it is characterised in that need to adjust heart beating letter in the determination Before the terminal of breath transmission time, methods described also includes:
Whether the instantaneous heart beating density for judging reference time section is more than or equal to the maximum number of concurrent of the server With the product with reference to coefficient;The instantaneous heart beating density is the heartbeat message received in the reference time section The ratio of quantity and the reference time section;The reference coefficient is more than 0, less than or equal to 1;
The determination needs the terminal for adjusting the heartbeat message transmission time to include:
When the instantaneous heart beating density is more than or equal to the maximum number of concurrent and the product with reference to coefficient, really Surely need to adjust the terminal that heartbeat message sends the time.
3. method according to claim 1 and 2, it is characterised in that need to adjust the heart in the determination Hop-information is sent before the terminal of time, and methods described also includes:
It is determined that needing the quantity for adjusting the terminal that heartbeat message sends the time.
4. a kind of heartbeat message sending method, it is characterised in that for terminal, including:
The first heart beating feedback information that the reception server sends, the first heart beating feedback information includes heart beating Side-play amount;
According to the heart beating side-play amount, adjustment sends the transmission time of heartbeat message to server next time.
5. method according to claim 4, it is characterised in that the sent in the reception server Before one heart beating feedback information, methods described also includes:
After establishing a connection with the server, the random time in a heart beat cycle is to server Send heartbeat message first.
6. method according to claim 5, it is characterised in that during random in a heart beat cycle Between send first after heartbeat message to server, methods described also includes:
If not receiving the first heart beating feedback information or second that the server sends in the first Preset Time Heart beating feedback information, does not include the heart beating side-play amount, when waiting random in the second heart beating feedback information Between after, to the server send connection request.
7. a kind of server, it is characterised in that include:
Determining unit, needs to adjust the terminal that heartbeat message sends the time for determining;
Transmitting element, for sending the first heart beating feedback information, the first heart beating feedback letter to the terminal Breath includes heart beating side-play amount, and the letter of heart beating next time is adjusted according to the heart beating side-play amount in order to the terminal The transmission time of breath.
8. server according to claim 7, it is characterised in that the server also includes:
Judging unit, for judging the instantaneous heart beating density of reference time section whether more than or equal to the service The maximum number of concurrent of device and the product with reference to coefficient;The instantaneous heart beating density is to connect in the reference time section The ratio of the heartbeat message quantity for receiving and the reference time section;The reference coefficient be more than 0, less than or Equal to 1;
The determining unit specifically for:When the instantaneous heart beating density is more than or equal to the maximum number of concurrent During with product with reference to coefficient, it is determined that needing to adjust the terminal that heartbeat message sends the time.
9. the server according to claim 7 or 8, it is characterised in that the determining unit is additionally operable to:
It is determined that needing the quantity for adjusting the terminal that heartbeat message sends the time.
10. a kind of terminal, it is characterised in that include:
Receiving unit, for the first heart beating feedback information that the reception server sends, the first heart beating feedback Information includes heart beating side-play amount;
Adjustment unit, for according to the heart beating side-play amount, adjustment to send heartbeat message to server next time The transmission time.
11. terminals according to claim 10, it is characterised in that the terminal also includes:
Transmitting element, after establishing a connection with the server, in a heart beat cycle with Machine time to server sends heartbeat message first.
12. terminals according to claim 11, it is characterised in that the transmitting element is additionally operable to:
If not receiving the first heart beating feedback information or second that the server sends in the first Preset Time Heart beating feedback information, does not include the heart beating side-play amount, when waiting random in the second heart beating feedback information Between after, to the server send connection request.
CN201510751434.XA 2015-11-05 2015-11-05 Heartbeat information sending method, server and terminal Active CN106685748B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510751434.XA CN106685748B (en) 2015-11-05 2015-11-05 Heartbeat information sending method, server and terminal

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510751434.XA CN106685748B (en) 2015-11-05 2015-11-05 Heartbeat information sending method, server and terminal

Publications (2)

Publication Number Publication Date
CN106685748A true CN106685748A (en) 2017-05-17
CN106685748B CN106685748B (en) 2020-06-12

Family

ID=58862795

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510751434.XA Active CN106685748B (en) 2015-11-05 2015-11-05 Heartbeat information sending method, server and terminal

Country Status (1)

Country Link
CN (1) CN106685748B (en)

Cited By (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107528729A (en) * 2017-08-25 2017-12-29 中国南方电网有限责任公司 Heartbeat message mechanism modeling method based on the communication of OPNET transformer station process layer
CN109104265A (en) * 2018-06-07 2018-12-28 海能达通信股份有限公司 Channel arrangement method, base station and readable storage medium storing program for executing
CN109831474A (en) * 2018-11-26 2019-05-31 阿里巴巴集团控股有限公司 Keep-alive system, method, server and the readable storage medium storing program for executing of http long connection
CN110365598A (en) * 2019-06-26 2019-10-22 深圳市梦网科技发展有限公司 Method, apparatus, server, terminal and the storage medium that heartbeat message is sent
CN111078267A (en) * 2019-12-31 2020-04-28 深圳市优必选科技股份有限公司 Robot state information updating method and device, server and storage medium
CN113612624A (en) * 2021-06-29 2021-11-05 济南浪潮数据技术有限公司 Method and device for processing heartbeat between nodes
CN113873017A (en) * 2021-09-06 2021-12-31 绿盟科技集团股份有限公司 Heartbeat period adjusting method and device, client and server
CN114500550A (en) * 2021-12-31 2022-05-13 深圳市晨北科技有限公司 Equipment heartbeat interval control method and device, Internet of things equipment and storage medium
CN115102885A (en) * 2022-06-17 2022-09-23 中建八局第二建设有限公司 Variable-speed heartbeat method for low-power-consumption Internet of things equipment

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102438181A (en) * 2011-08-18 2012-05-02 中兴通讯股份有限公司 Method and system for adjusting time for sending heartbeat message in Internet protocol television (IPTV) system
CN102447631A (en) * 2011-12-28 2012-05-09 华为终端有限公司 Heartbeat connection method and related device and system thereof
CN102843250A (en) * 2011-06-21 2012-12-26 中兴通讯股份有限公司 Adaptive method and adaptive device of heartbeat cycle
CN104144159A (en) * 2014-06-26 2014-11-12 腾讯科技(深圳)有限公司 Intelligent heartbeat keeping method and system

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102843250A (en) * 2011-06-21 2012-12-26 中兴通讯股份有限公司 Adaptive method and adaptive device of heartbeat cycle
CN102438181A (en) * 2011-08-18 2012-05-02 中兴通讯股份有限公司 Method and system for adjusting time for sending heartbeat message in Internet protocol television (IPTV) system
CN102447631A (en) * 2011-12-28 2012-05-09 华为终端有限公司 Heartbeat connection method and related device and system thereof
CN104144159A (en) * 2014-06-26 2014-11-12 腾讯科技(深圳)有限公司 Intelligent heartbeat keeping method and system

Cited By (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107528729A (en) * 2017-08-25 2017-12-29 中国南方电网有限责任公司 Heartbeat message mechanism modeling method based on the communication of OPNET transformer station process layer
CN109104265A (en) * 2018-06-07 2018-12-28 海能达通信股份有限公司 Channel arrangement method, base station and readable storage medium storing program for executing
CN109831474A (en) * 2018-11-26 2019-05-31 阿里巴巴集团控股有限公司 Keep-alive system, method, server and the readable storage medium storing program for executing of http long connection
CN109831474B (en) * 2018-11-26 2021-07-13 创新先进技术有限公司 Keep-alive system, method, server and readable storage medium for http long connection
CN110365598A (en) * 2019-06-26 2019-10-22 深圳市梦网科技发展有限公司 Method, apparatus, server, terminal and the storage medium that heartbeat message is sent
CN111078267A (en) * 2019-12-31 2020-04-28 深圳市优必选科技股份有限公司 Robot state information updating method and device, server and storage medium
CN113612624A (en) * 2021-06-29 2021-11-05 济南浪潮数据技术有限公司 Method and device for processing heartbeat between nodes
CN113612624B (en) * 2021-06-29 2023-01-06 济南浪潮数据技术有限公司 Method and device for processing heartbeat between nodes
CN113873017A (en) * 2021-09-06 2021-12-31 绿盟科技集团股份有限公司 Heartbeat period adjusting method and device, client and server
CN113873017B (en) * 2021-09-06 2023-12-26 绿盟科技集团股份有限公司 Heartbeat cycle adjusting method, device, client and server
CN114500550A (en) * 2021-12-31 2022-05-13 深圳市晨北科技有限公司 Equipment heartbeat interval control method and device, Internet of things equipment and storage medium
CN115102885A (en) * 2022-06-17 2022-09-23 中建八局第二建设有限公司 Variable-speed heartbeat method for low-power-consumption Internet of things equipment
CN115102885B (en) * 2022-06-17 2024-05-14 中建八局第二建设有限公司 Variable-speed heartbeat method for low-power-consumption Internet of things equipment

Also Published As

Publication number Publication date
CN106685748B (en) 2020-06-12

Similar Documents

Publication Publication Date Title
CN106685748A (en) Heartbeat information sending methods, server and terminal
CN109905259B (en) Communication connection maintaining method, system and related equipment
US8868773B2 (en) Efficiently distributing video content using a combination of a peer-to-peer network and a content distribution network
EP1654838B1 (en) System and method for selecting data providers
CN110120931B (en) Information interaction method and device and storage medium
EP0988878A2 (en) System and method for networking video games
EP3447970B1 (en) Live broadcast system in peer-to-peer network and node management method
CN107872396B (en) Communication method with timeout control, processing device, terminal device and server
WO2021237433A1 (en) Message pushing method and apparatus, and electronic device and computer-readable medium
US10402280B2 (en) File transfer system and method, policy server, terminal and storage medium
CN113783775B (en) Method and device for data transmission
CN103312752A (en) P2P (Peer to Peer) network information distribution method, downloading node, index server and P2P network information distribution system
CN108462755A (en) A kind of method and system of downloading data resource
AU2020257112A1 (en) Distribution of bandwidth in a network
Mišić et al. Performance of bitcoin network with synchronizing nodes and a mix of regular and compact blocks
CN110769019A (en) Session processing method, device and system
CN103595552B (en) Analysis method and analysis system for cluster storage network parallel load
CN111479298B (en) Method and device for controlling power consumption
KR101325351B1 (en) Asynchronous Multi-Source Streaming
CN114070494A (en) Data transmission method, device, equipment and storage medium
WO2012158161A1 (en) Efficiently distributing video content using a combination of a peer-to-peer network and a content distribution network
EP2738979A1 (en) Data stream reused transmission method, duplicate point device and system
CN113965495A (en) Method and device for detecting activity of terminal application program, electronic equipment and storage medium
CN112600683B (en) Cloud conference signaling control method and system and readable storage medium
US20230275962A1 (en) Data transmission method and communication apparatus

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
CB02 Change of applicant information
CB02 Change of applicant information

Address after: 310012 building A01, 1600 yuhangtang Road, Wuchang Street, Yuhang District, Hangzhou City, Zhejiang Province

Applicant after: CHINA MOBILE (HANGZHOU) INFORMATION TECHNOLOGY Co.,Ltd.

Applicant after: China Mobile Communications Corp.

Address before: 310012, No. 14, building three, Chang Torch Hotel, No. 259, Wensanlu Road, Xihu District, Zhejiang, Hangzhou

Applicant before: CHINA MOBILE (HANGZHOU) INFORMATION TECHNOLOGY Co.,Ltd.

Applicant before: China Mobile Communications Corp.

GR01 Patent grant
GR01 Patent grant