CN117851071A - Application resource allocation method and device, computer equipment and storage medium - Google Patents

Application resource allocation method and device, computer equipment and storage medium Download PDF

Info

Publication number
CN117851071A
CN117851071A CN202410102872.2A CN202410102872A CN117851071A CN 117851071 A CN117851071 A CN 117851071A CN 202410102872 A CN202410102872 A CN 202410102872A CN 117851071 A CN117851071 A CN 117851071A
Authority
CN
China
Prior art keywords
resource
information
target application
value
historical
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.)
Pending
Application number
CN202410102872.2A
Other languages
Chinese (zh)
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.)
Industrial and Commercial Bank of China Ltd ICBC
Original Assignee
Industrial and Commercial Bank of China Ltd ICBC
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 Industrial and Commercial Bank of China Ltd ICBC filed Critical Industrial and Commercial Bank of China Ltd ICBC
Priority to CN202410102872.2A priority Critical patent/CN117851071A/en
Publication of CN117851071A publication Critical patent/CN117851071A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/50Allocation of resources, e.g. of the central processing unit [CPU]
    • G06F9/5005Allocation of resources, e.g. of the central processing unit [CPU] to service a request
    • G06F9/5027Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resource being a machine, e.g. CPUs, Servers, Terminals
    • G06F9/505Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resource being a machine, e.g. CPUs, Servers, Terminals considering the load

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The application relates to a resource allocation method, a resource allocation device, computer equipment and a storage medium of an application, and relates to the field of financial science and technology or other related fields. The method comprises the following steps: firstly, acquiring historical resource information and predicted resource occupation information of a target application; then determining a resource configuration value corresponding to the target application according to the grade of the target application, the historical resource information and the predicted resource occupation information; and then, carrying out resource allocation on the target application according to the resource allocation value. Compared with the existing mode of directly configuring resources according to typical specifications, the method considers the grade of the target application, the historical resource information of the target application and the predicted resource occupation information, and obtains the corresponding resource configuration value based on the grade of the target application, the historical resource information of the target application and the predicted resource occupation information, so that the resource allocation of the target application according to the resource configuration value is realized, the accuracy of the resource allocation is improved to a certain extent, and the utilization rate of the resource is further improved.

Description

Application resource allocation method and device, computer equipment and storage medium
Technical Field
The present invention relates to the field of financial science and technology, and in particular, to a method, an apparatus, a computer device, and a storage medium for allocating resources of an application.
Background
The application requires certain resources (e.g., central processing unit (Central Processing Unit, CPU) resources, memory resources, etc.) during running, and the data center can allocate corresponding resources for different applications.
At present, the data center mainly allocates resources for applications in the following two ways: firstly, the application directly submits an application to a data center according to typical configuration, and the data center distributes resources corresponding to the application after receiving the application; second, the data center directly allocates resources of typical allocation specifications and related usage scenarios to the application.
However, when the data center allocates resources, in order to ensure that the service runs stably under a short time and high load, redundant resources are often allocated to the application, and the redundant resources are in idle states in most of the time, that is, the existing resource allocation mode has the problem of low resource utilization rate.
Disclosure of Invention
In view of the foregoing, it is desirable to provide a resource allocation method, apparatus, computer device, and storage medium for an application capable of improving resource utilization.
In a first aspect, the present application provides a method for allocating resources of an application, including:
acquiring historical resource information and predicted resource occupation information of a target application;
determining a resource configuration value corresponding to the target application according to the grade, the historical resource information and the predicted resource occupation information of the target application;
and carrying out resource allocation on the target application according to the resource allocation value.
In one embodiment, determining the resource configuration value corresponding to the target application according to the level of the target application, the historical resource data and the predicted resource data includes:
determining historical resource occupation information according to the grade of the target application and the historical resource information;
and determining a resource configuration value corresponding to the target application according to the historical resource occupation information and the predicted resource occupation information.
In one embodiment, determining the resource configuration value corresponding to the target application according to the historical resource occupancy information and the predicted resource occupancy information includes:
performing first multiple processing on the historical resource occupation information to obtain first information;
performing second multiple processing on the predicted resource occupation information to obtain second information;
and adding the value of the first information and the value of the second information to obtain a resource configuration value.
In one embodiment, determining the historical resource occupation information according to the level of the target application and the historical resource information includes:
acquiring target information corresponding to the target score value in the historical resource information according to the target score value corresponding to the grade of the target application;
and performing third time processing on the target information to obtain historical resource occupation information.
In one embodiment, the method further comprises:
determining whether the difference value between the resource allocation value and a preset allocation threshold meets the difference value requirement;
if yes, executing the step of carrying out resource allocation on the target application according to the resource allocation value;
if not, taking the resource allocation value as a new preset allocation threshold value, and executing the step of allocating the resource to the target application according to the resource allocation value.
In one embodiment, the method for obtaining predicted resource occupation information includes:
and inputting the historical resource information into the lifting tree model to predict the resource occupation condition, so as to obtain predicted resource occupation information.
In a second aspect, the present application further provides a resource allocation apparatus for an application, including:
the acquisition module is used for acquiring historical resource information and predicted resource occupation information of the target application;
The determining module is used for determining a resource configuration value corresponding to the target application according to the grade, the historical resource information and the predicted resource occupation information of the target application;
and the allocation module is used for allocating resources to the target application according to the resource allocation value.
In a third aspect, the present application also provides a computer device comprising a memory and a processor, the memory storing a computer program, the processor implementing the following steps when executing the computer program:
acquiring historical resource information and predicted resource occupation information of a target application;
determining a resource configuration value corresponding to the target application according to the grade, the historical resource information and the predicted resource occupation information of the target application;
and carrying out resource allocation on the target application according to the resource allocation value.
In a fourth aspect, the present application also provides a computer readable storage medium having stored thereon a computer program which when executed by a processor performs the steps of:
acquiring historical resource information and predicted resource occupation information of a target application;
determining a resource configuration value corresponding to the target application according to the grade, the historical resource information and the predicted resource occupation information of the target application;
And carrying out resource allocation on the target application according to the resource allocation value.
In a fifth aspect, the present application also provides a computer program product comprising a computer program which, when executed by a processor, performs the steps of:
acquiring historical resource information and predicted resource occupation information of a target application;
determining a resource configuration value corresponding to the target application according to the grade, the historical resource information and the predicted resource occupation information of the target application;
and carrying out resource allocation on the target application according to the resource allocation value.
The resource allocation method, the device, the computer equipment and the storage medium of the application. The method comprises the following steps: firstly, acquiring historical resource information and predicted resource occupation information of a target application; then determining a resource configuration value corresponding to the target application according to the grade of the target application, the historical resource information and the predicted resource occupation information; and then, carrying out resource allocation on the target application according to the resource allocation value. Compared with the existing mode of directly configuring resources according to typical specifications, the method considers the grade of the target application, the historical resource information of the target application and the predicted resource occupation information, and obtains the corresponding resource configuration value based on the grade of the target application, the historical resource information of the target application and the predicted resource occupation information, so that the resource allocation of the target application according to the resource configuration value is realized, the accuracy of the resource allocation is improved to a certain extent, and the utilization rate of the resource is further improved.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the related art, the drawings that are required to be used in the embodiments or the related technical descriptions will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and other drawings may be obtained according to the drawings without inventive effort for a person having ordinary skill in the art.
FIG. 1 is an application environment diagram of a resource allocation method applied in one embodiment;
FIG. 2 is a flow diagram of a resource allocation method applied in one embodiment;
FIG. 3 is a flow chart of a resource allocation method applied in another embodiment;
FIG. 4 is a flow chart of a resource allocation method applied in another embodiment;
FIG. 5 is a flow chart of a resource allocation method applied in another embodiment;
FIG. 6 is a flow chart of a resource allocation method applied in another embodiment;
FIG. 7 is a flow chart of a resource allocation method applied in another embodiment;
fig. 8 is a block diagram of a resource allocation apparatus applied in one embodiment.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more apparent, the present application will be further described in detail with reference to the accompanying drawings and examples. It should be understood that the specific embodiments described herein are for purposes of illustration only and are not intended to limit the present application.
Unless defined otherwise, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs; the terminology used herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the application; the terms "comprising" and "having" and any variations thereof in the description and claims of the present application and in the description of the figures above are intended to cover non-exclusive inclusions.
In the description of the embodiments of the present application, the technical terms "first," "second," etc. are used merely to distinguish between different objects and are not to be construed as indicating or implying a relative importance or implicitly indicating the number of technical features indicated, a particular order or a primary or secondary relationship. In the description of the embodiments of the present application, the meaning of "plurality" is two or more unless explicitly defined otherwise.
Reference herein to "an embodiment" means that a particular feature, structure, or characteristic described in connection with the embodiment may be included in at least one embodiment of the present application. The appearances of such phrases in various places in the specification are not necessarily all referring to the same embodiment, nor are separate or alternative embodiments mutually exclusive of other embodiments. Those of skill in the art will explicitly and implicitly appreciate that the embodiments described herein may be combined with other embodiments.
The application requires certain resources (e.g., central processing unit (Central Processing Unit, CPU) resources, memory resources, etc.) during running, and the data center can allocate corresponding resources for different applications. At present, the data center mainly allocates resources for applications in the following two ways: firstly, the application directly submits an application to a data center according to typical configuration, and the data center distributes resources corresponding to the application after receiving the application; second, the data center directly allocates resources of typical allocation specifications and related usage scenarios to the application. However, when the data center allocates resources, in order to ensure that the service runs stably under a short time and high load, redundant resources are often allocated to the application, and the redundant resources are in idle states in most of the time, that is, the existing resource allocation mode has the problem of low resource utilization rate. This patent aims to solve this problem.
After the background technology of the resource allocation method of the application provided by the embodiment of the present application is introduced, an implementation environment related to the resource allocation method of the application provided by the embodiment of the present application will be briefly described below. The resource allocation method of the application provided by the embodiment of the application can be applied to the computer equipment shown in the figure 1. The computer device includes a processor, a memory, an input/output interface, a communication interface, a display unit, and an input means. The processor, the memory and the input/output interface are connected through a system bus, and the communication interface, the display unit and the input device are connected to the system bus through the input/output interface. Wherein the processor of the computer device is configured to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage media. The input/output interface of the computer device is used to exchange information between the processor and the external device. The communication interface of the computer device is used for carrying out wired or wireless communication with an external terminal, and the wireless mode can be realized through WIFI, a mobile cellular network, NFC (near field communication) or other technologies. The computer program is executed by a processor to implement a method of determining signal strength. The display unit of the computer device is used for forming a visual picture, and can be a display screen, a projection device or a virtual reality imaging device. The display screen can be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer equipment can be a touch layer covered on the display screen, can also be a key, a track ball or a touch pad arranged on the shell of the computer equipment, and can also be an external keyboard, a touch pad or a mouse and the like.
It will be appreciated by those skilled in the art that the structure shown in fig. 1 is merely a block diagram of a portion of the structure associated with the present application and does not constitute a limitation of the computer device to which the present application is applied, and that a particular terminal may include more or less components than those shown, or may combine some components, or have a different arrangement of components.
After the application scenario of the application resource allocation method provided by the embodiment of the present application is described above, the application resource allocation method described in the present application is described in the following.
In one embodiment, as shown in fig. 2, there is provided a resource allocation method of an application, which is illustrated by way of example as being applied to the computer device in fig. 1, and includes the following steps:
s201, historical resource information and predicted resource occupation information of a target application are obtained.
The target application may be any one of common applications, for example, chatting software, payment software, financial software, and the like; the historical resource information comprises information such as CPU usage amount and memory usage amount; the predicted resource occupation information comprises resource occupation information of the target application predicted according to a certain prediction rule based on historical resource information of the target application.
In the embodiment of the application, when the resources of the data center are required to be reasonably allocated to the target application, the historical resource information of the target application can be acquired first, and the predicted resource occupation information in the preset time period can be determined according to the historical resource information. Alternatively, the historical resource information of the target application may be queried by the resource monitoring system, for example, by promethaus (promiscus) for CPU usage and memory usage for the past month. Optionally, inputting the historical resource information of the target application into a trained prediction model with a resource prediction function for prediction to obtain predicted resource occupation information; for another example, the user predicts predicted resource occupancy information based on trends in historical resource information for the target application.
S202, determining a resource configuration value corresponding to the target application according to the grade of the target application, the historical resource information and the predicted resource occupation information.
The application level refers to the level of each application obtained by dividing the importance level of each application, for example, the level of chat software is level a, which indicates that the importance level of chat software is high, for example, the level of entertainment software is level C, which indicates that the importance level of entertainment software is low, for example, the level of payment software is level B, which indicates that the importance level of payment software is high.
The resource configuration value is a reference value when the data center configures resources for the target application.
In this embodiment of the present application, after the historical resource information and the predicted resource occupation information of the target application are obtained, the historical resource information and the predicted resource occupation information may be respectively processed by performing an operation based on the level of the target application, and then the result of the operation is integrated and operated to obtain the resource configuration value corresponding to the target application.
S203, performing resource allocation on the target application according to the resource allocation value.
In this embodiment of the present application, after the resource configuration value corresponding to the target application is obtained, the resource corresponding to the resource configuration value may be allocated to the target application according to the resource configuration value corresponding to the target application.
The application resource allocation method provided by the embodiment of the application firstly acquires historical resource information and predicted resource occupation information of a target application; then determining a resource configuration value corresponding to the target application according to the grade of the target application, the historical resource information and the predicted resource occupation information; and then, carrying out resource allocation on the target application according to the resource allocation value. Compared with the existing mode of directly configuring resources according to typical specifications, the method considers the grade of the target application, the historical resource information of the target application and the predicted resource occupation information, and obtains the corresponding resource configuration value based on the grade of the target application, the historical resource information of the target application and the predicted resource occupation information, so that the resource allocation of the target application according to the resource configuration value is realized, the accuracy of the resource allocation is improved to a certain extent, and the utilization rate of the resource is further improved.
In one embodiment, a process of obtaining a resource configuration value corresponding to a target application may be described based on the embodiment shown in fig. 2, as shown in fig. 3, S202 "determine a resource configuration value corresponding to a target application according to a level of the target application, historical resource information, and predicted resource occupancy information", where the process includes:
s301, determining historical resource occupation information according to the grade of the target application and the historical resource information.
In this embodiment of the present application, after the level of the target application and the historical resource information are obtained, the historical resource information may be subjected to data processing based on the obtained level of the target application, so as to obtain historical resource occupation information.
Optionally, a method for obtaining historical resource occupation information is provided below, that is, S301 "determining historical resource occupation information according to the level of the target application and the historical resource information", as shown in fig. 4, includes:
s3010, obtaining target information corresponding to the target score value in the historical resource information according to the target score value corresponding to the grade of the target application.
The target ranking value refers to a value (0-100) determined in advance according to the grade of the target application, for example, the grade of the target application is grade a, then the corresponding target ranking value is a 99 ranking value, for example, the grade of the target application is grade B, then the corresponding target ranking value is a 95 ranking value. It should be noted that, in the embodiment of the present application, the level of the application and the size of the corresponding quantile value are not limited, and the user may determine the quantile value of the application according to the actual resource usage situation of the user.
The target information corresponding to the target quantile value is the target information corresponding to the target quantile value, which is obtained by sorting the historical resource information according to the sequence of the resource usage from big to small (or from small to big), then removing the highest resource usage in the historical resource information, and determining the highest resource usage after removal as the target information corresponding to the target quantile value.
In this embodiment of the present application, after the level of the target application is obtained, a target score corresponding to the preset level of the target application may be obtained, and then target information corresponding to the target score may be obtained from a large amount of historical resource information. For example, the target value corresponding to the class a of the target application is a 99-point value, and then the target information corresponding to the 99-point value may be obtained from the historical resource information.
S3011, performing third-time processing on the target information to obtain historical resource occupation information.
The third multiplier processing refers to multiplying a value corresponding to the target information by a corresponding third multiplier, and it should be noted that the third multiplier may be determined according to a difference between the determined resource configuration value and a preset allocation threshold, that is, if the difference between the determined resource configuration value and the preset allocation threshold meets a preset condition, the initially set third multiplier is not changed, and if the difference between the determined resource configuration value and the preset allocation threshold does not meet the preset condition, the initially set third multiplier needs to be adjusted correspondingly.
In this embodiment of the present application, after the target information is obtained, the value corresponding to the target information may be multiplied by the corresponding third multiple to obtain the value corresponding to the historical resource occupation information.
S302, determining a resource configuration value corresponding to the target application according to the historical resource occupation information and the predicted resource occupation information.
In this embodiment of the present application, after the historical resource occupancy information and the predicted resource occupancy information are obtained, an addition operation may be performed on the historical resource occupancy information and the predicted resource occupancy information to obtain an addition result, and the addition result is determined as a resource configuration value corresponding to the target application. When the target application applies for the resource again, the resource configuration value corresponding to the target application may be used as a reference to determine the resource value of the target application to be applied next time.
Optionally, the following provides a method for obtaining a resource configuration value corresponding to the target application, that is, S302 "determining, according to the historical resource occupancy information and the predicted resource occupancy information, the resource configuration value corresponding to the target application", as shown in fig. 5, includes:
s3020, performing first multiple processing on the historical resource occupation information to obtain first information.
The first multiple processing refers to multiplying a value corresponding to the target information by a corresponding first multiple, and it should be noted that the first multiple may be determined according to a difference between the determined resource configuration value and a preset allocation threshold, that is, if the difference between the determined resource configuration value and the preset allocation threshold meets a preset condition, the first multiple of the initial setting is not changed, and if the difference between the determined resource configuration value and the preset allocation threshold does not meet the preset condition, the first multiple of the initial setting needs to be adjusted correspondingly.
In this embodiment of the present application, after the historical resource occupation information is obtained, a value corresponding to the historical resource occupation information may be multiplied by a corresponding first multiple to obtain a value corresponding to the first information.
S3021, performing second multiple processing on the predicted resource occupation information to obtain second information.
The second multiple processing refers to multiplying a value corresponding to the target information by a corresponding second multiple, and it should be noted that the second multiple may be determined according to a difference between the determined resource configuration value and a preset allocation threshold, that is, if the difference between the determined resource configuration value and the preset allocation threshold meets a preset condition, the second multiple of the initial setting is not changed, and if the difference between the determined resource configuration value and the preset allocation threshold does not meet the preset condition, the second multiple of the initial setting needs to be adjusted correspondingly.
In this embodiment of the present application, after the predicted resource occupancy information is obtained, a value corresponding to the predicted resource occupancy information may be multiplied by a corresponding second multiple to obtain a value corresponding to the second information.
And S3022, adding the value of the first information and the value of the second information to obtain a resource allocation value.
In this embodiment of the present application, after the value corresponding to the first information and the value corresponding to the second information are obtained, the value corresponding to the first information and then the value corresponding to the second information may be added to obtain the resource configuration value.
In the embodiment of the application, the corresponding resource allocation value is obtained based on the grade of the target application, the historical resource information of the target application and the predicted resource occupation information, so that the target application is allocated according to the resource allocation value, the accuracy of resource allocation is improved to a certain extent, and the utilization rate of resources is improved.
In one embodiment, based on the embodiment shown in fig. 2, as shown in fig. 6, the method further includes:
s204, determining whether the difference between the resource allocation value and the preset allocation threshold meets the difference requirement, if so, returning to execute the S203, and if not, executing the S205.
The preset allocation threshold refers to the resource allocation amount in a preset time period determined according to a preset configuration specification. The difference requirement means that the difference between the resource allocation value and the preset allocation threshold is smaller than the preset difference.
In this embodiment of the present application, after the above-mentioned resource allocation value is obtained, the preset allocation threshold value in the preset time period may be continuously obtained, then a difference value between the resource allocation value and the preset allocation threshold value in the preset time period is determined, then it is determined whether the difference value between the resource allocation value and the preset allocation threshold value in the preset time period is smaller than the preset difference value, and in the case that it is determined that the difference value between the resource allocation value and the preset allocation threshold value in the preset time period is smaller than the preset difference value, resource allocation is performed on the target application according to the resource allocation value.
S205, taking the resource allocation value as a new preset allocation threshold value, and returning to execute S203.
In the embodiment of the application, under the condition that the difference value between the resource allocation value and the preset allocation threshold value in the preset time period is not smaller than the preset difference value, the resource allocation value is used as a new preset allocation threshold value, and the resource allocation is carried out on the target application according to the resource allocation value.
In the embodiment of the application, whether the difference value between the resource allocation value and the preset allocation threshold meets the difference value requirement or not is determined, and the accuracy of the preset allocation threshold is verified, so that the resource allocation is carried out on the target application according to the resource allocation value, the accuracy of the resource allocation is improved to a certain extent, and the utilization rate of the resource is further improved.
In one embodiment, a process of obtaining predicted resource occupancy information may be described based on the embodiment shown in fig. 2, where the obtaining predicted resource occupancy information includes:
and inputting the historical resource information into a lifting tree model to predict the resource occupation condition, and obtaining the predicted resource occupation information.
The lifting tree model can be obtained by training according to historical resource information of the target application in advance. For example, the historical resource information of the target application is input into an initial lifting tree model, the initial lifting tree model is trained, and the lifting tree model with the prediction function for the resource occupation information of the target application after training is obtained.
In this embodiment of the present application, after the obtained historical resource information of the target application is obtained, the obtained historical resource information of the target application may be input into the lifting number model to predict the resource occupation condition, and the resource occupation information may be predicted by de.
According to the method for acquiring the predicted resource occupation information, the historical resource information is obtained by prediction based on the lifting tree model, and a data basis is provided for determining the resource configuration value corresponding to the target application for the subsequent predicted resource occupation information based on the target application.
In one embodiment, as shown in fig. 7, there is further provided a resource allocation method of a complete application, including:
s10, acquiring historical resource information of a target application;
s11, inputting historical resource information into a lifting tree model to predict the resource occupation condition, and obtaining predicted resource occupation information;
s12, acquiring target information corresponding to the target score value in the historical resource information according to the target score value corresponding to the grade of the target application;
s13, performing third-time processing on the target information to obtain historical resource occupation information;
s14, performing first multiple processing on the historical resource occupation information to obtain first information;
s15, carrying out second multiple processing on the predicted resource occupation information to obtain second information;
s16, adding the value of the first information and the value of the second information to obtain a resource configuration value;
s17, determining whether a difference value between the resource allocation value and a preset allocation threshold meets a difference value requirement, if so, executing S19, and if not, executing S18;
S18, taking the resource allocation value as a new preset allocation threshold value, and returning to the step S19;
and S19, performing resource allocation on the target application according to the resource allocation value.
Compared with the existing mode of directly configuring resources according to typical specifications, the method considers the grade of the target application, the historical resource information of the target application and the predicted resource occupation information, and obtains the corresponding resource configuration value based on the grade of the target application, the historical resource information of the target application and the predicted resource occupation information, so that the resource allocation of the target application according to the resource configuration value is realized, the accuracy of the resource allocation is improved to a certain extent, and the utilization rate of the resource is further improved.
It should be understood that, although the steps in the flowcharts related to the embodiments described above are sequentially shown as indicated by arrows, these steps are not necessarily sequentially performed in the order indicated by the arrows. The steps are not strictly limited to the order of execution unless explicitly recited herein, and the steps may be executed in other orders. Moreover, at least some of the steps in the flowcharts described in the above embodiments may include a plurality of steps or a plurality of stages, which are not necessarily performed at the same time, but may be performed at different times, and the order of the steps or stages is not necessarily performed sequentially, but may be performed alternately or alternately with at least some of the other steps or stages.
Based on the same inventive concept, the embodiment of the application also provides a resource allocation device for realizing the application of the resource allocation method of the application. The implementation of the solution provided by the device is similar to the implementation described in the above method, so the specific limitation in the embodiments of the resource allocation device for one or more applications provided below may refer to the limitation of the resource allocation method for an application hereinabove, and will not be described herein.
In an exemplary embodiment, as shown in fig. 8, there is provided a resource allocation apparatus of an application, including: an acquisition module 10, a determination module 11 and an allocation module 12, wherein:
and the acquisition module 10 is used for acquiring the historical resource information and the predicted resource occupation information of the target application.
The determining module 11 is configured to determine a resource configuration value corresponding to the target application according to the level of the target application, the historical resource information and the predicted resource occupation information.
And the allocation module 12 is used for allocating resources to the target application according to the resource configuration value.
In an exemplary embodiment, the determining module 11 includes a first determining unit and a second determining unit, where:
The first determining unit is specifically used for determining historical resource occupation information according to the grade of the target application and the historical resource information;
the second determining unit is specifically configured to determine a resource configuration value corresponding to the target application according to the historical resource occupation information and the predicted resource occupation information.
In an exemplary embodiment, the second determining unit is specifically configured to perform a first multiple process on the historical resource occupation information to obtain first information; performing second multiple processing on the predicted resource occupation information to obtain second information; and adding the value of the first information and the value of the second information to obtain a resource configuration value.
In an exemplary embodiment, the first determining unit is specifically configured to obtain, according to a target score corresponding to a level of the target application, target information corresponding to the target score in the historical resource information; and performing third time processing on the target information to obtain historical resource occupation information.
In an exemplary embodiment, the above apparatus further includes: the second determining module is used for determining whether the difference value between the resource allocation value and the preset allocation threshold value meets the difference value requirement or not; if yes, carrying out resource allocation on the target application according to the resource allocation value; if not, taking the resource allocation value as a new preset allocation threshold value, and allocating the resources to the target application according to the resource allocation value.
In an exemplary embodiment, the method for predicting resource occupation information includes: and inputting the historical resource information into the lifting tree model to predict the resource occupation condition, so as to obtain predicted resource occupation information.
The respective modules in the resource allocation device of the above application may be implemented in whole or in part by software, hardware, and a combination thereof. The above modules may be embedded in hardware or may be independent of a processor in the computer device, or may be stored in software in a memory in the computer device, so that the processor may call and execute operations corresponding to the above modules.
In one exemplary embodiment, a computer device is provided, which may be a terminal, and an internal structure diagram thereof may be as shown in fig. 1. The computer device includes a processor, a memory, an input/output interface, a communication interface, a display unit, and an input means. The processor, the memory and the input/output interface are connected through a system bus, and the communication interface, the display unit and the input device are connected to the system bus through the input/output interface. Wherein the processor of the computer device is configured to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage media. The input/output interface of the computer device is used to exchange information between the processor and the external device. The communication interface of the computer device is used for carrying out wired or wireless communication with an external terminal, and the wireless mode can be realized through WIFI, a mobile cellular network, NFC (near field communication) or other technologies. The computer program, when executed by a processor, implements a resource allocation method for an application. The display unit of the computer device is used for forming a visual picture, and can be a display screen, a projection device or a virtual reality imaging device. The display screen can be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer equipment can be a touch layer covered on the display screen, can also be a key, a track ball or a touch pad arranged on the shell of the computer equipment, and can also be an external keyboard, a touch pad or a mouse and the like.
It will be appreciated by those skilled in the art that the structure shown in fig. 1 is merely a block diagram of some of the structures associated with the present application and is not limiting of the computer device to which the present application may be applied, and that a particular computer device may include more or fewer components than shown, or may combine certain components, or have a different arrangement of components.
In one exemplary embodiment, a computer device is provided comprising a memory and a processor, the memory having stored therein a computer program, the processor when executing the computer program performing the steps of:
acquiring historical resource information and predicted resource occupation information of a target application;
determining a resource configuration value corresponding to the target application according to the grade, the historical resource information and the predicted resource occupation information of the target application;
and carrying out resource allocation on the target application according to the resource allocation value.
In one embodiment, the processor when executing the computer program further performs the steps of:
determining historical resource occupation information according to the grade of the target application and the historical resource information;
and determining a resource configuration value corresponding to the target application according to the historical resource occupation information and the predicted resource occupation information.
In one embodiment, the processor when executing the computer program further performs the steps of:
performing first multiple processing on the historical resource occupation information to obtain first information;
performing second multiple processing on the predicted resource occupation information to obtain second information;
and adding the value of the first information and the value of the second information to obtain a resource configuration value.
In one embodiment, the processor when executing the computer program further performs the steps of:
acquiring target information corresponding to the target score value in the historical resource information according to the target score value corresponding to the grade of the target application;
and performing third time processing on the target information to obtain historical resource occupation information.
In one embodiment, the processor when executing the computer program further performs the steps of:
determining whether the difference value between the resource allocation value and a preset allocation threshold meets the difference value requirement;
if yes, executing the step of carrying out resource allocation on the target application according to the resource allocation value;
if not, taking the resource allocation value as a new preset allocation threshold value, and executing the step of allocating the resource to the target application according to the resource allocation value.
In one embodiment, the processor when executing the computer program further performs the steps of:
And inputting the historical resource information into the lifting tree model to predict the resource occupation condition, so as to obtain predicted resource occupation information.
In one embodiment, a computer readable storage medium is provided having a computer program stored thereon, which when executed by a processor, performs the steps of:
acquiring historical resource information and predicted resource occupation information of a target application;
determining a resource configuration value corresponding to the target application according to the grade, the historical resource information and the predicted resource occupation information of the target application;
and carrying out resource allocation on the target application according to the resource allocation value.
In one embodiment, the computer program when executed by the processor further performs the steps of:
determining historical resource occupation information according to the grade of the target application and the historical resource information;
and determining a resource configuration value corresponding to the target application according to the historical resource occupation information and the predicted resource occupation information.
In one embodiment, the computer program when executed by the processor further performs the steps of:
performing first multiple processing on the historical resource occupation information to obtain first information;
performing second multiple processing on the predicted resource occupation information to obtain second information;
And adding the value of the first information and the value of the second information to obtain a resource configuration value.
In one embodiment, the computer program when executed by the processor further performs the steps of:
acquiring target information corresponding to the target score value in the historical resource information according to the target score value corresponding to the grade of the target application;
and performing third time processing on the target information to obtain historical resource occupation information.
In one embodiment, the computer program when executed by the processor further performs the steps of:
determining whether the difference value between the resource allocation value and a preset allocation threshold meets the difference value requirement;
if yes, executing the step of carrying out resource allocation on the target application according to the resource allocation value;
if not, taking the resource allocation value as a new preset allocation threshold value, and executing the step of allocating the resource to the target application according to the resource allocation value.
In one embodiment, the computer program when executed by the processor further performs the steps of:
and inputting the historical resource information into the lifting tree model to predict the resource occupation condition, so as to obtain predicted resource occupation information.
In one embodiment, a computer program product is provided comprising a computer program which, when executed by a processor, performs the steps of:
Acquiring historical resource information and predicted resource occupation information of a target application;
determining a resource configuration value corresponding to the target application according to the grade, the historical resource information and the predicted resource occupation information of the target application;
and carrying out resource allocation on the target application according to the resource allocation value.
In one embodiment, the computer program when executed by the processor further performs the steps of:
determining historical resource occupation information according to the grade of the target application and the historical resource information;
and determining a resource configuration value corresponding to the target application according to the historical resource occupation information and the predicted resource occupation information.
In one embodiment, the computer program when executed by the processor further performs the steps of:
performing first multiple processing on the historical resource occupation information to obtain first information;
performing second multiple processing on the predicted resource occupation information to obtain second information;
and adding the value of the first information and the value of the second information to obtain a resource configuration value.
In one embodiment, the computer program when executed by the processor further performs the steps of:
acquiring target information corresponding to the target score value in the historical resource information according to the target score value corresponding to the grade of the target application;
And performing third time processing on the target information to obtain historical resource occupation information.
In one embodiment, the computer program when executed by the processor further performs the steps of:
determining whether the difference value between the resource allocation value and a preset allocation threshold meets the difference value requirement;
if yes, executing the step of carrying out resource allocation on the target application according to the resource allocation value;
if not, taking the resource allocation value as a new preset allocation threshold value, and executing the step of allocating the resource to the target application according to the resource allocation value.
In one embodiment, the computer program when executed by the processor further performs the steps of:
and inputting the historical resource information into the lifting tree model to predict the resource occupation condition, so as to obtain predicted resource occupation information.
It should be noted that, the user information (including, but not limited to, user equipment information, user personal information, etc.) and the data (including, but not limited to, data for analysis, stored data, presented data, etc.) referred to in the present application are information and data authorized by the user or sufficiently authorized by each party, and the collection, use, and processing of the related data are required to meet the related regulations.
Those skilled in the art will appreciate that implementing all or part of the above described methods may be accomplished by way of a computer program stored on a non-transitory computer readable storage medium, which when executed, may comprise the steps of the embodiments of the methods described above. Any reference to memory, database, or other medium used in the various embodiments provided herein may include at least one of non-volatile and volatile memory. The nonvolatile Memory may include Read-Only Memory (ROM), magnetic tape, floppy disk, flash Memory, optical Memory, high density embedded nonvolatile Memory, resistive random access Memory (ReRAM), magnetic random access Memory (Magnetoresistive Random Access Memory, MRAM), ferroelectric Memory (Ferroelectric Random Access Memory, FRAM), phase change Memory (Phase Change Memory, PCM), graphene Memory, and the like. Volatile memory can include random access memory (Random Access Memory, RAM) or external cache memory, and the like. By way of illustration, and not limitation, RAM can be in the form of a variety of forms, such as static random access memory (Static Random Access Memory, SRAM) or dynamic random access memory (Dynamic Random Access Memory, DRAM), and the like. The databases referred to in the various embodiments provided herein may include at least one of relational databases and non-relational databases. The non-relational database may include, but is not limited to, a blockchain-based distributed database, and the like. The processors referred to in the embodiments provided herein may be general purpose processors, central processing units, graphics processors, digital signal processors, programmable logic units, quantum computing-based data processing logic units, etc., without being limited thereto.
The technical features of the above embodiments may be arbitrarily combined, and all possible combinations of the technical features in the above embodiments are not described for brevity of description, however, as long as there is no contradiction between the combinations of the technical features, they should be considered as the scope of the description.
The above examples only represent a few embodiments of the present application, which are described in more detail and are not to be construed as limiting the scope of the present application. It should be noted that it would be apparent to those skilled in the art that various modifications and improvements could be made without departing from the spirit of the present application, which would be within the scope of the present application. Accordingly, the scope of protection of the present application shall be subject to the appended claims.

Claims (10)

1. A method for resource allocation for an application, the method comprising:
acquiring historical resource information and predicted resource occupation information of a target application;
determining a resource configuration value corresponding to the target application according to the grade of the target application, the historical resource information and the predicted resource occupation information;
and carrying out resource allocation on the target application according to the resource allocation value.
2. The method of claim 1, wherein the determining the resource configuration value corresponding to the target application according to the level of the target application, the historical resource data, and the predicted resource data comprises:
determining historical resource occupation information according to the grade of the target application and the historical resource information;
and determining a resource configuration value corresponding to the target application according to the historical resource occupation information and the predicted resource occupation information.
3. The method according to claim 2, wherein determining the resource configuration value corresponding to the target application according to the historical resource occupancy information and the predicted resource occupancy information comprises:
performing first multiple processing on the historical resource occupation information to obtain first information;
performing second multiple processing on the predicted resource occupation information to obtain second information;
and adding the value of the first information and the value of the second information to obtain the resource configuration value.
4. The method of claim 2, wherein determining historical resource occupancy information based on the level of the target application and the historical resource information comprises:
Acquiring target information corresponding to the target score value in the historical resource information according to the target score value corresponding to the grade of the target application;
and performing third time processing on the target information to obtain the historical resource occupation information.
5. The method according to claim 1, wherein the method further comprises:
determining whether the difference value between the resource allocation value and a preset allocation threshold meets the difference value requirement;
if yes, executing the step of carrying out resource allocation on the target application according to the resource allocation value;
and if the resource allocation value does not accord with the resource allocation value, taking the resource allocation value as a new preset allocation threshold value, and executing the step of allocating the resource to the target application according to the resource allocation value.
6. The method of claim 1, wherein the method of obtaining the predicted resource occupancy information comprises:
and inputting the historical resource information into a lifting tree model to predict the resource occupation condition, and obtaining the predicted resource occupation information.
7. An apparatus for resource allocation for an application, the apparatus comprising:
the acquisition module is used for acquiring historical resource information and predicted resource occupation information of the target application;
The determining module is used for determining a resource configuration value corresponding to the target application according to the grade of the target application, the historical resource information and the predicted resource occupation information;
and the allocation module is used for allocating resources to the target application according to the resource allocation value.
8. A computer device comprising a memory and a processor, the memory storing a computer program, characterized in that the processor implements the steps of the method of any of claims 1 to 6 when the computer program is executed.
9. A computer readable storage medium, on which a computer program is stored, characterized in that the computer program, when being executed by a processor, implements the steps of the method of any of claims 1 to 6.
10. A computer program product comprising a computer program, characterized in that the computer program, when being executed by a processor, implements the steps of the method of any of claims 1 to 6.
CN202410102872.2A 2024-01-24 2024-01-24 Application resource allocation method and device, computer equipment and storage medium Pending CN117851071A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202410102872.2A CN117851071A (en) 2024-01-24 2024-01-24 Application resource allocation method and device, computer equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202410102872.2A CN117851071A (en) 2024-01-24 2024-01-24 Application resource allocation method and device, computer equipment and storage medium

Publications (1)

Publication Number Publication Date
CN117851071A true CN117851071A (en) 2024-04-09

Family

ID=90547740

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202410102872.2A Pending CN117851071A (en) 2024-01-24 2024-01-24 Application resource allocation method and device, computer equipment and storage medium

Country Status (1)

Country Link
CN (1) CN117851071A (en)

Similar Documents

Publication Publication Date Title
US20200293360A1 (en) Techniques to manage virtual classes for statistical tests
CN106104484A (en) The resource management of profile is used based on the resource that the XOR because of equipment is different because of user
WO2017166643A1 (en) Method and device for quantifying task resources
CN109727070B (en) Method and device for determining potential active users
CN105630683A (en) Cloud testing architecture
CN118331513B (en) Data intelligent dynamic scheduling method and device and computer equipment
CN112764938A (en) Cloud server resource management method and device, computer equipment and storage medium
CN113672375A (en) Resource allocation prediction method, device, equipment and storage medium
CN117035980A (en) Resource borrowing evaluation method, device, computer equipment and storage medium
CN116737373A (en) Load balancing method, device, computer equipment and storage medium
CN117851071A (en) Application resource allocation method and device, computer equipment and storage medium
CN111858542B (en) Data processing method, device, equipment and computer readable storage medium
CN115617515A (en) Memory allocation method and device for intelligent Internet of things operating system and storage medium
CN114254958A (en) Energy and carbon data report processing device and storage medium
CN117453759B (en) Service data processing method, device, computer equipment and storage medium
CN116775247A (en) Task allocation method, device, computer equipment and storage medium
CN112600756B (en) Service data processing method and device
CN117314036A (en) Work order distribution method, apparatus, device, storage medium and program product
CN117389715A (en) Resource allocation method, resource allocation device, computer device, and storage medium
CN117149404A (en) Method, device, computer equipment and storage medium for allocating detection task resources
CN117311970A (en) Processing method and device for application memory, computer equipment and storage medium
CN113821349A (en) Load balancing method and device
CN116204296A (en) Algorithm execution method, device, computer equipment and storage medium of monitoring system
CN116860435A (en) Nuclear function priority determining method, device, computer equipment and storage medium
CN117632470A (en) Service processing method, device, equipment, storage medium and program product

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