Concurrent resource optimization method, system, equipment and medium
By collecting concurrent states in real time and generating optimization strategies, the user experience problem caused by idle concurrent connections in high-concurrency systems is solved, and efficient resource utilization and user experience are achieved.
Patent Information
- Application Number
- CN202411593528.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-08
- Publication Date
- 2025-02-18
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
In high concurrency systems, the occupied concurrent connections often have idle time slices, which leads to other users being unable to access and affects the user experience.
Through the resource monitoring interface, the system concurrency status is collected in real time, and whether there is idle resource, intelligently match the optimization timing based on the idle details, generate optimization strategies through dynamic balance of idle degree and request density, and implement resource optimization in the obtained scheduling permissions.
It realizes efficient utilization of concurrent resources, improves user experience, and avoids frequent system oscillations caused by single indicator judgment deviations in traditional methods.
Smart Images

Figure CN119473610A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of concurrent resource optimization, and in particular to a concurrent resource optimization method, system, device and medium. Background Art
[0002] In high-concurrency systems such as cloud games and distributed services, background services usually set concurrency limits to ensure business performance. However, there are often idle time slices in the occupied concurrent connections, which may come from temporary idleness of users or system verification intervals. For example, in the cloud game login scenario, the user occupying the login connection may be in a low resource consumption state, but it hinders other users from logging in, resulting in a damaged online user experience. This situation needs to be further improved. Summary of the invention
[0003] In order to solve the problem of impaired experience caused by idle resources in the existing environment, the present application provides a concurrent resource optimization method, system, device and medium, which adopts the following technical solutions: In a first aspect, the present application provides a concurrent resource optimization method, comprising the following steps: Collect system concurrency status through the resource monitoring interface to determine whether there are idle resources; If yes, determining the optimization opportunity according to the idle state of the resource; Obtaining the idleness and request density during the optimization opportunity and generating an optimization strategy; Matching a target scheduling solution according to the optimization strategy; Obtaining a target optimization area corresponding to the idle state, and obtaining a scheduling authority corresponding to the target optimization area; Resource optimization is implemented in the scheduling authority according to the target scheduling scheme.
[0004] By adopting the above technical solution, in application scenarios such as cloud games, there is often a contradictory situation in which some users occupy the connection but are in a low resource consumption state, while a large number of new users cannot access; this application first collects the system operation status in real time through the resource monitoring interface, and makes idle judgments based on multiple dimensions such as the number of connections, idle time and request waiting; then, it intelligently matches the optimization time based on the idle details, and generates an optimization strategy through a dynamic balance between the idle degree and the request density; finally, it implements resource scheduling for the target optimization area, realizes efficient use of concurrent resources, and improves user experience.
[0005] Optionally, the system concurrent status is collected through the resource monitoring interface to determine whether there are idle resources, which specifically includes the following steps: Collect system concurrency status through the monitoring interface and obtain resource utilization scores in the system; Obtaining a utilization threshold value in a preset idle condition; The utilization rate threshold and the resource utilization score are combined to determine whether there is idle resource.
[0006] By adopting the above technical solution, the traditional distributed service platform only makes judgments based on the number of connections. When a decrease in the number of connections is detected, resource recovery is triggered, but the characteristics of short-term fluctuations and business peaks are ignored, resulting in frequent system fluctuations. The present application first collects the current operating data of the system through the monitoring interface to obtain a score that reflects the system resource utilization status; then obtains the utilization threshold that matches the current business scenario from the preset idle condition library; finally, the resource utilization score is intelligently compared with the threshold to realize the idle state judgment, avoid the judgment deviation caused by a single indicator, and can flexibly adjust the judgment standard according to different scenarios, which significantly improves the accuracy and adaptability of resource idle judgment.
[0007] Optionally, the system concurrency status is collected through a monitoring interface to obtain a resource utilization score in the system, which specifically includes the following steps: Collect system concurrency status through the monitoring interface to obtain the number of connections, idle time and request waiting status corresponding to the system concurrency status; Generate a concurrent exception value according to the number of connections; Generate an idle degree value according to the idle duration; generating a request pressure value according to the request waiting situation; A resource utilization score is determined according to the concurrent exception value, the idle degree value, and the request pressure value.
[0008] By adopting the above technical solution, the present application first comprehensively collects system operation data through the monitoring interface, including the number of connections, idle time distribution and request waiting status; then calculates the concurrency anomaly value, idle degree value and request pressure value respectively, among which the concurrency anomaly value reflects the current connection usage deviation, the idle degree value is used to quantify the proportion of idle resources, and the request pressure value represents the system load demand; finally, through the weighted fusion of these three core indicators, an evaluation score is generated that can comprehensively reflect the efficiency of system resource utilization, thereby realizing the quantification of system resource utilization status.
[0009] Optionally, determining the optimization timing according to the idle state of the resource specifically includes the following steps: Obtaining idle details in the idle state; Generate an optimization tag according to the idle details content; The optimization opportunity is determined according to the optimization tag in the preset optimization opportunity set.
[0010] By adopting the above technical solution, the present application first deeply analyzes the detailed characteristics of the idle state, including the distribution location, duration, and correlation with the business load of idle resources; then, based on these characteristic information, extracts key attributes and generates optimization tags with semantic characteristics; finally, in the pre-established optimization timing knowledge base, the optimization timing that best suits the current scenario is selected through a label matching algorithm, thereby ensuring the accuracy of the optimization timing selection and realizing adaptive adjustment to different business scenarios.
[0011] Optionally, the step of obtaining the idle degree and the request density and generating an optimization strategy during the optimization opportunity specifically includes the following steps: obtaining the idleness level and the request density during the optimization opportunity; determining release conditions based on the level of inactivity; determining allocation conditions according to the request density; An optimization strategy is generated according to the release condition and the allocation condition.
[0012] By adopting the above technical solution, since the resource optimization strategy in the concurrent system needs to balance the two key dimensions of resource release and allocation at the same time, the traditional fixed-ratio release or passive allocation method often cannot achieve the optimal configuration of resources; the present application first obtains the idleness and request density of the system at a determined optimization time; then customizes the specific conditions such as the timing, quantity and rhythm of resource release based on the idleness; at the same time, formulates detailed rules such as the allocation priority and allocation ratio of new resources according to the request density; finally, the release conditions and allocation conditions are intelligently coordinated to generate an overall optimization strategy that takes into account both efficiency and stability. Through the dynamic balance mechanism of idle resource release and new demand allocation, not only the blind optimization in the traditional method is avoided, but also the precise control of resource scheduling is achieved.
[0013] Optionally, obtaining a target optimization area corresponding to the idle state and obtaining a scheduling authority corresponding to the target optimization area specifically includes the following steps: Obtaining a target optimization area corresponding to the idle state; Determine a scheduling strategy according to the target optimization area; Determine a scheduling port according to the scheduling policy and send a resource verification identifier to the scheduling port to receive authorization information fed back from the scheduling port; The scheduling authority corresponding to the target optimization area is obtained according to the authorization information.
[0014] By adopting the above technical solution, the present application first locates the target optimization area corresponding to the idle state to ensure the accuracy of the optimization range; then formulates a scheduling plan that complies with the security policy based on the characteristics of the optimization area; then establishes a trusted authorization channel by sending a verification request carrying a security identifier to a specific scheduling port; finally, obtains scheduling operation permissions based on the received authorization information; and achieves controllability of the resource optimization process by establishing a complete security chain of resource areas, scheduling policies, port verification, and permission granting.
[0015] Optionally, after determining the scheduling strategy according to the target optimization area, the method further includes the following steps: Obtain preset verification information, and traverse the preset verification information according to the target optimization area to obtain a traversal result; Determine target verification information according to the traversal result; The resource verification condition of the target optimization area is obtained, and a resource verification identifier is generated in combination with the target verification information.
[0016] By adopting the above technical scheme, since the generation of resource verification identifiers in the concurrent system is directly related to the security of scheduling operations, traditional fixed-format verification identifiers or simple random generation methods are easy to be cracked or forged, and there are serious security risks; this application first obtains the preset verification rules and templates from the verification information library, and performs intelligent traversal matching according to the characteristics of the target optimization area to find the most suitable verification basic information for the current scenario; then the traversal results are converted into target verification information; finally, combined with the specific verification conditions of the optimization area, a resource verification identifier is generated, which ensures the uniqueness and unpredictability of the verification identifier, while realizing differentiated security protection for different optimization areas.
[0017] In a second aspect, the present application provides a concurrent resource optimization system, comprising: A judgment module is used to collect system concurrency status through a resource monitoring interface to determine whether there are idle resources; an optimization timing determination module, for determining the optimization timing according to the idle state of the resource if yes; An optimization strategy generation module, used to obtain the idleness and request density during the optimization opportunity and generate an optimization strategy; A scheduling scheme matching module, used to match a target scheduling scheme according to the optimization strategy; A scheduling authority acquisition module, used to acquire the target optimization area corresponding to the idle state, and acquire the scheduling authority corresponding to the target optimization area; A resource optimization module is used to implement resource optimization in the scheduling authority according to the target scheduling solution.
[0018] In a third aspect, the present application provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of the above-mentioned concurrent resource optimization method when executing the computer program.
[0019] In a fourth aspect, the present application provides a computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the steps of the above-mentioned concurrent resource optimization method are implemented.
[0020] In summary, the present application includes at least one of the following beneficial technical effects: 1. This application first collects the system operation status in real time through the resource monitoring interface, and makes idle judgments based on multiple dimensions such as the number of connections, idle time, and request waiting; then intelligently matches the optimization timing based on the idle details, and generates an optimization strategy through the dynamic balance of idle degree and request density; finally, resource scheduling is implemented for the target optimization area, achieving efficient use of concurrent resources and improving user experience; 2. Traditional distributed service platforms only make judgments based on the number of connections. When a decrease in the number of connections is detected, resource recovery is triggered, but the characteristics of short-term fluctuations and business peaks are ignored, resulting in frequent system shocks. This application first collects the current operating data of the system through the monitoring interface to obtain a score reflecting the system resource utilization status; then obtains the utilization threshold matching the current business scenario from the preset idle condition library; finally, the resource utilization score is intelligently compared with the threshold to realize the idle state judgment, avoiding the judgment deviation caused by a single indicator, and can flexibly adjust the judgment standard according to different scenarios, significantly improving the accuracy and adaptability of resource idle judgment; 3. This application first comprehensively collects system operation data through the monitoring interface, including the number of connections, idle time distribution and request waiting status; then calculates the concurrency anomaly value, idle degree value and request pressure value respectively, among which the concurrency anomaly value reflects the current connection usage deviation, the idle degree value is used to quantify the proportion of idle resources, and the request pressure value represents the system load demand; finally, through the weighted fusion of these three core indicators, an evaluation score is generated that can comprehensively reflect the efficiency of system resource utilization, thereby realizing the quantification of system resource usage status. BRIEF DESCRIPTION OF THE DRAWINGS
[0021] Figure 1 It is a flowchart of a concurrent resource optimization method according to an embodiment of the present application; Figure 2 It is a flowchart of step S110 in a concurrent resource optimization method in an embodiment of the present application; Figure 3 It is a flowchart of step S120 in a concurrent resource optimization method in an embodiment of the present application; Figure 4 It is a flowchart of step S130 in a concurrent resource optimization method in an embodiment of the present application; Figure 5 It is a flowchart of step S150 in a concurrent resource optimization method in an embodiment of the present application; Figure 6 It is a schematic diagram of a process of generating a resource verification identifier in a concurrent resource optimization method in an embodiment of the present application; Figure 7 It is a module diagram of a concurrent resource optimization system according to an embodiment of the present application; Figure 8 It is a diagram of the internal structure of an electronic device according to an embodiment of the present application. DETAILED DESCRIPTION
[0022] The terms used in the following embodiments of the present application are only for the purpose of describing specific embodiments, and are not intended to be used as limitations to the present application. As used in the specification and appended claims of the present application, the singular expressions "one", "a kind of", "said", "above", "the" and "this" are intended to also include plural expressions, unless there is a clear indication to the contrary in the context. It should also be understood that the term "and / or" used in the present application refers to any or all possible combinations comprising one or more listed items.
[0023] In the following, the terms "first" and "second" are used for descriptive purposes only and are not to be understood as suggesting or implying relative importance or implicitly indicating the number of the indicated technical features. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of the features, and in the description of the embodiments of the present application, unless otherwise specified, "plurality" means two or more.
[0024] The embodiments of the present application are further described in detail below in conjunction with the drawings in the specification.
[0025] In the first aspect, the present application provides a concurrent resource optimization method, referring to Figure 1 , including the following steps: S110. Collect system concurrency status through a resource monitoring interface to determine whether there are idle resources.
[0026] Among them, the resource monitoring interface refers to the programmatic interface used in the system to collect and monitor the system operation status in real time, which can obtain the current number of connections, resource occupancy, request queue and other information of the system. Resource idleness refers to the existence of underutilized computing resources, storage resources or network resources in the system.
[0027] Specifically, the system collects system status information every preset time period (e.g., 10 seconds) through the resource monitoring interface, and compares the collected information with the preset resource idleness judgment condition. For example, when the system detects that the CPU utilization rate of a certain area is less than 30% and lasts for more than 5 minutes, it is determined that there is resource idleness in the area.
[0028] If yes, then execute step S120. S120: Determine an optimization opportunity according to the idle state of resources.
[0029] Among them, the optimization timing refers to the best time point for the system to schedule resources, which needs to comprehensively consider the system load status, business peak characteristics and historical optimization experience. The idle state includes characteristic information such as the location, degree and duration of idle resources.
[0030] Specifically, the system selects a suitable execution time from a preset set of optimization opportunities based on the currently detected idle state characteristics and pre-set business rules (such as avoiding business peaks, reserving buffer time, etc.). For example, if a data processing node is detected to be idle, the system will choose to optimize at 3 a.m. during the business off-peak period.
[0031] S130: Obtain the idleness and request density during the optimization period and generate an optimization strategy.
[0032] Among them, the idle degree reflects the idleness of system resources, which is measured by resource utilization and idle time. Request density refers to the number of resource requests received by the system per unit time, reflecting the load demand of the system.
[0033] Specifically, at the determined optimization time, the system calculates the proportion of idle resources and the length of the current request queue, and formulates corresponding resource release and allocation strategies based on the balance between these two indicators. For example, when it is detected that 40% of the computing resources are idle and there are a large number of waiting tasks in the request queue, the system will generate an optimization strategy of "quick release + priority allocation".
[0034] S140. Match the target scheduling plan according to the optimization strategy.
[0035] Among them, the target scheduling plan refers to the specific resource scheduling execution plan, including resource release order, allocation priority and scheduling path.
[0036] Specifically, the system selects the execution plan with the highest matching degree from the preset scheduling plan library according to the generated optimization strategy.
[0037] S150. Obtain a target optimization area corresponding to the idle state, and obtain a scheduling authority corresponding to the target optimization area.
[0038] The target optimization area refers to the system area that needs to be optimized for resources, and the scheduling authority refers to the authorization level that the system allows to perform resource scheduling operations in this area. The location information of the idle state determines the scope of the target optimization area.
[0039] Specifically, the system first determines the specific area that needs to be optimized based on the idle status information, and then applies to the authority management module for the scheduling operation permission for the area. For example, when a node in a computing cluster is found to be idle, the system will locate the specific node group and apply for resource scheduling permission for the node group.
[0040] S160. Implement resource optimization according to the target scheduling plan in the scheduling authority.
[0041] Among them, resource optimization refers to the process of reallocating and adjusting system resources according to the scheduling plan, which needs to be operated within the scope of the obtained authority.
[0042] Specifically, after obtaining authorization, the system performs resource optimization operations according to the steps of the scheduling plan, including releasing idle resources, reallocating resources, etc., and monitors the changes in system status during the optimization process in real time. For example, the system will release the resources of idle nodes in a predetermined order and allocate the released resources to high-priority tasks in the waiting queue.
[0043] In one embodiment, referring to Figure 2 In step S110, the system concurrent status is collected through the resource monitoring interface to determine whether there are idle resources, which specifically includes the following steps: S111. Collect system concurrency status through the monitoring interface and obtain resource utilization scores in the system.
[0044] The monitoring interface of this embodiment is a resource status collection module in the system, which is responsible for collecting various status indicators during the operation of the system.
[0045] In this embodiment, step S111 includes collecting the system concurrency status through the monitoring interface, obtaining the number of connections, idle time and request waiting status corresponding to the system concurrency status; generating a concurrency exception value according to the number of connections; generating an idle degree value according to the idle time; generating a request pressure value according to the request waiting status; determining the resource utilization score according to the concurrency exception value, idle degree value and request pressure value.
[0046] Specifically, the monitoring interface first collects the original indicator data of the current system, and then generates the evaluation values of each dimension through specific calculation rules. For example, if the system detects that the number of active connections of a service node is only 20% of the maximum number of connections, and it has been in this state for 3 consecutive hours, and the request queue is empty, the concurrent abnormality value, idleness value and request pressure value are calculated respectively, and finally the comprehensive resource utilization score is obtained through weighted calculation.
[0047] S112: Obtain a utilization threshold in a preset idle condition.
[0048] Among them, the utilization threshold is a set of resource idleness judgment criteria pre-set by the system, including the critical values of resource utilization in different scenarios, which are formulated based on historical operating experience and business needs.
[0049] Specifically, the system reads the utilization threshold configuration applicable to the current scenario from the configuration management module. For example, during normal business hours, the utilization threshold set by the system is 0.4, which means that when the resource utilization score is lower than 0.4, there may be idle resources; during business peak hours, this threshold may be adjusted to 0.6 to maintain more resource reserves.
[0050] S113. Determine whether there is idle resource by combining the utilization rate threshold and the resource utilization score.
[0051] Among them, the judgment of resource idleness requires comparing the real-time calculated resource utilization score with the preset utilization threshold, while considering the current operation stage and business characteristics of the system.
[0052] Specifically, the system compares the resource utilization score calculated in step S111 with the utilization threshold obtained in step S112. If the resource utilization score is continuously lower than the threshold, the system determines that there is idle resource in the system. For example, when the resource utilization score of a computing node is 0.7, which is greater than the preset utilization threshold of 0.4, the system determines that there is no idle resource in the node; on the contrary, if the resource utilization score is 0.3 and is lower than the threshold for a period of time, it is determined that there is idle resource and subsequent optimization processing is required.
[0053] In one embodiment, referring to Figure 3 In step S120, the optimization timing is determined according to the idle state of resources, which specifically includes the following steps: S121. Obtain idle details in the idle state.
[0054] In this embodiment, the system obtains a complete idle status report from the resource monitoring module, and performs structured analysis on the report to extract key idle feature information. For example, after the system detects an idle state in a data processing cluster, it will record detailed information such as the specific number of idle nodes, idle time characteristics, and idle resource types.
[0055] S122: Generate an optimization tag according to the idle details.
[0056] Among them, the optimization label is a characteristic mark that the system marks for the idle state based on the idle details and specific label generation rules. These labels can reflect the urgency of idleness, the difficulty level of optimization, the recommended processing method and other attributes.
[0057] Specifically, the system uses a multi-dimensional label classification system to convert idle details into a set of standardized labels. For example, for the detected idle state, the system may generate label combinations such as "periodic idle", "medium scale", and "computation intensive".
[0058] S123: Determine an optimization opportunity in a preset optimization opportunity set according to the optimization tag.
[0059] Among them, the preset optimization time set is a time point library maintained by the system, which contains time nodes suitable for resource optimization in different scenarios.
[0060] Specifically, the system performs matching calculations on the generated optimization tags and the predefined time point features in the optimization opportunity set, and selects the time point with the highest matching degree as the optimization opportunity.
[0061] In one embodiment, referring to Figure 4 In step S130, the step of obtaining the idle degree and request density at the optimization opportunity and generating an optimization strategy specifically includes the following steps: S131. Obtain the idleness and request density during optimization.
[0062] In this embodiment, the idleness refers to the severity of the idle state of system resources, which is measured by resource utilization, idle time and the number of idle resources. The request density reflects the current resource demand intensity of the system, including information in dimensions such as request queue length, request arrival frequency, and requested resource quantity.
[0063] Specifically, when the determined optimization opportunity arrives, the system collects and calculates the idle degree and request density indicators in real time.
[0064] S132. Determine release conditions according to the idleness level.
[0065] The release condition refers to the set of rules that the system needs to follow when releasing resources, including the proportion of resources to be released, the priority order of release, and the time schedule of release.
[0066] Specifically, the system generates a release condition that meets the current scenario based on the idle degree value and with reference to a preset release policy template.
[0067] S133. Determine allocation conditions according to request density.
[0068] Among them, the allocation conditions include priority rules for resource allocation, allocation ratio restrictions and allocation timing arrangements.
[0069] Specifically, the system analyzes the numerical characteristics of request density and formulates detailed resource allocation conditions based on business priority rules.
[0070] S134. Generate an optimization strategy according to the release condition and the allocation condition.
[0071] In one embodiment, referring to Figure 5 In step S150, the target optimization area corresponding to the idle state is obtained, and the scheduling authority corresponding to the target optimization area is obtained, which specifically includes the following steps: S151. Obtain a target optimization area corresponding to an idle state.
[0072] The target optimization area refers to the system scope that requires resource scheduling optimization, including physical areas (such as server racks, network partitions) and logical areas (such as business units, functional modules).
[0073] Specifically, the system identifies and delineates specific areas that need to be optimized based on the location features in the idle status information and the system topology. For example, when a computing cluster in a data center is detected to be idle, the system will locate the specific rack group (such as racks 3-8 in area A) and mark the physical area and its associated business processing units as the target optimization area.
[0074] S152. Determine a scheduling strategy according to the target optimization area.
[0075] Among them, the scheduling strategy defines the specific methods and rules for the system to schedule resources in the target optimization area, including the execution order of scheduling, the authority level of scheduling, and the security restrictions of scheduling.
[0076] Specifically, the system analyzes the properties of the target optimization area, including the area level, business importance and security requirements, and selects or generates an adaptive scheduling strategy from the preset scheduling strategy library. For example, for the optimization area containing the core business nodes, the system will adopt the "progressive scheduling" strategy, requiring the gradual adjustment of resource allocation and setting strict security checkpoints; while for ordinary business areas, the "fast scheduling" strategy may be adopted to simplify the scheduling process.
[0077] S153: Determine a scheduling port according to the scheduling policy and send a resource verification identifier to the scheduling port to receive authorization information fed back from the scheduling port.
[0078] Among them, the scheduling port is the access point in the system responsible for processing resource scheduling requests, and each port has its corresponding authority level and processing capability.
[0079] S154. Obtain the scheduling authority corresponding to the target optimization area according to the authorization information.
[0080] Specifically, after receiving the authorization information returned by the dispatch port, the system parses the permission description therein and converts it into an executable operation permission list.
[0081] In one embodiment, referring to Figure 6 , step S152, after determining the scheduling strategy according to the target optimization area, the method further includes the following steps: S210: Obtain preset verification information, traverse the preset verification information according to the target optimization area, and obtain the traversal result.
[0082] Among them, the preset verification information is a set of verification rules and standards pre-configured in the system, which includes verification elements, verification processes and verification parameters for different optimization areas.
[0083] Specifically, the system reads all available validation rules from the validation rule library and matches the rules according to the characteristics of the target optimization area (such as area type, business attributes, security level, etc.).
[0084] S220. Determine target verification information according to the traversal result.
[0085] The target verification information is a set of verification rules that are most suitable for the current optimization area and are selected from the traversal results.
[0086] Specifically, the system prioritizes and filters the validation rules obtained through the traversal, and selects the validation rule combination that best suits the current scenario.
[0087] S230: Obtain resource verification conditions of the target optimization area, and generate a resource verification identifier in combination with the target verification information.
[0088] Among them, resource verification conditions are resource usage restrictions and requirements unique to the target optimization area, including specific conditions such as resource quotas, performance indicators, and security requirements. The system needs to combine these conditions with the target verification information to generate a complete verification mark.
[0089] Specifically, the system first obtains the resource verification conditions of the target optimization area, such as resource usage limits, performance requirements, and security levels, and then integrates these conditions with the previously determined target verification information. For example, the verification conditions of a computing cluster require "CPU usage not exceeding 80%, memory usage not exceeding 75%, and response time less than 100ms". The system will combine these specific indicators with the verification rules to generate a complete verification mark containing verification rules, threshold parameters, and verification processes for the subsequent resource scheduling authorization process.
[0090] It should be understood that the size of the serial numbers of the steps in the above embodiments does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present application.
[0091] In a second aspect, the present application provides a concurrent resource optimization system. The following describes a concurrent resource optimization system of the present application in combination with the above-mentioned concurrent resource optimization method.
[0092] Reference Figure 7 , a concurrent resource optimization system, comprising: A judgment module is used to collect system concurrency status through a resource monitoring interface to determine whether there are idle resources; An optimization timing determination module is used to determine the optimization timing according to the idle state of resources if so; An optimization strategy generation module is used to obtain the idleness and request density during optimization and generate an optimization strategy; A scheduling scheme matching module is used to match the target scheduling scheme according to the optimization strategy; A scheduling authority acquisition module is used to obtain the target optimization area corresponding to the idle state and obtain the scheduling authority corresponding to the target optimization area; The resource optimization module is used to implement resource optimization according to the target scheduling plan in the scheduling authority.
[0093] In one embodiment, the present application provides an electronic device, which may be a server, and its internal structure diagram may be as follows: Figure 8As shown. The electronic device includes a processor, a memory and a network interface connected through a system bus. Among them, the processor of the electronic device is used to provide computing and control capabilities. The memory of the electronic device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the electronic device is used to store data. The network interface of the electronic device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, a concurrent resource optimization method is implemented.
[0094] Those skilled in the art will understand that Figure 8 The structure shown in the figure is merely a block diagram of a partial structure related to the scheme of the present application, and does not constitute a limitation on the electronic device to which the scheme of the present application is applied. The specific electronic device may include more or fewer components than shown in the figure, or combine certain components, or have a different arrangement of components.
[0095] In one embodiment, an electronic device is further provided, including a memory and a processor, wherein a computer program is stored in the memory, and the processor implements the steps in the above method embodiments when executing the computer program.
[0096] Those of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the above-mentioned computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), tape, floppy disk, flash memory or optical memory, etc. Volatile memory can include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM).
[0097] The above are all preferred embodiments of the present application, and the protection scope of the present application is not limited thereto. Therefore, any equivalent changes made according to the structure, shape, and principle of the present application should be included in the protection scope of the present application.
Claims
1. A concurrent resource optimization method, characterized in that: The steps include: Collect system concurrency status through the resource monitoring interface to determine whether there are idle resources; If yes, determining the optimization opportunity according to the idle state of the resource; Obtaining the idleness and request density during the optimization opportunity and generating an optimization strategy; Matching a target scheduling solution according to the optimization strategy; Obtaining a target optimization area corresponding to the idle state, and obtaining a scheduling authority corresponding to the target optimization area; Resource optimization is implemented in the scheduling authority according to the target scheduling scheme.
2. The concurrent resource optimization method according to claim 1, characterized in that: The resource monitoring interface is used to collect system concurrency status and determine whether there are idle resources. The specific steps include the following: Collect system concurrency status through the monitoring interface and obtain resource utilization scores in the system; Obtaining a utilization threshold value in a preset idle condition; The utilization rate threshold and the resource utilization score are combined to determine whether there is idle resource.
3. The concurrent resource optimization method according to claim 2, characterized in that: The system concurrent status is collected through the monitoring interface to obtain the resource utilization score in the system, which includes the following steps: Collect system concurrency status through the monitoring interface to obtain the number of connections, idle time and request waiting status corresponding to the system concurrency status; Generate a concurrent exception value according to the number of connections; Generate an idle degree value according to the idle duration; generating a request pressure value according to the request waiting situation; A resource utilization score is determined according to the concurrent exception value, the idleness value, and the request pressure value.
4. The concurrent resource optimization method according to claim 1, characterized in that: Determining the optimization timing according to the idle state of the resource specifically includes the following steps: Obtaining idle details in the idle state; Generate an optimization tag according to the idle details content; The optimization opportunity is determined according to the optimization tag in the preset optimization opportunity set.
5. The concurrent resource optimization method according to claim 1, characterized in that: The step of obtaining the idle degree and request density and generating an optimization strategy during the optimization opportunity specifically includes the following steps: obtaining the idleness level and the request density during the optimization opportunity; determining release conditions based on the level of inactivity; determining allocation conditions according to the request density; An optimization strategy is generated according to the release condition and the allocation condition.
6. The concurrent resource optimization method according to claim 1, characterized in that: Obtaining the target optimization area corresponding to the idle state and obtaining the scheduling authority corresponding to the target optimization area specifically includes the following steps: Obtaining a target optimization area corresponding to the idle state; Determine a scheduling strategy according to the target optimization area; Determine a scheduling port according to the scheduling policy and send a resource verification identifier to the scheduling port to receive authorization information fed back from the scheduling port; The scheduling authority corresponding to the target optimization area is obtained according to the authorization information.
7. The concurrent resource optimization method according to claim 6, characterized in that: After determining the scheduling strategy according to the target optimization area, the method further includes the following steps: Obtain preset verification information, and traverse the preset verification information according to the target optimization area to obtain a traversal result; Determine target verification information according to the traversal result; The resource verification condition of the target optimization area is obtained, and a resource verification identifier is generated in combination with the target verification information.
8. A concurrent resource optimization system, characterized in that: include: A judgment module is used to collect system concurrency status through a resource monitoring interface to determine whether there are idle resources; an optimization timing determination module, for determining the optimization timing according to the idle state of the resource if yes; An optimization strategy generation module, used to obtain the idleness and request density during the optimization opportunity and generate an optimization strategy; A scheduling scheme matching module, used to match a target scheduling scheme according to the optimization strategy; A scheduling authority acquisition module, used to acquire the target optimization area corresponding to the idle state, and acquire the scheduling authority corresponding to the target optimization area; A resource optimization module is used to implement resource optimization in the scheduling authority according to the target scheduling solution.
9. An electronic device, characterized in that: The method comprises a memory, a processor and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, the steps of the concurrent resource optimization method according to any one of claims 1 to 7 are implemented.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the concurrent resource optimization method described in any one of claims 1 to 7 are implemented.
Citation Information
Patent Citations
Method for preventing website access congestion
CN102170400A
Cloud resource intelligent recovery method and system, and terminal equipment
CN118689639A