Overload protection method and apparatus
An overload protection and request message technology, applied in the computer field, can solve the problems of difficult dynamic change of the threshold, difficult setting of the threshold, unsuitable for batch promotion, etc., and achieve the effect of shortening the recovery time and improving the stability
- Summary
- Abstract
- Description
- Claims
- Application Information
AI Technical Summary
Problems solved by technology
Method used
Image
Examples
Embodiment 1
[0022] figure 1 It is a flow chart of the overload protection method provided by Embodiment 1 of the present invention. This embodiment is applicable to the situation where the request message received by the server is overloaded. The method can be executed by an overload protection device, and specifically includes the following steps:
[0023] Step 110, acquire the request message in the communication queue.
[0024] At present, in order to efficiently process the request messages sent by the client and give timely feedback on the processing results, the server can adopt the Master / Slave architecture model. Based on the Master / Slave architecture model, the server can be built into a multi-process architecture model or multi-thread Architecture model. Among them, Master, as the main database server, is responsible for receiving the request message sent by the client and sending it to the communication queue, so that Slave can obtain the request message from the communication...
Embodiment 2
[0033] figure 2 It is a schematic flowchart of an overload protection method provided by Embodiment 2 of the present invention. This embodiment optimizes on the basis of above-mentioned embodiment, judges that current service end is in service overload high water level, has increased following steps after discarding request message: record the quantity of discarding request message of high water level; Judging whether the quantity of high water level discarding request message The preset overload recovery threshold is reached, and if so, the service overload high water mark is turned off.
[0034] Therefore, after discarding the request message, it is determined whether to close the service overload high water mark by judging whether the number of recorded high-water mark discard request messages reaches the preset overload recovery threshold, so as to restore the normal operation of the server.
[0035] Correspondingly, the method of this embodiment includes the following s...
Embodiment 3
[0048] image 3 It is a schematic flowchart of an overload protection method provided by Embodiment 3 of the present invention. This embodiment is optimized on the basis of the above embodiments. The current server is not at the high water level of service overload. According to the enqueue time of the request message in the communication queue, it is judged whether the queue waiting time of the request message is overloaded. If so, After discarding the request message, the following steps are added: record the quantity of the queue waiting time overload and continuously discard the request message; judge whether the quantity of the queue waiting time overload and continuously discard the request message reaches the overload high water mark, if so, then open the service overload high water mark.
[0049] Thus, after discarding the request message, by judging whether the recorded queue waiting time overload and the number of continuously discarding request messages reach the pr...
PUM

Abstract
Description
Claims
Application Information

- R&D
- Intellectual Property
- Life Sciences
- Materials
- Tech Scout
- Unparalleled Data Quality
- Higher Quality Content
- 60% Fewer Hallucinations
Browse by: Latest US Patents, China's latest patents, Technical Efficacy Thesaurus, Application Domain, Technology Topic, Popular Technical Reports.
© 2025 PatSnap. All rights reserved.Legal|Privacy policy|Modern Slavery Act Transparency Statement|Sitemap|About US| Contact US: help@patsnap.com