CN106713171A - Server and delay-queue-based current-limiting protection system and method - Google Patents

Server and delay-queue-based current-limiting protection system and method Download PDF

Info

Publication number
CN106713171A
CN106713171A CN201510451329.4A CN201510451329A CN106713171A CN 106713171 A CN106713171 A CN 106713171A CN 201510451329 A CN201510451329 A CN 201510451329A CN 106713171 A CN106713171 A CN 106713171A
Authority
CN
China
Prior art keywords
time delay
request
delay queue
queue
server
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
CN201510451329.4A
Other languages
Chinese (zh)
Other versions
CN106713171B (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.)
Tencent Technology Shenzhen Co Ltd
Original Assignee
Tencent Technology Shenzhen 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 Tencent Technology Shenzhen Co Ltd filed Critical Tencent Technology Shenzhen Co Ltd
Priority to CN201510451329.4A priority Critical patent/CN106713171B/en
Publication of CN106713171A publication Critical patent/CN106713171A/en
Application granted granted Critical
Publication of CN106713171B publication Critical patent/CN106713171B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Abstract

The invention provides a delay-queue-based current-limiting protection method. The method comprises: performance parameters of a server are collected and analyzed and a request number threshold value in a queue and request occupied time are obtained; whether the request number in the queue exceeds a threshold value is determined; if not, the request is added into the delay queue, and the request leaves from the delay queue when the request meets the occupied time; and if so, busy information is sent to a user terminal. In addition, the invention also provides a server and a delay-queue-based current-limiting protection system. Therefore, requirements on conditions of user request random distribution and server processing capacity excess can be met.

Description

Server, the current-limiting protection system and method based on time delay queue
Technical field
The present invention relates to computer communication technology field, more particularly to a kind of server, based on time delay team The current-limiting protection system and method for row.
Background technology
At present, asked for high concurrent, server would generally set to carry out overload protection and first enter elder generation Go out (First Input First Output, FIFO) queue.
In order to the treatment quantity of limiting concurrent request can carry out semaphore control, wherein, take letter thing The request of feelings token then allows server to enter treatment, and the request for not taking letter thing token is then considered as Overload and return to busy information.Additionally, further, can also be solid by counter and time control The request amount passed through in interval of fixing time carries out current-limiting protection.
But existing queue Preservation tactics can only be directed to the not enough situation of server handling ability, it is impossible to full Sufficient server handling ability is superfluous and be limited to the situation of such as network interface card floating resources etc., and pass through to count When the request amount that passes through carries out current-limiting protection in device and time control set time interval, due to time zone Between be fixed, it is impossible to meet the situation of user's request random distribution.
The content of the invention
In view of this, the present invention provides a kind of situation and server that can meet user's request random distribution The current limiting protecting method based on time delay queue of the superfluous situation of disposal ability.
The embodiment of the present invention provides a kind of current limiting protecting method based on time delay queue, described based on time delay The current limiting protecting method of queue includes collecting the performance parameter of simultaneously Analysis server, so as to obtain time delay team The threshold values of the number of requests in row and the occupy-place time of request;Receive the request that user terminal sends;Sentence Whether the number of requests in the disconnected time delay queue exceedes threshold values;If the number of request in the time delay queue The request is then added the time delay queue, and meet described in the request by amount not less than threshold values During the occupy-place time, the request is allowed to leave the time delay queue;And if the request of the time delay queue Quantity exceedes threshold values, then send busy information to the user terminal.
The embodiment of the present invention also provides a kind of server, and the server includes acquisition module, flow control Molding block.The acquisition module is used to collect and analyze the performance parameter of the server, so as to obtain The threshold values of the number of requests in time delay queue and the occupy-place time of request;The flow-control module is used for When receiving the request that user terminal sends, and number of requests in the time delay queue not less than threshold values, The request is added into the time delay queue, and the request in the time delay queue meets described During the occupy-place time, the request is allowed to leave the time delay queue.
The embodiment of the present invention also provides a kind of current-limiting protection system based on time delay queue, described based on prolonging When queue current-limiting protection system include user terminal and server;The user terminal is used to send asks Ask to the server;The server is used to collect and analyze the performance parameter of the server, from And threshold values and the occupy-place time of the request of number of requests in time delay queue are obtained, and prolong described When queue in number of requests not less than threshold values when, the request is added into the time delay queue, and When the request in the time delay queue meets the occupy-place time, the request is allowed to leave described prolonging When queue.
Server of the invention, the current-limiting protection system and method based on time delay queue basis can prolong in real time When queue in request quantity response user terminal request, user's request random distribution can be met Situation, and the request in time delay queue when meeting the occupy-place time just by time delay queue Number of requests is correspondingly reduced, and can meet the superfluous situation of server handling ability.
It is that above and other objects, features and advantages of the invention can be become apparent, it is cited below particularly Preferred embodiment, and coordinate institute's accompanying drawings, it is described in detail below.
Brief description of the drawings
The structural representation of the server that Fig. 1 is provided for first embodiment of the invention.
Fig. 2 shows a kind of structural representation of time delay queue.
Fig. 3 shows a kind of structured flowchart of user terminal.
The structure of the current-limiting protection system based on time delay queue that Fig. 4 is provided for second embodiment of the invention Schematic diagram.
The flow of the current limiting protecting method based on time delay queue that Fig. 5 is provided for third embodiment of the invention Schematic diagram.
Fig. 6 is the applied environment schematic diagram of the current limiting protecting method based on time delay queue as shown in Figure 5.
The flow of the current limiting protecting method based on time delay queue that Fig. 7 is provided for fourth embodiment of the invention Schematic diagram.
The flow of the current limiting protecting method based on time delay queue that Fig. 8 is provided for fifth embodiment of the invention Schematic diagram.
Specific embodiment
Further to illustrate the present invention to realize technological means and work(that predetermined goal of the invention taken Effect, below in conjunction with accompanying drawing and preferred embodiment, to according to specific embodiment of the invention, structure, Feature and its effect, describe in detail as after.
First embodiment
The structural representation of the server that Fig. 1 is provided for first embodiment of the invention.As shown in figure 1, Server 10 includes acquisition module 100 and flow-control module 101.
Wherein, acquisition module 100 is used to collect the performance parameter of simultaneously Analysis server 10, so as to obtain The threshold values of the number of requests in time delay queue and the occupy-place time of request.
Specifically, the performance parameter of server 10 can be, but not limited to include network interface card flow, input and output The service condition of interface distinguishes corresponding performance parameter.Certainly it will be appreciated by those skilled in the art that , the performance parameter of server 10 can with but be not limited to also including central processing unit loading condition etc. Etc. corresponding performance parameter.
Wherein, flow-control module 101 is used to receive the request of user terminal transmission, and in time delay team When number of requests in row is not less than threshold values, request is added into time delay queue, and in time delay queue When request meets the occupy-place time, allow and ask leave latency queue.
Specifically, user terminal can be, but not limited to be mobile phone, panel computer etc. terminal device.With Family terminal can be communicated with various networks such as internet, intranet, wireless network for example to be passed through Wireless network sends a request to server.Above-mentioned wireless network may include cellular telephone networks, wireless LAN or Metropolitan Area Network (MAN).Above-mentioned wireless network can use various communication standards, agreement and technology.
Wherein, time delay queue is that can be, but not limited to be the time delay queue with timestamp as priority, when So it will be appreciated by those skilled in the art that, time delay queue can also be with the class of other such as requests Type etc. is the queue of priority.
Fig. 2 shows a kind of structural representation of time delay queue.Wherein, time delay queue is to be with timestamp The time delay queue of priority, that is to say, that time delay queue head is timestamp (time joined the team at the moment) Minimum request, time delay queue tail is the maximum request of timestamp.As shown in Fig. 2 time delay queue Include 9 requests altogether, the time in time delay queue represents that corresponding requests go out the remaining time of team, for example, If the threshold values of the number of requests in time delay queue is 9, the occupy-place time of request is 1 second (s), then, Only after 100 milliseconds (ms), being possible to next request addition time delay queue ought prolong When queue be packed with (number of requests reaches threshold values), only have request leave latency queue when, it is next Individual request could add time delay queue.Additionally, each request must is fulfilled for 1s ability in time delay queue Leave latency queue.
It is noted that each request must is fulfilled for the occupy-place time in time delay queue and can just leave and prolong When queue, but the time of server real response request may but be not limited to prior to request leave latency team The time of row.
The quantity response of server energy provided in an embodiment of the present invention request in real time in time delay queue The request of user terminal, can meet the situation of user's request random distribution, and the institute in time delay queue State when request meets the occupy-place time and just correspondingly reduce the number of requests in time delay queue, can be full The superfluous situation of sufficient server handling ability.
Fig. 3 shows a kind of structured flowchart of user terminal.As shown in figure 3, user terminal includes storage Device 202, storage control 204, it is one or more (one is only shown in figure) processors 206, outer If interface 208, radio-frequency module 210, locating module 212, photographing module 214, audio-frequency module 216, Touch Screen 218 and key-press module 220.These components pass through one or more communication bus/signal Line is mutually communicated.
It is appreciated that the structure shown in Fig. 3 is only to illustrate, user terminal may also include than institute in Fig. 3 Show more or less components, or with configuration different shown in Fig. 3.Institute in Fig. 3 Each component for showing can be realized using hardware, software or its combination.
Memory 202 can be used to store software program and module.Processor 202 is stored by running Software program and module in memory 204, so as to perform at various function application and data Reason.
Memory 202 may include high speed random access memory, may also include nonvolatile memory, such as one Individual or multiple magnetic storage devices, flash memory or other non-volatile solid state memories.At some In example, memory 202 can further include the memory remotely located relative to processor 206, These remote memories can be by network connection to user terminal.The example of above-mentioned network include but not It is limited to internet, intranet, LAN, mobile radio communication and combinations thereof.Processor 206 with And access of other possible components to memory 202 can be carried out under the control of storage control 204.
Various input/output devices are coupled to processor 206 and memory 202 by Peripheral Interface 208. Various softwares in the run memory 202 of processor 206, instruction are performing the various work(of user terminal Data processing and can be carried out.
In certain embodiments, Peripheral Interface 208, processor 206 and storage control 204 can be with Realized in one single chip.In other examples, Peripheral Interface 208, processor 206 and storage control Device processed 204 can be realized by independent chip respectively.
Radio-frequency module 210 is used to receive and send electromagnetic wave, realizes that electromagnetic wave is mutual with electric signal Conversion, so as to be communicated with communication network or other equipment.Radio-frequency module 210 may include various The existing circuit element for performing these functions, for example, antenna, RF transceiver, numeral letter Number processor, encryption/deciphering chip, subscriber identity module (SIM) card, memory etc..Radio frequency Module 210 can be communicated or led to various networks such as internet, intranet, wireless network Wireless network is crossed to be communicated with other equipment.Above-mentioned wireless network may include cellular telephone networks, WLAN or Metropolitan Area Network (MAN).Above-mentioned wireless network can using various communication standards, agreement and Technology, including but not limited to global system for mobile communications (Global System for Mobile Communication, GSM), enhanced mobile communication technology (Enhanced Data GSM Environment, EDGE), Wideband CDMA Technology (wideband code division multiple Access, W-CDMA), CDMA (Code division access, CDMA), time-division are more Location technology (time division multiple access, TDMA), bluetooth, adopting wireless fidelity technology (Wireless, Fidelity, WiFi) (such as IEEE-USA's standard IEEE 802.11a, IEEE 802.11b, IEEE802.11g and/or IEEE 802.11n), the networking telephone (Voice over internet Protocal, VoIP), worldwide interoperability for microwave accesses (Worldwide Interoperability for Microwave Access, Wi-Max), other be used for the agreement of mail, instant messaging and short message, it is and any Other suitable communications protocol, or even may include those agreements not being developed yet currently.
Locating module 212 is used to obtain the current location of user terminal.The example bag of locating module 212 Include but be not limited to GPS (GPS), based on WLAN or mobile radio communication Location technology.
Photographing module 214 is used to shoot photo or video.The photo or video of shooting can be stored To memory 202, and can be sent by radio-frequency module 210.
Audio-frequency module 216 provides a user with COBBAIF, and it may include one or more microphones, one Individual or multiple loudspeakers and voicefrequency circuit.Audio-frequency module 216 is from reception sound at Peripheral Interface 208 Sound data, power information is converted to by voice data, and power information is transmitted to loudspeaker.Loudspeaker is by electricity Information is converted to the sound wave that human ear can be heard.Voicefrequency circuit receives power information also from microphone, by electricity Signal is converted to voice data, and will be further to carry out in data transmission in network telephony to Peripheral Interface 208 Treatment.Voice data can be obtained from memory 202 or by radio-frequency module 210.Additionally, Voice data can also be stored into memory 202 or is transmitted by radio-frequency module 210. In some examples, audio-frequency module 216 may also include an earphone and broadcast hole, for earphone or other Equipment provides COBBAIF.
Touch Screen 218 provides an output and inputting interface simultaneously between user terminal and user. Touch Screen 218 is used to show video frequency output to user, the content of these video frequency outputs may include word, Figure, video and its any combination.Touch Screen 218 is additionally operable to receive the input of user, for example The gesture operations such as click, the slip of user, the input so as to user interface object to these users is made Response.The technology for detecting user input can be based on resistance-type, condenser type or other any possibility Touch control detection technology.The instantiation of the display unit of Touch Screen 218 includes but is not limited to liquid crystal Display or light emitting polymer displays.
Key-press module 220 equally provides the interface that user is input into user terminal, and user can lead to Cross and press different buttons so that user terminal performs different functions.
Second embodiment
The structure of the current-limiting protection system based on time delay queue that Fig. 4 is provided for second embodiment of the invention Schematic diagram.As shown in figure 4, the current-limiting protection system based on time delay queue includes server 30 and user Terminal 40.
Wherein, user terminal 40 is used to send a request to the server 30.
Specifically, user terminal 40 can be, but not limited to be mobile phone, panel computer etc. terminal device. User terminal 40 can be communicated for example with various networks such as internet, intranet, wireless network Server 30 is sent a request to by wireless network.Wireless network can use various communication standards, association View and technology.
Server 30 is used to collect the performance parameter of simultaneously Analysis server 30, so as to obtain time delay queue In number of requests threshold values and the occupy-place time of request, and number of requests in time delay queue do not surpass When crossing threshold values, the request that the user terminal 40 of reception is sent adds time delay queue, and in time delay queue In request when meeting the occupy-place time, allow request leave latency queue.
Specifically, the performance parameter of server 30 can be, but not limited to include network interface card flow, input and output The service condition of interface distinguishes corresponding performance parameter.Certainly it will be appreciated by those skilled in the art that , the performance parameter of server 30 can with but be not limited to also including central processing unit loading condition etc. Etc. corresponding performance parameter.
Wherein, time delay queue is that can be, but not limited to be the time delay queue with timestamp as priority, when So it will be appreciated by those skilled in the art that, time delay queue can also be with the class of other such as requests Type etc. is the queue of priority.
It is noted that each request must is fulfilled for the occupy-place time in time delay queue and can just leave and prolong When queue, but the time of server real response request may but be not limited to prior to request leave latency team The time of row.
Current-limiting protection system based on time delay queue provided in an embodiment of the present invention can be in real time according to time delay team The request of the quantity response user terminal of the request in row, can meet the situation of user's request random distribution, And the request in time delay queue when meeting the occupy-place time just by the number of request in time delay queue Amount is correspondingly reduced, and can meet the superfluous situation of server handling ability.
3rd embodiment
The flow of the current limiting protecting method based on time delay queue that Fig. 5 is provided for third embodiment of the invention Schematic diagram.Fig. 6 is that the applied environment of the current limiting protecting method based on time delay queue as shown in Figure 5 shows It is intended to.
Fig. 5 and Fig. 6 is please also refer to, the current limiting protecting method based on time delay queue comprises the following steps:
Step S51:The performance parameter of simultaneously Analysis server 50 is collected, so that in obtaining time delay queue The threshold values of number of requests and the occupy-place time of request;
Specifically, the performance parameter of server 50 can be, but not limited to include network interface card flow, input and output The service condition of interface distinguishes corresponding performance parameter.Certainly it will be appreciated by those skilled in the art that , the performance parameter of server 50 can with but be not limited to also including central processing unit loading condition etc. Etc. corresponding performance parameter.
Wherein, time delay queue is that can be, but not limited to be the time delay queue with timestamp as priority, when So it will be appreciated by those skilled in the art that, time delay queue can also be with the class of other such as requests Type etc. is the queue of priority.
Step S52:Receive the request that user terminal 60 sends;
Specifically, user terminal 60 can be, but not limited to be mobile phone, panel computer etc. terminal device. User terminal 60 can be communicated for example with various networks such as internet, intranet, wireless network Server 50 is sent a request to by wireless network.Wireless network can use various communication standards, association View and technology.
Step S53:Judge whether the number of requests in time delay queue exceedes threshold values;
If the number of requests in time delay queue is not less than threshold values, into step S54:Request addition is prolonged When queue, and when request meets the occupy-place time, allow request leave latency queue;
It is noted that each request must is fulfilled for the occupy-place time in time delay queue and can just leave and prolong When queue, but the time of server real response request may but be not limited to prior to request leave latency team The time of row.
If the number of requests of time delay queue exceedes threshold values, into step S55:Send busy information to use Family terminal 60.
Current limiting protecting method based on time delay queue provided in an embodiment of the present invention can be in real time according to time delay team The request of the quantity response user terminal of the request in row, can meet the situation of user's request random distribution, And the request in time delay queue when meeting the occupy-place time just by the number of request in time delay queue Amount is correspondingly reduced, and can meet the superfluous situation of server handling ability.
Fourth embodiment
The flow of the current limiting protecting method based on time delay queue that Fig. 7 is provided for fourth embodiment of the invention Schematic diagram.Current limiting protecting method based on time delay queue comprises the following steps:
Step S71:The performance parameter of simultaneously Analysis server is collected, so as to obtain the request in time delay queue The threshold values of quantity and the occupy-place time of request;
Specifically, the performance parameter of server can be, but not limited to include that network interface card flow, input and output connect The service condition of mouth distinguishes corresponding performance parameter.Certainly it will be appreciated by those skilled in the art that Be, the performance parameter of server can with but be not limited to also include that central processing unit loading condition etc. is right The performance parameter answered.
Specifically, time delay queue is that can be, but not limited to be the time delay queue with timestamp as priority, Certainly it will be appreciated by those skilled in the art that, time delay queue can also be with other such as requests Type etc. is the queue of priority.
Step S72:Receive the request that user terminal sends;
Specifically, user terminal can be, but not limited to be mobile phone, panel computer etc. terminal device.With Family terminal can be, but not limited to send a request to server by various networks.
Step S73:Judge whether the number of requests in time delay queue exceedes threshold values;
If the number of requests in time delay queue is not less than threshold values, into step S74:Request addition is prolonged When queue;
Step S75:Judge whether the request in time delay queue meets the occupy-place time;
If the request in time delay queue meets the occupy-place time, into step S76:Allow request leave latency Queue;
Between if the request in time delay queue does not meet occupation time, return to step S75.
Specifically, whether real-time judge request meets the occupy-place time, if what request was treated in time delay queue Time meets the occupy-place time then allows request leave latency queue, if time for being treated in time delay queue of request The occupy-place time is unsatisfactory for, then repeats to judge until it meets the occupy-place time.
If the number of requests of time delay queue exceedes threshold values, into step S77:Send busy information to use Family terminal.
It is noted that each request must is fulfilled for the occupy-place time in time delay queue and can just leave and prolong When queue, but the time of server real response request may but be not limited to prior to request leave latency team The time of row.
Current limiting protecting method based on time delay queue provided in an embodiment of the present invention can be in real time according to time delay team The request of the quantity response user terminal of the request in row, can meet the situation of user's request random distribution, And whether the request in real-time judge time delay queue meets the occupy-place time, and in the request Just the number of requests in time delay queue is correspondingly reduced when meeting the occupy-place time, service can be met The superfluous situation of device disposal ability.
5th embodiment
The flow of the current limiting protecting method based on time delay queue that Fig. 8 is provided for fifth embodiment of the invention Schematic diagram.
Current limiting protecting method based on time delay queue comprises the following steps:
Step S81:The performance parameter of simultaneously Analysis server is collected, so as to obtain the request in time delay queue The threshold values of quantity and the occupy-place time of request;
Specifically, the performance parameter of server can be, but not limited to include that network interface card flow, input and output connect The service condition of mouth distinguishes corresponding performance parameter.Certainly it will be appreciated by those skilled in the art that Be, the performance parameter of server can with but be not limited to also include that central processing unit loading condition etc. is right The performance parameter answered.
Specifically, time delay queue is that can be, but not limited to be the time delay queue with timestamp as priority, Certainly it will be appreciated by those skilled in the art that, time delay queue can also be with other such as requests Type etc. is the queue of priority.
Step S82:Receive the request that user terminal sends;
Specifically, user terminal can be, but not limited to be mobile phone, panel computer etc. terminal device.With Family terminal can be, but not limited to send a request to server by various networks.
Step S83:Judge whether the number of requests in time delay queue exceedes threshold values;
If the number of requests in time delay queue is not less than threshold values, into step S84:Request addition is prolonged When queue;
Step S85:Obtain the timestamp that request adds time delay queue;
Specifically, obtaining request adds the timestamp of time delay queue namely to obtain request addition time delay team The row time at the moment.
Step S86:After waiting the occupy-place time, allow and ask leave latency queue;
Specifically, for example the occupy-place time be 1s, then request add time delay queue after 1S, allow request from Open time delay queue.
It is noted that each request must is fulfilled for the occupy-place time in time delay queue and can just leave and prolong When queue, but the time of server real response request may but be not limited to prior to request leave latency team The time of row.
The number of requests of time delay queue exceedes threshold values, then into step S87:If sending busy information to use Family terminal.
Current limiting protecting method based on time delay queue provided in an embodiment of the present invention can be in real time according to time delay team The request of the quantity response user terminal of the request in row, can meet the situation of user's request random distribution, And after waiting the occupy-place time, allow the request to leave the time delay queue and compare and real-time judge institute State whether the request in time delay queue meets the occupy-place time, server process energy can met In the case of power surplus, system operations number of times is reduced.
Server of the invention, the current-limiting protection system and method based on time delay queue basis can prolong in real time When queue in request quantity response user terminal request, user's request random distribution can be met Situation, and the request in time delay queue when meeting the occupy-place time just by time delay queue Number of requests is correspondingly reduced, and can meet the superfluous situation of server handling ability.
It should be noted that each embodiment in this specification is described by the way of progressive, often What individual embodiment was stressed is all the difference with other embodiment, identical between each embodiment Similar part mutually referring to.For device class embodiment, due to itself and embodiment of the method Substantially similar, so description is fairly simple, related part is referring to the part explanation of embodiment of the method Can.
It should be noted that herein, such as first and second or the like relational terms are only used By an entity or operation with another entity or operate make a distinction, and not necessarily require or Imply between these entities or operation there is any this actual relation or order.And, term " including ", "comprising" or any other variant thereof is intended to cover non-exclusive inclusion so that Process, method, article or device including a series of key elements not only include those key elements, but also Including other key elements being not expressly set out, or also include for this process, method, article or The intrinsic key element of person's device.In the absence of more restrictions, by sentence "including a ..." The key element of restriction, it is not excluded that also exist in the process including key element, method, article or device Other identical element.
One of ordinary skill in the art will appreciate that realizing that all or part of step of above-described embodiment can be with Completed by hardware, it is also possible to instruct the hardware of correlation to complete by program, described program can To be stored in a kind of computer-readable recording medium, storage medium mentioned above can be read-only depositing Reservoir, disk or CD etc..
More than, only it is presently preferred embodiments of the present invention, not make any formal to the present invention Limitation, although the present invention is disclosed above with preferred embodiment, but is not limited to the present invention, Any those skilled in the art, without departing from the scope of the present invention, when available The technology contents of the disclosure above make a little change or are modified to the Equivalent embodiments of equivalent variations, as long as It is, without departing from technical solution of the present invention content, above example to be made according to technical spirit of the invention Any simple modification, equivalent variations and modification, still fall within the range of technical solution of the present invention.

Claims (11)

1. a kind of current limiting protecting method based on time delay queue, it is characterised in that described based on time delay queue Current limiting protecting method include:
The performance parameter of simultaneously Analysis server is collected, so as to obtain the valve of the number of requests in time delay queue Value and the occupy-place time of request;
Receive the request that user terminal sends;
Judge whether the number of requests in the time delay queue exceedes threshold values;
If the number of requests in the time delay queue will prolong not less than threshold values described in the request addition When queue, and it is described request meet the occupy-place time when, allow it is described request leave the time delay team Row;And
If the number of requests of the time delay queue exceedes threshold values, busy information to user's end is sent End.
2. the current limiting protecting method of time delay queue is based on as claimed in claim 1, it is characterised in that It is described and it is described request meet the occupy-place time when, allow it is described request leave the time delay queue Step includes:
Judge whether the request in the time delay queue meets the occupy-place time;
If the request in the time delay queue meets the occupy-place time, the request is allowed to leave The time delay queue;And
If the request in the time delay queue does not meet the occupy-place time, the judgement is returned The step of whether request in the time delay queue meets the occupy-place time.
3. the current limiting protecting method of time delay queue is based on as claimed in claim 1, it is characterised in that institute State and when the request meets the occupy-place time, allow the request to leave the step of the time delay queue Suddenly include:
Obtain the timestamp that the request adds the time delay queue;And
After waiting the occupy-place time, the request is allowed to leave the time delay queue.
4. the current limiting protecting method of time delay queue is based on as claimed in claim 1, it is characterised in that institute Stating the performance parameter of server includes that network interface card flow, the service condition of input/output interface are corresponded to respectively Performance parameter.
5. the current limiting protecting method of time delay queue is based on as claimed in claim 1, it is characterised in that institute It is the time delay queue with timestamp as priority to state time delay queue.
6. a kind of server, it is characterised in that the server includes:
Acquisition module, the acquisition module is used to collect and analyze the performance parameter of the server, from And obtain threshold values and the occupy-place time of request of number of requests in time delay queue;And
Flow-control module, the flow-control module is used to receive the request of user terminal transmission, and When number of requests in the time delay queue is not less than threshold values, the request is added into the time delay team Row, and the request in the time delay queue is when meeting the occupy-place time, allow it is described ask from Open the time delay queue.
7. server as claimed in claim 6, it is characterised in that the performance parameter bag of the server Include network interface card flow, the service condition of input/output interface distinguishes corresponding performance parameter.
8. server as claimed in claim 6, it is characterised in that the time delay queue is with timestamp It is the time delay queue of priority.
9. a kind of current-limiting protection system based on time delay queue, it is characterised in that described based on time delay queue Current-limiting protection system include user terminal and server;
The user terminal is used to send a request to the server;
The server is used to collect and analyze the performance parameter of the server, so as to obtain time delay team The threshold values of the number of requests in row and the occupy-place time of the request, and asking in the time delay queue When seeking quantity not less than threshold values, the request is added into the time delay queue, and in the time delay queue In request when meeting the occupy-place time, allow the request to leave the time delay queue.
10. the current-limiting protection system of time delay queue is based on as claimed in claim 9, it is characterised in that Service condition institute of the performance parameter of the server including network interface card flow, input/output interface is right respectively The performance parameter answered.
The 11. current-limiting protection systems based on time delay queue as claimed in claim 9, it is characterised in that The time delay queue is the time delay queue with timestamp as priority.
CN201510451329.4A 2015-07-28 2015-07-28 Server, and current-limiting protection system and method based on delay queues Active CN106713171B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510451329.4A CN106713171B (en) 2015-07-28 2015-07-28 Server, and current-limiting protection system and method based on delay queues

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510451329.4A CN106713171B (en) 2015-07-28 2015-07-28 Server, and current-limiting protection system and method based on delay queues

Publications (2)

Publication Number Publication Date
CN106713171A true CN106713171A (en) 2017-05-24
CN106713171B CN106713171B (en) 2020-04-03

Family

ID=58900645

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510451329.4A Active CN106713171B (en) 2015-07-28 2015-07-28 Server, and current-limiting protection system and method based on delay queues

Country Status (1)

Country Link
CN (1) CN106713171B (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107465743A (en) * 2017-08-03 2017-12-12 郑州云海信息技术有限公司 A kind of method and apparatus for handling request
CN110099009A (en) * 2018-01-31 2019-08-06 北京易真学思教育科技有限公司 Dynamic current limiting method and computer-readable medium based on interface response time trend
CN110971561A (en) * 2018-09-28 2020-04-07 阿里巴巴集团控股有限公司 Access request processing method, device and equipment
CN111935782A (en) * 2020-06-29 2020-11-13 福建天泉教育科技有限公司 Optimization method of client retry mechanism and storage medium
CN113032410A (en) * 2019-12-25 2021-06-25 阿里巴巴集团控股有限公司 Data processing method and device, electronic equipment and computer storage medium

Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101159699A (en) * 2007-11-27 2008-04-09 杭州华三通信技术有限公司 Distributed equipment switch network bandwidth dynamic assignment method and apparatus
CN101299764A (en) * 2008-06-19 2008-11-05 中兴通讯股份有限公司 Method for backupping broadband access server for PPPOE access service
CN102307133A (en) * 2011-03-25 2012-01-04 国云科技股份有限公司 Virtual machine scheduling method for public cloud platform
CN102932840A (en) * 2012-11-14 2013-02-13 浙江大学 Wireless router active queue management method based on rates and queue length
CN103107955A (en) * 2011-11-15 2013-05-15 中国移动通信集团公司 Method and device of scheduling packet transport network queues
CN103248583A (en) * 2012-02-09 2013-08-14 迈普通信技术股份有限公司 FIFO (first-in first-out) message queue management method and device based on finite depth
CN104022965A (en) * 2014-05-20 2014-09-03 华为技术有限公司 Message dequeue scheduling method and equipment thereof
CN104202261A (en) * 2014-08-27 2014-12-10 华为技术有限公司 Service request processing method and device
CN104301066A (en) * 2013-07-19 2015-01-21 华为技术有限公司 Data packet transmission method and device
CN104767689A (en) * 2014-01-07 2015-07-08 腾讯科技(深圳)有限公司 Method of controlling network access amount and server

Patent Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101159699A (en) * 2007-11-27 2008-04-09 杭州华三通信技术有限公司 Distributed equipment switch network bandwidth dynamic assignment method and apparatus
CN101299764A (en) * 2008-06-19 2008-11-05 中兴通讯股份有限公司 Method for backupping broadband access server for PPPOE access service
CN102307133A (en) * 2011-03-25 2012-01-04 国云科技股份有限公司 Virtual machine scheduling method for public cloud platform
CN103107955A (en) * 2011-11-15 2013-05-15 中国移动通信集团公司 Method and device of scheduling packet transport network queues
CN103248583A (en) * 2012-02-09 2013-08-14 迈普通信技术股份有限公司 FIFO (first-in first-out) message queue management method and device based on finite depth
CN102932840A (en) * 2012-11-14 2013-02-13 浙江大学 Wireless router active queue management method based on rates and queue length
CN104301066A (en) * 2013-07-19 2015-01-21 华为技术有限公司 Data packet transmission method and device
CN104767689A (en) * 2014-01-07 2015-07-08 腾讯科技(深圳)有限公司 Method of controlling network access amount and server
CN104022965A (en) * 2014-05-20 2014-09-03 华为技术有限公司 Message dequeue scheduling method and equipment thereof
CN104202261A (en) * 2014-08-27 2014-12-10 华为技术有限公司 Service request processing method and device

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107465743A (en) * 2017-08-03 2017-12-12 郑州云海信息技术有限公司 A kind of method and apparatus for handling request
CN107465743B (en) * 2017-08-03 2020-10-16 苏州浪潮智能科技有限公司 Method and device for processing request
CN110099009A (en) * 2018-01-31 2019-08-06 北京易真学思教育科技有限公司 Dynamic current limiting method and computer-readable medium based on interface response time trend
CN110099009B (en) * 2018-01-31 2021-01-26 北京易真学思教育科技有限公司 Dynamic current limiting method based on interface response time trend and computer readable medium
CN110971561A (en) * 2018-09-28 2020-04-07 阿里巴巴集团控股有限公司 Access request processing method, device and equipment
CN113032410A (en) * 2019-12-25 2021-06-25 阿里巴巴集团控股有限公司 Data processing method and device, electronic equipment and computer storage medium
CN111935782A (en) * 2020-06-29 2020-11-13 福建天泉教育科技有限公司 Optimization method of client retry mechanism and storage medium
CN111935782B (en) * 2020-06-29 2023-08-08 福建天泉教育科技有限公司 Optimization method of client retry mechanism and storage medium

Also Published As

Publication number Publication date
CN106713171B (en) 2020-04-03

Similar Documents

Publication Publication Date Title
CN109699084B (en) Information transmission method, terminal and network equipment under unlicensed frequency band
CN104349340B (en) The surfing flow monitoring method and device of mobile terminal
CN109656980A (en) Data processing method, electronic equipment, device and readable storage medium storing program for executing
CN106713171A (en) Server and delay-queue-based current-limiting protection system and method
CN106657528A (en) Incoming call management method and device
CN107360332A (en) Talking state display methods, device, mobile terminal and storage medium
CN107613536A (en) Select method, apparatus, mobile terminal and the readable storage medium storing program for executing of network
CN107193610A (en) A kind of loading method of dynamic base, device, terminal device and storage medium
CN107608720A (en) Using the display methods of footmark, device, mobile terminal and storage medium
CN107948055A (en) Shielding group members send out the method, apparatus and computer-readable recording medium of message
CN109922539B (en) Network connection method and related product
CN107872555A (en) Call recording method, device, terminal device and computer-readable recording medium
CN106488413A (en) Notification message based reminding method and mobile terminal
CN107193445A (en) Interface of mobile terminal switches display methods and display device
CN107466033A (en) IMS register method, device, mobile terminal and storage medium
CN106815025A (en) Sensing data report method and device
CN106708240A (en) Power saving method, server and power saving system
CN107222629A (en) Call processing method and related product
CN105704106B (en) A kind of visualization IVR implementation method and mobile terminal
CN106331258A (en) Call methods, call apparatus and call system
CN105843361A (en) Method for reducing power consumption while photographing, and mobile terminal
CN104113620A (en) Contact list updating method, updating device and user terminal
CN106503023A (en) The method and device of prompting nearby friends
CN107819943A (en) Call processing method and Related product
CN107613535A (en) Method for network access, device, mobile terminal and computer-readable recording medium

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
GR01 Patent grant
GR01 Patent grant