A method and device for dynamically allocating server threads
A dynamic allocation and server-side technology, applied in the Internet field, can solve the problems that the interface response time cannot be allocated to the server-side thread, the server-side thread cannot be released in time, and the RPC request message cannot be processed in time.
- Summary
- Abstract
- Description
- Claims
- Application Information
AI Technical Summary
Problems solved by technology
Method used
Image
Examples
Embodiment 1
[0049] Aiming at the problems existing in the prior art, Embodiment 1 of the present application provides a method for dynamically allocating server threads. The method is applied to a system including a server and multiple clients, and the system may be a distributed system. Such as figure 1 As shown, the dynamic allocation method of the server thread includes the following steps:
[0050] Step 101, the server uses the interface information corresponding to each interface to allocate the number of first server threads of each interface. Wherein, the interface information corresponding to each interface specifically includes, but is not limited to: the average interface response time corresponding to each interface within a specified time period (such as from the 100th millisecond before the current time to the current time), and / or, the response time of each interface at the specified time The number of received RPC request messages corresponding to the segment.
[0051] Us...
Embodiment 2
[0081] Based on the same application concept as the above method, a server is also provided in the embodiment of the present application, such as figure 2 As shown, the server specifically includes: an allocation module 11, configured to allocate the number of first server threads corresponding to each interface by using the interface information corresponding to each interface; a determination module 12, configured to receive a remote procedure call RPC request After the message, determine the number of second server threads that the interface corresponding to the RPC request message has currently started; processing module 13, for when the number of second server threads is less than the number of first server threads corresponding to the interface , then start the server thread for the RPC request message; when the number of the second server thread is equal to the number of the first server thread corresponding to the interface, then refuse to start the server thread for t...
PUM
Abstract
Description
Claims
Application Information
- R&D Engineer
- R&D Manager
- IP Professional
- Industry Leading Data Capabilities
- Powerful AI technology
- Patent DNA Extraction
Browse by: Latest US Patents, China's latest patents, Technical Efficacy Thesaurus, Application Domain, Technology Topic, Popular Technical Reports.
© 2024 PatSnap. All rights reserved.Legal|Privacy policy|Modern Slavery Act Transparency Statement|Sitemap|About US| Contact US: help@patsnap.com