Migration deployment method and device, storage medium and electronic equipment
By obtaining the operating resource information of the application and making judgments based on preset judgment rules, the automated identification of cloud instance migration to cloud functions and batch migration deployment are realized, and the problems of low migration efficiency and waste of resource costs in the existing technology are solved, which improves migration efficiency and saves costs.
Patent Information
- Application Number
- CN202510167600.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-02-14
- Publication Date
- 2025-05-23
AI Technical Summary
The prior art is difficult to efficiently migrate cloud instances to cloud functions, especially in the case of huge applications, resulting in waste of resource costs and inefficient migration.
By obtaining the operating resource information of the application, we can judge whether the migration object conditions are met based on the preset judgment rules. If so, batch migration deployment will be carried out, and the cloud functions will be used to save resource costs.
It realizes automated identification and batch migration deployment of cloud instance migration to cloud functions, improves migration efficiency, saves resource costs, and reduces labor operation and maintenance costs.
Smart Images

Figure CN120029735A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of cloud computing, and more specifically, to a migration deployment method, device, storage medium and electronic device. Background Art
[0002] With the popularization of cloud computing technology, more and more enterprises will choose to deploy applications on cloud platforms. After the application is deployed on the cloud platform, it is generally deployed on a cloud instance, and the program is executed based on the central processing unit (CPU), memory, disk and other resources of the cloud instance to provide services.
[0003] However, some applications, such as computing or periodic applications, are more suitable for deployment on cloud functions. Cloud functions are cloud products produced by cloud platforms based on the serverless concept. Compared with cloud instances, the biggest advantage of cloud functions is that they can be charged by volume. Cloud instances will incur normal fees even when they are idle, while cloud functions will only be charged when they are executed. Therefore, computing or periodic applications are more suitable for deployment on cloud functions, which can save resource costs when they are idle. Therefore, it is necessary to migrate cloud instances to cloud functions.
[0004] The migration and deployment process of existing technologies is also performed manually by technicians, who generally manually identify applications that can be deployed to cloud functions, then manually configure cloud function resources and environments, and then submit code packages to cloud functions, one by one. As the number of applications continues to increase, reaching hundreds or even thousands, technicians do not have the ability to batch identify whether they can be deployed to cloud functions, and it is difficult to batch migrate cloud instances to cloud functions.
[0005] Therefore, how to improve the efficiency of migrating cloud instances to cloud functions is an urgent problem to be solved in this application. Summary of the invention
[0006] In view of this, the present application discloses a migration deployment method, device, storage medium and electronic device, aiming to improve the efficiency of migrating cloud instances to cloud functions.
[0007] In order to achieve the above purpose, the disclosed technical solution is as follows:
[0008] The first aspect of the present application discloses a migration deployment method, the method comprising:
[0009] Get the resource information of each application in running state;
[0010] According to a preset judgment rule, judging whether the resource information of the running state of each application meets the migration object condition;
[0011] If the resource information of the running state of each application meets the migration object condition, the application corresponding to the resource information of the running state of each application is determined as each target migration object program;
[0012] Determining whether each target migration object program meets the migration conditions;
[0013] If the target migration object program meets the migration conditions, the allocated resource information of the cloud function is obtained, and the target migration object program is migrated and deployed in batches according to the allocated resource information of the cloud function.
[0014] Preferably, the resource information of the running state of each application program includes at least a CPU utilization rate and a number of traffic inbound requests per second. The step of judging whether the resource information of the running state of each application program meets the migration object condition according to a preset judgment rule includes:
[0015] Based on the resource information of the running state of the application, it is determined whether the utilization rate of the central processing unit is a periodic sawtooth utilization rate, and whether the number of traffic inflow requests per second is less than or equal to a preset threshold value, to obtain a first judgment result; wherein the periodic sawtooth utilization rate is a utilization rate with a preset number of peak values and a preset number of valley values in each preset time interval;
[0016] Whether the migration object condition is met is determined according to the first judgment result.
[0017] Preferably, if the resource information of the running state of each application meets the migration object condition, determining the application corresponding to the resource information of the running state of the application as each target migration object program includes:
[0018] If the first judgment result indicates that the CPU utilization is a periodic sawtooth utilization, and the number of traffic inbound requests per second is less than or equal to the preset threshold, it is determined that the resource information of the running state of each application meets the migration object condition;
[0019] When the resource information of the running state of each application meets the migration object condition, the application corresponding to the resource information of the running state of each application is determined as each target migration object program; wherein the target migration object program is a periodic computing application program.
[0020] Preferably, it also includes:
[0021] If the first judgment result indicates that the CPU utilization is not a periodic sawtooth utilization, or the number of traffic requests per second entering the database is greater than the preset threshold, it is determined that the resource information of the running state of the application does not meet the migration object conditions, and the determination of the target migration object program is terminated.
[0022] Preferably, the determining whether each target migration object program meets the migration condition includes:
[0023] Determine whether each of the target migration object programs has a long-term cache entry, and obtain a second determination result;
[0024] Determining whether each target migration object program meets the migration condition according to the second judgment result;
[0025] The process of determining whether each target migration object program has a long-term cache entry includes:
[0026] Obtaining application source code of each target migration object program; wherein the application source code at least includes static collection class objects, runtime global collection class objects and other global collection variables;
[0027] The application source code is matched with cache items through matching rules to determine whether each target migration object program has a long-term cache item.
[0028] Preferably, the resource information of the cloud function includes at least current resource usage and cloud resource utilization, and if the target migration object program meets the migration condition, obtaining the allocated resource information of the cloud function, and performing migration deployment on the target migration object program according to the allocated resource information of the cloud function, including:
[0029] If the second judgment result indicates that each target migration object program does not have a long-term cache entry, determining that each target migration object program meets the migration condition;
[0030] When each target migration object program meets the migration condition, obtain the application code package of the cloud function and the resource usage information on the current cloud instance; wherein the resource usage information on the current cloud instance is the real resource usage information;
[0031] Obtaining resource allocation information of the cloud function based on the application code package of the cloud function and the resource usage information on the cloud instance;
[0032] In the application deployment environment, batch migration and deployment of cloud functions are performed on each target migration object program according to the allocated resource information of the cloud function.
[0033] Preferably, it also includes:
[0034] If the second judgment result indicates that the target migration object program has a long-term cache entry, determining that each of the target migration object programs does not meet the migration condition;
[0035] If each of the target migration object programs does not meet the migration condition, the long-term cache item is converted into a shared cache, and the target migration object program is migrated and deployed.
[0036] A second aspect of the present application discloses a migration deployment device, the device comprising:
[0037] An acquisition unit, used to acquire resource information of the running state of each application;
[0038] A first judgment unit, configured to judge whether the resource information of the running state of each application meets the migration object condition according to a preset judgment rule;
[0039] A first determining unit, configured to determine the application corresponding to the resource information of the running state of each application as each target migration object program if the resource information of the running state of each application meets the migration object condition;
[0040] A second judging unit, configured to judge whether each target migration object program meets the migration condition;
[0041] The migration deployment unit is used to obtain the allocated resource information of the cloud function if the target migration object program meets the migration conditions, and perform batch migration deployment on the target migration object program according to the allocated resource information of the cloud function.
[0042] A third aspect of the present application discloses a storage medium, which includes stored instructions, wherein when the instructions are executed, the device where the storage medium is located is controlled to execute the migration deployment method as described in any one of the first aspects.
[0043] The fourth aspect of the present application discloses an electronic device, comprising a memory and one or more instructions, wherein the one or more instructions are stored in the memory and are configured to be executed by one or more processors to perform the migration deployment method as described in any one of the first aspects.
[0044] It can be seen from the above technical scheme that the present application discloses a migration deployment method, device, storage medium and electronic device, which obtain the resource information of the running state of each application, and judge whether it meets the migration object conditions according to the preset judgment rules and the resource information of the running state of each application. If the resource information of the running state of each application meets the migration object conditions, the application corresponding to the resource information of the running state of each application is determined as each target migration object program, and it is judged whether each target migration object program meets the migration conditions. If the target migration object program meets the migration conditions, the allocated resource information of the cloud function is obtained, and the target migration object programs are batch migrated and deployed according to the allocated resource information of the cloud function.
[0045] Through the above scheme, the running state of the application is analyzed to obtain each target migration object program, so as to realize automatic identification and discovery of applications that can be migrated from the cloud instance to the cloud function during the migration process, and determine whether each target migration object program meets the migration conditions to determine whether the application can be migrated and deployed from the cloud instance to the cloud function. The actual usage is calculated based on the resource utilization of the current cloud instance, and the allocated resource information of the cloud function is obtained based on the actual usage to deploy the cloud function to complete the allocation of resource usage. At the same time, batch migration and deployment of the target migration object programs are automatically realized to improve the efficiency of cloud instance migration to cloud function. BRIEF DESCRIPTION OF THE DRAWINGS
[0046] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without paying any creative work.
[0047] Figure 1 A schematic diagram of the structure of the migration deployment system disclosed in the embodiment of the present application;
[0048] Figure 2 A flow chart of target application source code cache processing disclosed in an embodiment of the present application;
[0049] Figure 3 A resource allocation flow chart disclosed in an embodiment of the present application;
[0050] Figure 4 A flowchart of a migration deployment method disclosed in an embodiment of the present application;
[0051] Figure 5 A schematic diagram of the structure of a migration deployment device disclosed in an embodiment of the present application;
[0052] Figure 6 This is a schematic diagram of the structure of an electronic device disclosed in an embodiment of the present application. DETAILED DESCRIPTION
[0053] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0054] In this application, the terms "comprises", "comprising" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device comprising a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, an element defined by the sentence "comprising a ..." does not exclude the presence of other identical elements in the process, method, article or device comprising the element.
[0055] As can be seen from the background technology, the migration and deployment process of the prior art is also performed manually by technical personnel. Generally, the application programs that can be deployed to the cloud function are manually identified, and then the cloud function resources and environment are manually configured, and then the code software package is submitted to the cloud function, one by one. With the continuous increase in the number of applications, reaching hundreds or even thousands, technical personnel do not have the ability to batch identify whether they can be deployed to the cloud function, and it is difficult to batch migrate cloud instances to cloud functions. Therefore, how to improve the efficiency of migrating cloud instances to cloud functions is a problem that needs to be solved in this application.
[0056] In order to solve the above problems, the present application discloses a migration deployment method, device, storage medium and electronic device, which analyzes the running state of the application to obtain each target migration object program, so as to realize automatic identification and discovery of applications that can be migrated from cloud instances to cloud functions during the migration process, and determines whether each target migration object program meets the migration conditions to determine whether the application can be migrated and deployed from the cloud instance to the cloud function, and obtains the actual usage based on the resource utilization rate of the current cloud instance, and obtains the allocated resource information of the cloud function based on the actual usage to deploy the cloud function to complete the allocation of resource usage, and automatically realizes batch migration and deployment of the target migration object program, thereby improving the efficiency of migrating from the cloud instance to the cloud function. The specific implementation method is specifically described through the following embodiments.
[0057] refer to Figure 1As shown, it is a structural diagram of a migration deployment system disclosed in an embodiment of the present application. The migration deployment system includes a unified monitoring module, a migration judgment module and a migration deployment module.
[0058] The operation process of the unified monitoring module, migration judgment module and migration deployment module in the migration deployment system is as follows:
[0059] (1) Currently, applications are deployed on cloud instances. Traffic comes in from the load balancer and is forwarded to the cloud instance. The application deployed on the cloud instance executes the program and provides resource information of each application's running state to the unified monitoring module. The resource information includes cloud instance resource information, application related information, etc.
[0060] (2) The migration judgment module performs a complete judgment process based on the resource information of the running state of each application provided by the unified monitoring module. The specific judgment process is described as follows. After confirming the target application for migration, the long-term cache items of the application are processed to obtain the application code package that can be deployed to the cloud function. At the same time, combined with the resource usage information on the existing cloud instance, the allocation resource information that should be configured to the cloud function is obtained. Finally, the migration judgment module provides the allocation resource information to the cloud function migration module;
[0061] (3) The migration and deployment module of the cloud function deploys the function based on the allocated resource information of the cloud function obtained above, configures the cloud function parsing language (java, python, etc.) and running environment (jvm, python) based on the running environment of the application on the cloud instance, and then creates corresponding triggers (such as Hypertext Transfer Protocol (HTTP) triggers), receives traffic from the load balancing, provides services on behalf of the cloud instance, and provides program running information to the unified monitoring module. After the migration is completed, the application runs normally on the cloud function, and the entire batch migration and deployment process is completed.
[0062] The functions of the unified monitoring module, migration judgment module, and migration deployment module are as follows:
[0063] Unified monitoring module:
[0064] The unified monitoring module is used to collect monitoring data, that is, the resource information of the running state of the application, and provide formatted monitoring information to the migration judgment module for resource judgment. Specifically, the unified monitoring module collects the running state resource information of all applications, such as the application information, resource information, and utilization information of the application, and provides it to the migration judgment module after formatting. All information required during the migration deployment process can be obtained directly or indirectly from the unified monitoring module. The unified monitoring module not only collects the monitoring information of the cloud instance, but also collects the monitoring information of the cloud function, request traffic information, etc. through the application programming interface (API) provided by the cloud platform, etc., to ensure that the application migrated to the cloud function can also be fully monitored, achieving the same monitoring effect as the cloud instance monitoring.
[0065] Migration judgment module:
[0066] The migration judgment module is used to judge whether the application is suitable for migration deployment through multiple dimensions. Specifically, the migration judgment module judges whether the resource information of the running state of each application meets the migration object conditions according to the preset judgment rules.
[0067] It should be noted that judging whether the conditions for the migration object are met includes whether the primary conditions are met and whether the secondary conditions are met. The migration judgment module judges whether the CPU utilization of the cloud instance deployed by the application meets the primary condition. If it is a periodic sawtooth utilization, that is, there is a peak value in each preset time interval (the preset time interval is set according to the actual situation, and this application does not make specific restrictions), and there is a valley value in each preset time interval, it is sawtooth. The sawtooth utilization represents that the application is periodically performing calculation operations, which is a computing application. In addition, there is a difference between the peak and the trough, and this difference needs to reach the preset difference to meet the requirements. This preset difference is set according to the actual situation, and this application does not make specific restrictions.
[0068] Determine whether the number of requests per second (QPS) of the traffic entering the computing application meets the secondary condition. The determination of whether the QPS of the computing application meets the secondary condition is based on the preset threshold. If the QPS of the computing application is less than or equal to the preset threshold (the preset threshold is set according to the actual situation and is not specifically limited in this application), it is considered to meet the condition; if the QPS of the computing application exceeds the preset threshold, it means that this application is not only a computing program, but also a service program. It not only needs to provide a large amount of computing power, but also a large number of service interfaces. Such applications are still not suitable for cloud function deployment, so this condition is a secondary condition.
[0069] The application program that meets the above two conditions, namely the primary condition and the secondary condition, is the target migration program of this solution.
[0070] Specifically, the migration judgment module judges whether the migration object conditions are met according to the preset judgment rules and the resource information of the running state of each application, that is, by judging whether the CPU utilization is a periodic sawtooth utilization, and judging whether the QPS is less than or equal to the preset threshold, a first judgment result is obtained, and whether the migration object conditions are met is determined according to the first judgment result. The preset threshold here is set according to the actual situation, and this application does not make specific restrictions.
[0071] If the resource information of the running state of each application meets the migration object condition, the migration judgment module determines the application corresponding to the resource information of the running state of the application as each target migration object program. Specifically, if the first judgment result indicates that the CPU utilization is a periodic sawtooth utilization, and the QPS is less than or equal to the preset threshold, it is determined that the resource information of the running state of each application meets the migration object condition; if the resource information of the running state of each application meets the migration object condition, the application corresponding to the resource information of the running state of each application is determined as each target migration object program; wherein the target migration object program is a periodic computing application.
[0072] It should be noted that only periodic computing applications are most suitable for deployment on cloud functions. They are also the target of this technology. If it is a non-computing application, it may need to provide a large number of connections or a large number of interface services, which is not suitable for deployment on cloud functions; if it is a continuous computing application, there is no need to deploy it on cloud functions, because it does not waste the resources of cloud instances. Therefore, periodic computing applications and applications with idle periods are the target of this solution. Cloud functions save the cost of idle periods.
[0073] The migration judgment module obtains the running resource information of each application from the monitoring module. The running resource information of the application includes the basic information of the application (such as name, label, source code address, code package address, etc.), cloud instance resource information (such as cloud instance specifications, number of CPU cores, memory size, etc.), cloud instance resource utilization information, number of cloud instance hosts, request call frequency and other information related to the application.
[0074] If the resource information of the running state of each application program meets the migration object condition, the migration determination module determines the application program corresponding to the resource information of the running state of each application program as each target migration object program.
[0075] The migration judgment module judges whether the target migration object program meets the migration conditions. Specifically, the migration judgment module judges whether there is a long-term cache item for each target migration object program, obtains a second judgment result, and determines whether each target migration object program meets the migration conditions according to the second judgment result.
[0076] Among them, the migration judgment module judges whether each target application has a long-term cache item. If the second judgment result indicates that the target application has no long-term cache item, and it is determined that the target migration object program meets the migration conditions, then the migration can be started directly; if the second judgment result indicates that the target application has a long-term cache item, and it is determined that the target migration object program does not meet the migration conditions, then it is necessary to convert the long-term cache item into a shared cache item before migration can be performed. This process is because the application was originally deployed on the cloud instance. After the program is started, the memory is held for a long time and will not be released. Since the memory of the cloud function is not held for a long time, the long-term cache items in the code need to be converted into shared cache items to solve the efficiency problem of cache object initialization when the cloud function is executed.
[0077] The migration judgment module obtains the application source code of each target migration object program; wherein the application source code includes at least static collection class objects, runtime global collection class objects and other global collection variables, and the static collection class objects are global static collection class objects. The migration judgment module matches the cache items of the application source code through matching rules to determine whether each target migration object program has a long-term cache item.
[0078] The specific migration judgment module determines whether the target application has a long-term cache item by obtaining the application source code and judging whether there is a long-term cache item through the application source code. The content required for judgment mainly includes three types of objects: static collection class objects, runtime global collection class objects, and other global collection variables. These three types of objects are generally declared in the source code and can be directly judged by matching rules. For example, in the Java language, the hash map (HashMap) object in the global variable in the code is a long-term cache item. The HashMap object refers to the collection class used to store key-value pairs in the Java language. It is one of the most commonly used data structures in the Java collection framework. Map is an abstract data structure, and HashMap is a Map structure that concretizes the abstraction and is implemented based on the hash table. It is a specific static collection class object in Java.
[0079] Here, HashMap is used as an example to represent the Map structure. In addition, ArrayList can also be used to represent the List structure, HashSet can represent the Set structure, and so on.
[0080] To help you understand how the migration judgment module matches cache items of application source code through matching rules, an example is given here:
[0081] For example, in the application source code of each target migration object program, the described objects refer to the objects in the source code, which are mainly divided into three categories: the first type is static collection class objects, the second type is runtime global collection class objects, and the third type is other global collection class objects;
[0082] Static collection class objects refer to collections in the code, such as List, Map, Set and other collection class data structures in Java language. This collection class data structure mainly stores collections of other objects. Static collection class refers to static collection objects declared in Java class. This object is modified with static keyword and initialized when Java class is loaded for the first time. It exists in the whole life cycle of the application. The specific matching rules can be matched according to the keyword static and List, Map, Set in the source code;
[0083] Compared with the first category, the second category of runtime global collection class objects is not modified with the keyword static and will be initialized each time it is instantiated. However, in many cases, such as using the spring framework, some objects will use the singleton mode, and there will only be one instance of the global container class object. This type of object is also stored in the memory and used by the application for a long time, so it also needs to be extracted as a long-term cache item. The specific matching rule can be to find the singleton class in advance, and then find the collection class objects such as List, Map, Set, etc. in the singleton object;
[0084] After the long-term cache item becomes a shared cache item, the class object in the singleton mode obtains the corresponding collection class object through the shared cache after initialization, without the need to initialize the collection class object to memory during each cloud function execution.
[0085] The third category represents other global collection objects that have not been matched by the above two categories. They can also be matched according to the collection objects of List, Map, Set and other data structures in the Java class. The specific matching rules need to be enriched according to the specific situation. This logic is not only used in Java, but also in other object-oriented languages, such as golang, python and other languages.
[0086] If the second determination result indicates that the target migration object program has a long-term cache entry, the migration determination module determines that each target migration object program does not meet the migration condition.
[0087] After the migration judgment module obtains the target long-term cache item, the source code for operating such objects is uniformly changed to the source code for operating shared cache. For example, cache (Redis) can be introduced as a shared cache item. The application originally stored the target object in memory, and after rewriting it will be stored in Redis, solving the problem that cloud functions cannot hold memory for a long time.
[0088] After solving the problem of long-term cache items, the actual usage information can be obtained based on the current cloud resource usage and cloud resource utilization. For example, application A uses 10 cloud instances on cloud platform X, and the specification of each cloud instance is 4C8G (4 cores and 8G memory), and the peak utilization is 20%. The actual total usage of application A deployed on the cloud instance is: 10*4C8G*20%=8C16G. Cloud function resources are allocated based on the total amount. You can allocate 2 4C8G cloud functions or 4 2C4G cloud functions. This application does not require the allocation method. After allocating the resource configuration, provide the resource allocation information to the migration deployment module of the cloud function.
[0089] If the second judgment result indicates that there is no long-term cache item for each target migration object program, the migration judgment module determines that each target migration object program meets the migration conditions. When each target migration object program meets the migration conditions, the migration judgment module obtains the application code package of the cloud function and the resource usage information on the current cloud instance, wherein the resource usage information on the current cloud instance is the real resource usage information, and obtains the allocated resource information of the cloud function based on the application code package of the cloud function and the resource usage information on the cloud instance.
[0090] In order to facilitate the understanding of the process of the migration judgment module judging whether the target migration object program meets the migration conditions, combined with Figure 2 To explain, Figure 2 A flow chart of target application source code caching processing is shown.
[0091] Figure 2 In the migration judgment module, the target migration object program is obtained, and the target migration object program is judged by the source code whether there is a long-term cache item. The content mainly includes three types of objects: static container class objects (static container variables), runtime global collection class objects (runtime container variables) and other global collection variables. These three types of objects are generally declared in the source code and can be directly judged by matching rules. For example, in the Java language, the HashMap object in the global variable in the code is a long-term cache item;
[0092] After the migration judgment module obtains the long-term cache items, the migration judgment module will uniformly change the source code for operating such objects to the source code for operating shared caches. For example, Redis can be introduced as a shared cache item. Application A originally stored the target object in memory, and after rewriting it will be stored in Redis, thus solving the problem that cloud functions cannot hold memory for a long time. After that, submit the changed code to the code repository, and build a code delivery package based on the rewritten source code. After this process, application A is converted from a state suitable for deployment on a cloud instance to a state suitable for deployment on a cloud function.
[0093] If the target migration object program meets the migration conditions, the migration judgment module obtains the allocated resource information of the cloud function and sends the allocated resource information of the cloud function to the migration deployment module. The allocated resource information of the cloud function at least includes the current resource usage and cloud resource utilization.
[0094] Migrate deployment module:
[0095] The migration deployment module performs the migration deployment process of the cloud function based on the application information, resource information, and actual operating environment generated by the migration judgment module.
[0096] In the application deployment environment, the migration judgment module performs batch migration deployment of cloud functions for each target migration object program based on the allocated resource information of the cloud function.
[0097] When each target migration object program does not meet the migration conditions, the target migration object program converts the long-term cache items into shared caches, and performs migration deployment on the target migration object program through the migration deployment module.
[0098] Specifically, 1) the migration deployment module obtains the information required for cloud function deployment, such as application basic information, resource information, application code package information, and operating environment information, from the migration judgment module;
[0099] 2) The migration deployment module configures cloud function resources based on cloud instance resource information, and obtains clear function configuration and quantity from the migration judgment module.
[0100] The specific migration deployment module converts the cloud instance resource information into the allocation resource information of the cloud function, such as Figure 3 shown.
[0101] Figure 3 In the example, the deployment of application A includes cloud instance A, cloud instance B, and cloud instance C.
[0102] The unified monitoring module monitors and extracts resource information, including machine CPU information, runtime CPU peak value, machine memory information, runtime memory peak value, etc. The effective number of CPU cores is determined by the number of CPU cores in the machine CPU information, the CPU utilization in the machine CPU information, the number of instances (such as cloud instance A, cloud instance B, cloud instance C, the number of instances is 3), and the runtime CPU peak value. The effective memory size is determined by the memory size in the machine memory information, the memory utilization in the machine memory information, the number of instances, and the runtime memory peak value.
[0103] The cloud function rated resource configuration includes the number of cloud function CPU cores, the number of cloud functions, the cloud function memory size, and the cloud function elastic range. The number of cloud functions is determined by the total resources and the resources occupied by each function. The total resources are divided by the resources occupied by each function to get the number of cloud functions. The cloud function elastic range is the size of resources that can be adjusted when the function is fully loaded.
[0104] The actual usage information is obtained based on the current cloud resource usage and cloud resource utilization. For example, application A uses 10 cloud instances on cloud platform X, and the specification of each cloud instance is 4C8G (4 cores and 8G memory), and the peak utilization is 20%. The actual total usage of application A deployed on the cloud instance is: 10*4C8G*20%=8C16G. Based on the total amount, cloud function resource allocation can be performed, and 2 4C8G cloud functions can be allocated, or 4 2C4G cloud functions can be allocated;
[0105] If the application is deployed in multiple clouds, you can also perform multi-cloud deployment migration. For example, you can migrate a product cloud instance deployment to the product cloud function deployment.
[0106] Among them, cloud functions have a certain elasticity. When the function is running at full load, the resource size of the cloud function can be automatically expanded, such as from 2 cores to 4 cores. At the same time, if the function is running at low load, such as a cloud function configured with 4 cores, the peak usage is less than 2 cores, the function CPU can be automatically adjusted to 2 cores. This is one of the advantages of cloud function deployment compared to cloud instance deployment.
[0107] 3) The migration deployment module configures the cloud function information based on the application details, including the cloud function name, cloud function tag, etc. After that, the migration deployment module configures the cloud function's operating environment based on the application's operating environment on the cloud instance, for example, a Java application environment is Java 8, a Python application environment is Python 3.6, etc.
[0108] 4) The migration deployment module creates a cloud function listener based on the application interface to receive request traffic.
[0109] 5) All operations of the migration deployment module and the cloud platform cloud functions can be implemented by calling the cloud platform application programming interface (API) or software development kit (SDK).
[0110] 6) If the application is deployed in multiple clouds, it can also be deployed in multiple clouds. For example, the migration deployment module migrates the deployment of a product's cloud instance A to the product's cloud function a for deployment. The deployment of cloud instance B is migrated to cloud function b for deployment, and so on.
[0111] 7) After the deployment is completed, the migration deployment module forwards the traffic from the load balancing layer to the cloud function to achieve traffic transfer. After the traffic is transferred, the migration deployment module will periodically generate monitoring data of the cloud function and provide it to the unified monitoring module for application monitoring.
[0112] To facilitate understanding of the migration deployment process, an example is given here:
[0113] For example, application A is deployed on the cloud instance of product A cloud. This program is a Java program with the version of Java8. It uses 10 4C8G cloud instances. The traffic is routed to the cloud instance by the load balancer, and the traffic is forwarded by receiving requests through the HTTP listener of the load balancer. Application A is a computing program that receives 10 processing requests per hour. Each request takes 30 minutes to process. The peak CPU utilization is about 81%, the valley value is about 1%, and the memory is stable at around 40%;
[0114] The unified monitoring module provides information of application A to the migration judgment module;
[0115] The migration judgment module first judges the CPU situation and finds that the sawtooth utilization requirement is met. The difference = 81% - 1% = 80%. At the same time, the cycle is 30 minutes, that is, the application has a utilization rate of 80% for 30 minutes on the cloud instance, and another 1 hour (60 minutes) - 30 minutes = 30 minutes with a utilization rate of 1%. At this time, the application is in an idle state.
[0116] Application A meets the primary condition. The migration judgment module then judges the secondary condition and finds that the QPS of application A = 10 (pieces) / 3600 (seconds) < 1 (piece / second). The preset threshold of the QPS rated by the migration judgment module is 10, so it is determined that the secondary condition is met.
[0117] After testing the source code of application A, it was found that it did not have long-term cache items and did not need to be processed for long-term cache items. It was the most suitable resource for cloud function deployment.
[0118] At this time, the resources of application A are converted as follows: CPU effective resources = 10 units * 4 cores * 81% = 32 cores, memory effective resources = 10 units * 8G * 40% = 32G, then 32 cores and 32G resources can be allocated;
[0119] In this migration deployment configuration, if the total resource usage of application A does not exceed the preset threshold of 64 cores and 128G, large computing resources will be allocated first. At the same time, service availability needs to be guaranteed and dual cloud function deployment is required. In this case, the deployed cloud function is configured as 32 / 2=16 cores, and the result is the resource allocation information for deploying two 16-core 16G cloud functions. The preset threshold is optional and can be set according to actual conditions. This application does not make any specific restrictions.
[0120] After obtaining the real cloud function's allocated resource information and application deployment environment, the migration deployment module deploys the cloud function of application A on the cloud. At the same time, it creates a responsive HTTP trigger and receives traffic forwarded from the load balancer. The program runs normally every 30 minutes, completing the entire migration deployment process.
[0121] In order to solve the problem that it is not only difficult to identify applications that can be migrated from cloud instances to cloud functions under the existing technology, but also difficult to perform operations such as batch migration and deployment, which will cause a certain degree of idle resource waste, the migration and deployment method and device of the present application make a judgment based on the running characteristics of the application, and obtain the resource information of the running state of the application to judge the application type (such as computing type, IO type (disk), memory type, network type, etc.). The application that meets the computing type requirements is the target object of this technology. After determining the target object, the source code is analyzed to confirm whether the application can be directly migrated. For applications that do not have long-term cache items in the source code, this technology considers it to be a pure computing application, which is the most suitable target object for migration and can be directly migrated; for applications that have long-term cache items in the source code, it is necessary to convert its source code cache items into shared cache items to meet the conditions for migration. After confirming that the application can be migrated, the cloud function quota is configured based on the real resource usage data generated by the application on the existing cloud instance, which not only ensures the consistency of the resource environment of the application before and after migration, but also completes the utilization of effective resources and the recovery of idle resources.
[0122] In the running state of the application, this application mainly judges by the fluctuation of CPU utilization. If it is a periodic sawtooth utilization, it is considered to be a computing application, because the characteristic of computing applications is the volatility of CPU utilization. In addition, this technology allocates cloud function resources based on the actual resource usage of the application, and the application may be deployed on a single machine, a cluster, or multiple computer rooms. This technology performs different migration resource allocations based on different deployment characteristics to ensure the consistency of the resource environment after migration.
[0123] During the migration process, the present application automatically identifies and discovers applications that can be migrated from cloud instances to cloud functions, and automatically allocates resource usage, while automatically realizing batch migration and deployment of applications, solving the problems of being difficult to identify and migrate under the existing technology. Through long-term cache item conversion and resource usage allocation, which refer to the steps required in the migration and deployment process, the technical effect of batch migration from cloud instances to cloud functions is achieved, and finally the entire automated migration process is realized. At the same time, the cost difference between deploying applications on cloud instances and on cloud functions can be quantified, thereby reducing the effect of idle resources and reducing deployment costs.
[0124] This application analyzes the running state of the application to determine whether the application can be migrated and deployed, converts the actual usage based on the resource utilization of the current cloud instance, deploys cloud functions based on the actual usage, and uses the advantage of cloud functions that can use resources in quantity to reduce the cost of application deployment. Make a judgment based on the running characteristics of the application to identify whether the application is suitable for migration and deployment. First, determine the form of resource utilization, mainly including CPU utilization. If it is a periodic sawtooth resource utilization, it is determined to meet the primary condition; then, determine the call frequency of the traffic entry interface. If it is lower than a certain threshold, it is determined to meet the secondary condition. Resources that meet these two conditions are computing resources and are the target objects of migration; finally, determine whether the source code of the target object has a long-term cache item. If not, it can be directly migrated. If it has, the long-term cache is converted to a shared cache and then migrated. After confirming the migration target, deploy the cloud function based on the resource configuration of the original cloud instance, mainly including the number of CPU cores and the actual memory usage value of the cloud instance, so as to achieve an effective resource environment closest to the cloud instance. If the cloud instance is a cluster deployment, it is allocated based on the accumulated actual usage of resources, and multiple identical cloud functions are created for deployment. After the deployment is complete, the traffic routed to the cloud instance by the load balancer is transferred to the trigger of the cloud function, completing the entire migration process.
[0125] This application can reduce the resource deployment cost of the application. During the migration process, this application extracts and converts the actual usage of the cloud instance and deploys it to the cloud function. By taking advantage of the on-demand use of cloud function resource information, the idle usage of the cloud instance is saved, achieving the effect of reducing the deployment cost. At the same time, it automatically identifies applications suitable for cloud function deployment and automates the entire migration and deployment process. In addition, during the migration process, the resource costs can be quantitatively compared, and the specific cost savings after the migration can be automatically determined, which is convenient for business to calculate costs and reduces labor costs. Automatically discover applications suitable for deployment to cloud functions based on application characteristics, and then deploy cloud functions based on the current cloud instance information and the actual resource usage, and finally use the advantages of cloud functions to achieve the lowest deployment cost for the application.
[0126] This application provides the ability to automatically discover applications suitable for migration. Direct cost reduction. Migrating applications suitable for cloud function deployment from cloud instances to cloud functions is equivalent to recovering the resource costs of cloud instances in idle state, which directly reduces deployment costs. Batch application recognition and migration deployment capabilities, exponential efficiency improvement. It provides the ability to identify applications, and can automatically and batch-wise discover applications suitable for migration to cloud functions through the monitoring information of cloud instances, as well as batch migration and deployment, achieving efficiency improvement.
[0127] The beneficial effects of the embodiments of the present application are as follows: by analyzing the running state of the application, each target migration object program is obtained, so as to realize automatic identification and discovery of the application that can be migrated from the cloud instance to the cloud function during the migration process, and by judging whether each target migration object program meets the migration conditions, it is determined whether the application can be migrated and deployed from the cloud instance to the cloud function, and the actual usage is calculated based on the resource utilization of the current cloud instance, and the allocated resource information of the cloud function is obtained based on the actual usage to deploy the cloud function to complete the allocation of resource usage, and at the same time, the batch migration and deployment of the target migration object programs is automatically realized to improve the efficiency of migrating from the cloud instance to the cloud function.
[0128] refer to Figure 4 FIG. 1 is a flow chart of a migration deployment method disclosed in an embodiment of the present application, and the migration deployment method is applicable to the above-mentioned embodiment. Figure 1 The disclosed migration deployment system and the migration deployment method include:
[0129] S401: Obtain resource information of each application program in running state.
[0130] S402: According to the preset judgment rules, it is judged whether the resource information of the running state of each application meets the migration object condition. If yes, execute S403, if not, execute S406.
[0131] In S402, based on the resource information of the running state of the application, it is determined whether the CPU utilization is a periodic sawtooth utilization, and whether the number of traffic requests per second entering the database is less than or equal to a preset threshold, to obtain a first judgment result, and based on the first judgment result, it is determined whether the migration object conditions are met.
[0132] The periodic sawtooth utilization rate is a utilization rate with a preset number of peak values and a preset number of valley values in each preset time interval.
[0133] S403: Determine the application programs corresponding to the resource information of the running state of each application program as each target migration object program.
[0134] In S403, if the judgment result indicates that the CPU utilization is a periodic sawtooth utilization, and the number of traffic inbound requests per second is less than or equal to a preset threshold, it is determined that the running state resource information of each application meets the migration object condition.
[0135] When the resource information of the running state of each application program meets the migration object condition, the application program corresponding to the resource information of the running state of each application program is determined as each target migration object program.
[0136] The target migration object program is a periodic computing application program.
[0137] S404: Determine whether each target migration object program meets the migration conditions. If yes, execute S405; if no, execute S407.
[0138] The specific process of determining whether each target migration object program meets the migration conditions is shown in A1-A2.
[0139] A1: Determine whether each target migration object program has a long-term cache entry, and obtain a second determination result.
[0140] The specific process of determining whether each target migration object program has a long-term cache entry is as follows:
[0141] First, the application source code of each target migration object program is obtained; wherein the application source code at least includes static collection class objects, runtime global collection class objects and other global collection variables;
[0142] Then, cache items are matched against the application source code through matching rules to determine whether there are long-term cache items for each target migration object program.
[0143] A2: Determine whether each target migration program meets the migration condition according to the second judgment result.
[0144] S405: Obtain the resource allocation information of the cloud function, and perform batch migration deployment on the target migration object program according to the resource allocation information of the cloud function.
[0145] Specifically, if the target migration object program meets the migration conditions, the allocation resource information of the cloud function is obtained, and the target migration object program is batch migrated and deployed according to the allocation resource information of the cloud function, as shown in B1-B4.
[0146] B1: If the second determination result indicates that each target migration object program does not have a long-term cache entry, it is determined that each target migration object program meets the migration condition.
[0147] If the second judgment result indicates that the target migration object program has a long-term cache item, it is determined that each target migration object program does not meet the migration conditions. If each target migration object program does not meet the migration conditions, the long-term cache item is converted into a shared cache, and the target migration object program is migrated and deployed.
[0148] B2: When each target migration object program meets the migration conditions, obtain the application code package of the cloud function and the resource usage information on the current cloud instance; wherein the resource usage information on the current cloud instance is the real resource usage information.
[0149] B3: Obtain the allocated resource information of the cloud function based on the application code package of the cloud function and the resource usage information on the cloud instance.
[0150] B4: In the application deployment environment, perform batch migration and deployment of cloud functions for each target migration object program based on the allocated resource information of the cloud function.
[0151] S406: End the determination of the target migration program.
[0152] In S406, if the judgment result indicates that the CPU utilization is not a periodic sawtooth utilization, or the number of traffic inflow requests per second is greater than the preset threshold, it is determined that the resource information of the running state of the application does not meet the migration object conditions, and the determination of the target migration object program is terminated.
[0153] S407: Convert the long-term cache items in each target migration object program that does not meet the migration condition into a shared cache, and perform migration deployment on the target migration object program.
[0154] The execution process and execution principle of S401-S407 are similar to those of the above embodiment. Figure 1 The execution process and execution principle are consistent, which can be used as a reference and will not be repeated here.
[0155] The beneficial effects of the embodiments of the present application are as follows: by analyzing the running state of the application, each target migration object program is obtained, so as to realize automatic identification and discovery of the application that can be migrated from the cloud instance to the cloud function during the migration process, and by judging whether each target migration object program meets the migration conditions, it is determined whether the application can be migrated and deployed from the cloud instance to the cloud function, and the actual usage is calculated based on the resource utilization of the current cloud instance, and the allocated resource information of the cloud function is obtained based on the actual usage to deploy the cloud function to complete the allocation of resource usage, and at the same time, the batch migration and deployment of the target migration object programs is automatically realized to improve the efficiency of migrating from the cloud instance to the cloud function.
[0156] Based on the above embodiments Figure 4 A migration deployment method is disclosed, and the embodiment of the present application also discloses a migration deployment device, such as Figure 5 As shown, the migration deployment device includes:
[0157] The acquisition unit 501 is used to acquire the resource information of the running state of each application program;
[0158] The first judgment unit 502 is used to judge whether the resource information of the running state of each application meets the migration object condition according to a preset judgment rule;
[0159] The first determining unit 503 is configured to determine the application corresponding to the resource information of the running state of each application as each target migration object program if the resource information of the running state of each application meets the migration object condition;
[0160] The second determination unit 504 is used to determine whether each target migration object program meets the migration condition;
[0161] The migration deployment unit 505 is used to obtain the allocated resource information of the cloud function if the target migration object program meets the migration conditions, and perform batch migration deployment on the target migration object program according to the allocated resource information of the cloud function.
[0162] Furthermore, the first judging unit 502 includes:
[0163] The first judgment module is used to judge whether the CPU utilization is a periodic sawtooth utilization, and whether the number of traffic inbound requests per second is less than or equal to a preset threshold value, based on the resource information of the running state of the application program, to obtain a first judgment result; wherein the periodic sawtooth utilization is a utilization with a preset number of peak values and a preset number of valley values in each preset time interval;
[0164] The first determination module is used to determine whether the migration object condition is met according to the first judgment result.
[0165] Further, the first determining unit 503 includes:
[0166] The second determination module is used to determine that the resource information of the running state of each application meets the migration object condition if the judgment result indicates that the CPU utilization is a periodic sawtooth utilization and the number of traffic inbound requests per second is less than or equal to a preset threshold;
[0167] The third determination module is used to determine the applications corresponding to the running state resource information of each application as target migration object programs when the running state resource information of each application meets the migration object conditions; wherein the target migration object program is a periodic computing application program.
[0168] Furthermore, it also includes:
[0169] The second determination unit is used to determine that the resource information of the running state of the application does not meet the migration object conditions if the judgment result indicates that the central processing unit utilization is not a periodic sawtooth utilization, or the number of traffic requests per second entering the database is greater than the preset threshold, and end the judgment of the target migration object program.
[0170] Furthermore, the second determining unit 504 includes:
[0171] The second judgment module is used to judge whether each target migration object program has a long-term cache item, and obtain a second judgment result;
[0172] A fourth determination module, used to determine whether each target migration object program meets the migration condition according to the second judgment result;
[0173] The second judgment module includes:
[0174] The acquisition submodule is used to acquire the application source code of each target migration object program; wherein the application source code at least includes static collection class objects, runtime global collection class objects and other global collection variables;
[0175] The matching submodule is used to match cache items of the application source code through matching rules, so as to determine whether there are long-term cache items for each target migration object program.
[0176] Furthermore, the resource information of the cloud function includes at least the current resource usage and the cloud resource utilization rate. The migration deployment unit 505 includes:
[0177] A fifth determination module, configured to determine that each target migration object program meets the migration condition if the second determination result indicates that each target migration object program does not have a long-term cache item;
[0178] The first acquisition module is used to acquire the application code package of the cloud function and the resource usage information on the current cloud instance when each target migration object program meets the migration conditions; wherein the resource usage information on the current cloud instance is the real resource usage information;
[0179] A second acquisition module is used to obtain the allocated resource information of the cloud function according to the application code package of the cloud function and the resource usage information on the cloud instance;
[0180] The migration deployment module is used to perform batch migration and deployment of cloud functions for each target migration object program according to the allocated resource information of the cloud function in the application deployment environment.
[0181] Furthermore, the migration deployment device also includes:
[0182] A second determination unit is used to determine that each target migration object program does not meet the migration condition if the second judgment result indicates that the target migration object program has a long-term cache item;
[0183] The conversion unit is used to convert the long-term cache items into shared caches when each target migration object program does not meet the migration conditions, and perform migration deployment on the target migration object program.
[0184] The beneficial effects of the embodiments of the present application are as follows: it is possible to automatically identify and discover applications that can be migrated from cloud instances to cloud functions during the migration process, determine whether each target migration object program meets the migration conditions, and determine whether the application can be migrated and deployed from the cloud instance to the cloud function. The actual usage is calculated based on the resource utilization of the current cloud instance, and the allocated resource information of the cloud function is obtained based on the actual usage to deploy the cloud function to complete the allocation of resource usage. At the same time, batch migration and deployment of the target migration object programs are automatically realized to improve the efficiency of migrating from cloud instances to cloud functions.
[0185] An embodiment of the present application further provides a storage medium, which includes stored instructions, wherein when the instructions are executed, the device where the storage medium is located is controlled to execute the above-mentioned migration deployment method.
[0186] The present application also provides an electronic device, whose structural diagram is as follows: Figure 6 As shown, it specifically includes a memory 601 and one or more instructions 602, wherein the one or more instructions 602 are stored in the memory 601 and are configured to be executed by one or more processors 603 to execute the one or more instructions 602 to perform the above-mentioned migration deployment method.
[0187] For the aforementioned method embodiments, for the sake of simplicity, they are all described as a series of action combinations, but those skilled in the art should be aware that the present application is not limited by the order of the actions described, because according to the present application, some steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also be aware that the embodiments described in the specification are all preferred embodiments, and the actions and modules involved are not necessarily required by the present application.
[0188] It should be noted that each embodiment in this specification is described in a progressive manner, and each embodiment focuses on the differences from other embodiments, and the same or similar parts between the embodiments can be referred to each other. For system embodiments, since they are basically similar to method embodiments, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.
[0189] The steps in the methods of the embodiments of the present application can be adjusted in order, combined, and deleted according to actual needs.
[0190] Finally, it should be noted that, in this article, relational terms such as first and second, etc. are merely used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any actual relationship or order between these entities or operations.
[0191] The above description of the disclosed embodiments enables those skilled in the art to implement or use the present application. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the scope of the present application. Therefore, the present application will not be limited to the embodiments shown herein, but will conform to the widest scope consistent with the principles and novel features disclosed herein.
[0192] The above is only a preferred implementation of the present application. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present application. These improvements and modifications should also be regarded as the scope of protection of the present application.
Claims
1. A migration deployment method, characterized in that: The method comprises: Get the resource information of each application in running state; According to a preset judgment rule, judging whether the resource information of the running state of each application meets the migration object condition; If the resource information of the running state of each application meets the migration object condition, the application corresponding to the resource information of the running state of each application is determined as each target migration object program; Determining whether each target migration object program meets the migration conditions; If the target migration object program meets the migration conditions, the allocated resource information of the cloud function is obtained, and the target migration object program is migrated and deployed in batches according to the allocated resource information of the cloud function.
2. The method according to claim 1, characterized in that The resource information of the running state of each application program includes at least a CPU utilization rate and a number of traffic inbound requests per second. The judging, according to a preset judging rule, whether the resource information of the running state of each application program meets the migration object condition includes: Based on the resource information of the running state of the application, it is determined whether the utilization rate of the central processing unit is a periodic sawtooth utilization rate, and whether the number of traffic inflow requests per second is less than or equal to a preset threshold value, to obtain a first judgment result; wherein the periodic sawtooth utilization rate is a utilization rate with a preset number of peak values and a preset number of valley values in each preset time interval; Whether a migration object condition is met is determined according to the first judgment result.
3. The method according to claim 2, characterized in that If the resource information of the running state of each application meets the migration object condition, determining the application corresponding to the resource information of the running state of the application as each target migration object program includes: If the first judgment result indicates that the CPU utilization is a periodic sawtooth utilization, and the number of traffic inbound requests per second is less than or equal to the preset threshold, it is determined that the resource information of the running state of each application meets the migration object condition; When the resource information of the running state of each application meets the migration object condition, the application corresponding to the resource information of the running state of each application is determined as each target migration object program; wherein the target migration object program is a periodic computing application program.
4. The method according to claim 3, characterized in that Also includes: If the first judgment result indicates that the CPU utilization is not a periodic sawtooth utilization, or the number of traffic requests per second entering the database is greater than the preset threshold, it is determined that the resource information of the running state of the application does not meet the migration object conditions, and the determination of the target migration object program is terminated.
5. The method according to claim 1, characterized in that The determining whether each target migration object program meets the migration condition includes: Determine whether each of the target migration object programs has a long-term cache entry to obtain a second determination result; Determining whether each target migration object program meets the migration condition according to the second judgment result; The process of determining whether each target migration object program has a long-term cache entry includes: Obtaining application source code of each target migration object program; wherein the application source code at least includes static collection class objects, runtime global collection class objects and other global collection variables; The application source code is matched with cache items through matching rules to determine whether each target migration object program has a long-term cache item.
6. The method according to claim 5, characterized in that The resource information of the cloud function includes at least current resource usage and cloud resource utilization. If the target migration object program meets the migration condition, obtaining the allocated resource information of the cloud function, and performing migration deployment on the target migration object program according to the allocated resource information of the cloud function, including: If the second judgment result indicates that each target migration object program does not have a long-term cache entry, determining that each target migration object program meets the migration condition; When each target migration object program meets the migration condition, obtain the application code package of the cloud function and the resource usage information on the current cloud instance; wherein the resource usage information on the current cloud instance is the real resource usage information; Obtaining resource allocation information of the cloud function based on the application code package of the cloud function and the resource usage information on the cloud instance; In the application deployment environment, batch migration and deployment of cloud functions are performed on each target migration object program according to the allocated resource information of the cloud function.
7. The method according to claim 5, characterized in that Also includes: If the second judgment result indicates that the target migration object program has a long-term cache entry, determining that each of the target migration object programs does not meet the migration condition; If each of the target migration object programs does not meet the migration condition, the long-term cache item is converted into a shared cache, and the target migration object program is migrated and deployed.
8. A migration deployment device, characterized in that: The device comprises: An acquisition unit, used to acquire resource information of the running state of each application; A first judgment unit, configured to judge whether the resource information of the running state of each application meets the migration object condition according to a preset judgment rule; A first determining unit, configured to determine the application corresponding to the resource information of the running state of each application as each target migration object program if the resource information of the running state of each application meets the migration object condition; A second judging unit, configured to judge whether each target migration object program meets the migration condition; The migration deployment unit is used to obtain the allocated resource information of the cloud function if the target migration object program meets the migration conditions, and perform batch migration deployment on the target migration object program according to the allocated resource information of the cloud function.
9. A storage medium, characterized in that: The storage medium includes stored instructions, wherein when the instructions are executed, the device where the storage medium is located is controlled to execute the migration deployment method according to any one of claims 1 to 7.
10. An electronic device, characterized in that: It comprises a memory and one or more instructions, wherein the one or more instructions are stored in the memory and are configured to be executed by one or more processors to perform the migration deployment method as claimed in any one of claims 1 to 7.