Configuration parameter determination method and device, equipment and medium
By obtaining parameter documents and target operation environments from the current running environment, and generating and detecting configuration parameters, the problem of low parameter configuration efficiency and poor reliability when enterprises migrate applications is solved, efficient and accurate configuration parameter determination is achieved, and the stability and work efficiency of the application are improved.
Patent Information
- Application Number
- CN202411865461.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-18
- Publication Date
- 2025-03-28
AI Technical Summary
When enterprises migrate applications, the existing technology relies on manual configuration and verification of parameters, resulting in low efficiency and error proneness. Especially when the parameter data is large, it cannot be effectively checked, which affects work efficiency and application stability.
By obtaining parameter documents from the current running environment of the application, obtaining configuration rules from the target running environment to be migrated, generating configuration parameters of the target running environment, and performing consistency detection with the configuration parameters of the current running environment to determine the target configuration parameters.
This method can accurately and reliably determine target configuration parameters, reduce manual verification errors, save time and cost, improve work efficiency, enhance application stability and reliability, and save computer and network resources when the parameter data is large.
Smart Images

Figure CN119718409A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of big data technology, specifically to the field of cloud computing technology, and in particular to a configuration parameter determination method, device, equipment, medium and program product. Background Art
[0002] In enterprises including banks, with the development of computer network technology, the demand for parameter configuration in data migration is gradually increasing. Enterprises including banks often need to migrate applications from the current operating environment to a new operating environment to meet business needs. During the migration process, it is necessary to configure and determine the parameters in the new operating environment.
[0003] In the prior art, the parameters in the new operating environment are manually configured, and each configuration parameter is checked and confirmed after the configuration is completed. This method is not only inefficient, but also prone to errors. When the amount of parameter data is large, only sampling checks can be performed for efficiency, which reduces the reliability of the configuration parameters. In addition, due to manual verification, the reuse rate is low. Each time an application is migrated, the parameters must be reconfigured and checked, which affects work efficiency. Summary of the invention
[0004] In view of the above problems, the present disclosure provides a configuration parameter determination method, apparatus, device, medium and program product.
[0005] According to the first aspect of the present disclosure, a method for determining configuration parameters is provided, the method comprising: obtaining a parameter document of a first operating environment from a first operating environment of an application, wherein the first operating environment is the current operating environment of the application; obtaining configuration rules of a second operating environment from a second operating environment of the application, wherein the second operating environment is the target operating environment to be migrated of the application; generating configuration parameters for the second operating environment when running the application based on the parameter document of the first operating environment and the configuration rules of the second operating environment; obtaining the configuration parameters for the first operating environment when running the application, and performing a consistency check on the configuration parameters for the second operating environment when running the application and the configuration parameters for the first operating environment when running the application; and if the consistency check on the configuration parameters for the second operating environment when running the application and the configuration parameters for the first operating environment when running the application passes, determining that the configuration parameters for the second operating environment when running the application are the target configuration parameters for the second operating environment when running the application.
[0006] According to an embodiment of the present disclosure, the first operating environment includes: a cloud computing service model, and the second operating environment includes: a standardized operating environment. Based on the parameter document of the first operating environment and the configuration rules of the second operating environment, configuration parameters for the second operating environment to run an application are generated, including: analyzing the parameter document of the cloud computing service model to generate a parameter list of the cloud computing service model; obtaining the common variables and node variables of the standardized operating environment from the configuration rules of the standardized operating environment, and generating parameter dependencies when the standardized operating environment runs the application based on the common variables and node variables of the standardized operating environment; and adjusting the parameter list of the cloud computing service model based on the parameter dependencies when the standardized operating environment runs the application to generate configuration parameters when the standardized operating environment runs the application.
[0007] According to an embodiment of the present disclosure, the parameter list of the cloud computing service model is adjusted based on the parameter dependencies when the standardized operating environment runs the application, and the configuration parameters when the standardized operating environment runs the application are generated, including: adjusting the parameter list of the cloud computing service model based on the parameter dependencies when the standardized operating environment runs the application, and generating a parameter list of the standardized operating environment; and configuring the environment variables of the standardized operating environment and the version variables of the application for the parameter list of the standardized operating environment, and generating the configuration parameters when the standardized operating environment runs the application.
[0008] According to an embodiment of the present disclosure, a consistency check is performed on the configuration parameters when the second operating environment runs the application and the configuration parameters when the first operating environment runs the application, including: encoding the configuration parameters when the standardized environment runs the application to generate multiple standardized configuration parameter key-value pairs, wherein each standardized configuration parameter key-value pair has a standardized configuration parameter name as a key and a standardized configuration parameter value as a value; encoding the configuration parameters when the cloud computing model runs the application to generate multiple cloud computing model configuration parameter key-value pairs, wherein each cloud computing model configuration parameter key-value pair has a cloud computing model configuration parameter name as a key and a cloud computing model configuration parameter value as a value; and a consistency check is performed on the multiple standardized configuration parameter key-value pairs and the multiple cloud computing model configuration parameter key-value pairs.
[0009] According to an embodiment of the present disclosure, a consistency check is performed on the multiple standardized configuration parameter key-value pairs and the multiple cloud computing model configuration parameter key-value pairs, including: obtaining standardized configuration parameter key-value pairs and cloud computing model configuration parameter key-value pairs with the same parameter name, and generating multiple detection key-value pairs corresponding to each other; obtaining the standardized configuration parameter values and the cloud computing model configuration parameter values in each pair of detection key-value pairs in the multiple detection key-value pairs, and judging whether the standardized configuration parameter values and the cloud computing model configuration parameter values in each pair of detection key-value pairs in the multiple detection key-value pairs are consistent; obtaining the number of detection key-value pairs in which the standardized configuration parameter values and the cloud computing model configuration parameter values are consistent in the multiple detection key-value pairs; and if the number of detection key-value pairs in which the standardized configuration parameter values and the cloud computing model configuration parameter values are consistent in the multiple detection key-value pairs is greater than a preset threshold, the consistency check passes.
[0010] According to an embodiment of the present disclosure, the method further includes: obtaining parameter names of detection key-value pairs whose standardized configuration parameter values and cloud computing model configuration parameter values are inconsistent among the multiple detection key-value pairs and marking them for reminder.
[0011] According to a second aspect of the present disclosure, a configuration parameter determination device is provided, which includes: a first acquisition module, used to acquire a parameter document of a first operating environment from a first operating environment of an application, wherein the first operating environment is the current operating environment of the application; a second acquisition module, used to acquire configuration rules of a second operating environment from a second operating environment of the application, wherein the second operating environment is a target operating environment to be migrated by the application; a first generation module, used to generate configuration parameters when the second operating environment runs the application based on the parameter document of the first operating environment and the configuration rules of the second operating environment; a first detection module, used to acquire the configuration parameters when the first operating environment runs the application, and perform consistency detection on the configuration parameters when the second operating environment runs the application and the configuration parameters when the first operating environment runs the application; and a determination module, used to determine that the configuration parameters when the second operating environment runs the application are the target configuration parameters when the second operating environment runs the application if the consistency detection of the configuration parameters when the second operating environment runs the application and the configuration parameters when the first operating environment runs the application passes.
[0012] According to an embodiment of the present disclosure, the first operating environment includes: a cloud computing service model, the second operating environment includes: a standardized operating environment, and the first generating module includes: a second generating module for analyzing a parameter document of the cloud computing service model to generate a parameter list of the cloud computing service model; a third generating module for acquiring common variables and node variables of the standardized operating environment from configuration rules of the standardized operating environment, and generating parameter dependencies when the standardized operating environment runs an application based on the common variables and node variables of the standardized operating environment; and a fourth generating module for adjusting the parameter list of the cloud computing service model based on the parameter dependencies when the standardized operating environment runs an application, and generating configuration parameters when the standardized operating environment runs an application.
[0013] According to an embodiment of the present disclosure, the fourth generation module includes: a fifth generation module, which is used to adjust the parameter list of the cloud computing service model based on the parameter dependency when the standardized operating environment runs the application, and generate a parameter list of the standardized operating environment; and a sixth generation module, which is used to configure the environment variables of the standardized operating environment and the version variables of the application for the parameter list of the standardized operating environment, and generate configuration parameters when the standardized operating environment runs the application.
[0014] According to an embodiment of the present disclosure, the first detection module includes: a seventh generation module, which is used to encode the configuration parameters when the standardized environment runs the application, and generate multiple standardized configuration parameter key-value pairs, wherein each standardized configuration parameter key-value pair has a standardized configuration parameter name as a key and a standardized configuration parameter value as a value; an eighth generation module, which is used to encode the configuration parameters when the cloud computing model runs the application, and generate multiple cloud computing model configuration parameter key-value pairs, wherein each cloud computing model configuration parameter key-value pair has a cloud computing model configuration parameter name as a key and a cloud computing model configuration parameter value as a value; and a second detection module, which is used to perform consistency detection on the multiple standardized configuration parameter key-value pairs and the multiple cloud computing model configuration parameter key-value pairs.
[0015] According to an embodiment of the present disclosure, the second detection module includes: a ninth generation module, used to obtain standardized configuration parameter key-value pairs and cloud computing model configuration parameter key-value pairs with the same parameter name, and generate multiple detection key-value pairs corresponding to each other; a judgment module, used to obtain the standardized configuration parameter values and cloud computing model configuration parameter values in each pair of detection key-value pairs in the multiple detection key-value pairs, and judge whether the standardized configuration parameter values and cloud computing model configuration parameter values in each pair of detection key-value pairs in the multiple detection key-value pairs are consistent; a third acquisition module, used to obtain the number of detection key-value pairs in which the standardized configuration parameter values and the cloud computing model configuration parameter values are consistent in the multiple detection key-value pairs; and a third detection module, used to pass the consistency detection if the number of detection key-value pairs in which the standardized configuration parameter values and the cloud computing model configuration parameter values are consistent in the multiple detection key-value pairs is greater than a preset threshold.
[0016] According to a third aspect of the present disclosure, an electronic device is provided, comprising: one or more processors; a storage device for storing one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors execute the above-mentioned configuration parameter determination method.
[0017] According to a fourth aspect of the present disclosure, a computer-readable storage medium is provided, on which executable instructions or computer programs are stored. When the instructions or computer programs are executed by a processor, the processor executes the above-mentioned configuration parameter determination method.
[0018] According to a fifth aspect of the present disclosure, a computer program product is also provided, including a computer program, which implements the above-mentioned configuration parameter determination method when executed by a processor.
[0019] This method generates the configuration parameters of the target operating environment by obtaining the parameter document of the current operating environment and the configuration rules of the target operating environment, and then obtains the configuration parameters of the current operating environment to perform consistency detection on the generated configuration parameters of the target operating environment. This solves the technical problem that a large number of configuration parameters cannot be effectively checked when the application is migrated from the current operating environment to the target operating environment. This method can accurately and reliably determine the target configuration parameters, which is convenient for effectively reducing manual verification errors, saving time costs, improving work efficiency, and achieving the technical effect of improving the stability and reliability of application operation. This method does not require sampling to check parameters when the parameter data volume is large and can be reused, saving computer resources and network resources, and improving the utilization rate of computer resources and network resources. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] The above contents and other purposes, features and advantages of the present disclosure will become more apparent through the following description of the embodiments of the present disclosure with reference to the accompanying drawings, in which:
[0021] Figure 1 A diagram schematically shows an application scenario of a method and device for determining configuration parameters according to an embodiment of the present disclosure;
[0022] Figure 2 A flowchart of a method for determining configuration parameters according to an embodiment of the present disclosure is schematically shown;
[0023] Figure 3 A flowchart schematically shows a method for determining configuration parameters according to an embodiment of the present disclosure for generating configuration parameters when the second operating environment runs an application program;
[0024] Figure 4 A flowchart schematically shows a method for determining configuration parameters according to an embodiment of the present disclosure for generating configuration parameters when running an application in a standardized running environment;
[0025] Figure 5 A flowchart schematically shows a method for determining configuration parameters according to an embodiment of the present disclosure for detecting consistency between configuration parameters when the standardized environment runs an application and configuration parameters when the cloud computing model runs an application;
[0026] Figure 6 A flowchart schematically illustrates a method for determining configuration parameters according to an embodiment of the present disclosure for performing consistency detection on a plurality of standardized configuration parameter key-value pairs and a plurality of cloud computing model configuration parameter key-value pairs;
[0027] Figure 7 A structural block diagram of a device for determining configuration parameters according to an embodiment of the present disclosure is schematically shown; and
[0028] Figure 8 A block diagram of an electronic device suitable for implementing a configuration parameter determination method according to an embodiment of the present disclosure is schematically shown. DETAILED DESCRIPTION
[0029] Hereinafter, embodiments of the present disclosure will be described with reference to the accompanying drawings. However, it should be understood that these descriptions are exemplary only and are not intended to limit the scope of the present disclosure. In the following detailed description, for ease of explanation, many specific details are set forth to provide a comprehensive understanding of the embodiments of the present disclosure. However, it is apparent that one or more embodiments may also be implemented without these specific details. In addition, in the following description, descriptions of known structures and technologies are omitted to avoid unnecessary confusion of the concepts of the present disclosure.
[0030] The terms used herein are only for describing specific embodiments and are not intended to limit the present disclosure. The terms "comprise", "include", etc. used herein indicate the existence of the features, steps, operations and / or components, but do not exclude the existence or addition of one or more other features, steps, operations or components.
[0031] All terms (including technical and scientific terms) used herein have the meanings commonly understood by those skilled in the art unless otherwise defined. It should be noted that the terms used herein should be interpreted as having a meaning consistent with the context of this specification and should not be interpreted in an idealized or overly rigid manner.
[0032] When using expressions such as "at least one of A, B, and C, etc.", they should generally be interpreted according to the meaning of the expression commonly understood by those skilled in the art (for example, "a system having at least one of A, B, and C" should include but is not limited to a system having A alone, B alone, C alone, A and B, A and C, B and C, and / or A, B, C, etc.).
[0033] Some block diagrams and / or flow charts are shown in the accompanying drawings. It should be understood that some blocks or combinations thereof in the block diagrams and / or flow charts may be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable control device, so that these instructions, when executed by the processor, may create a device for implementing the functions / operations described in these block diagrams and / or flow charts.
[0034] First, the technical terms that appear in this article are explained as follows:
[0035] Node variables: variables that are used only in the application service node and are defined in the node-specific git repository along with the program.
[0036] Public variables: variables with the same name and business meaning used in multiple application service nodes, which are centrally defined in an independent public git repository.
[0037] git repository: an environment for storing and managing code versions.
[0038] An embodiment of the present disclosure provides a method for determining configuration parameters, the method comprising: obtaining a parameter document of a first operating environment from a first operating environment of an application, wherein the first operating environment is the current operating environment of the application. Obtaining configuration rules of a second operating environment from a second operating environment of the application, wherein the second operating environment is the target operating environment to be migrated by the application. Based on the parameter document of the first operating environment and the configuration rules of the second operating environment, generating configuration parameters for the second operating environment when the application is running. Obtaining the configuration parameters for the first operating environment when the application is running, and performing a consistency check on the configuration parameters for the second operating environment when the application is running and the configuration parameters for the first operating environment when the application is running. If the consistency check on the configuration parameters for the second operating environment when the application is running passes the consistency check on the configuration parameters for the first operating environment when the application is running, determining that the configuration parameters for the second operating environment when the application is running are the target configuration parameters for the second operating environment when the application is running.
[0039] According to the disclosed embodiment, the configuration parameters of the target operating environment are generated by acquiring the parameter document of the current operating environment and the configuration rules of the target operating environment, and then the configuration parameters of the current operating environment are acquired to perform consistency check on the generated configuration parameters of the target operating environment. The technical problem that a large number of configuration parameters cannot be effectively checked when the application is migrated from the current operating environment to the target operating environment is solved. The method can accurately and reliably determine the target configuration parameters, which is convenient for effectively reducing manual verification errors, saving time costs, improving work efficiency, and achieving the technical effect of improving the stability and reliability of the application operation. The method does not need to sample and verify parameters when the parameter data volume is large and can be reused, saving computer resources and network resources, and improving the utilization rate of computer resources and network resources.
[0040] Figure 1 The following schematically shows an application scenario diagram of the configuration parameter determination method and device according to an embodiment of the present disclosure. It should be noted that: Figure 1 The examples shown are merely scenarios in which the embodiments of the present disclosure can be applied, to help those skilled in the art understand the technical content of the present disclosure, but do not mean that the embodiments of the present disclosure cannot be used in other devices, systems, environments or scenarios.
[0041] like Figure 1 As shown, the application scenario 100 according to this embodiment may include an application scenario determined by configuration parameters. The network 104 is used to provide a medium for a communication link between the first terminal device 101, the second terminal device 102, the third terminal device 103 and the server 105. The network 104 may include various connection types, such as wired, wireless communication links or optical fiber cables, etc.
[0042] The user can use the first terminal device 101, the second terminal device 102, and the third terminal device 103 to interact with the server 105 through the network 104 to receive or send messages, etc. Various communication client applications can be installed on the first terminal device 101, the second terminal device 102, and the third terminal device 103, such as shopping applications, web browser applications, search applications, instant messaging tools, email clients, social platform software, etc. (only for example).
[0043] The first terminal device 101, the second terminal device 102, and the third terminal device 103 may be various electronic devices having display screens and supporting web browsing, including but not limited to smart phones, tablet computers, laptop computers, desktop computers, and the like.
[0044] The server 105 may be a server that provides various services, such as a background management server (only as an example) that provides support for websites browsed by users using the first terminal device 101, the second terminal device 102, and the third terminal device 103. The background management server may analyze and process the received data such as user requests, and feed back the processing results (such as web pages, information, or data obtained or generated according to user requests) to the terminal device.
[0045] It should be noted that the configuration parameter determination method provided in the embodiment of the present disclosure can generally be executed by the server 105. Accordingly, the configuration parameter determination device provided in the embodiment of the present disclosure can generally be set in the server 105. The configuration parameter determination method provided in the embodiment of the present disclosure can also be executed by a server or server cluster that is different from the server 105 and can communicate with the first terminal device 101, the second terminal device 102, the third terminal device 103 and / or the server 105. Accordingly, the configuration parameter determination device provided in the embodiment of the present disclosure can also be set in a server or server cluster that is different from the server 105 and can communicate with the first terminal device 101, the second terminal device 102, the third terminal device 103 and / or the server 105.
[0046] It should be understood that Figure 1 The number of terminal devices, networks and servers in the embodiment is only for illustration. Any number of terminal devices, networks and servers may be provided according to implementation requirements.
[0047] The following will be based on Figure 1 The scene described by Figure 2~Figure 6 The configuration parameter determination method of the disclosed embodiment is described in detail. It should be noted that the above application scenarios are only shown to facilitate understanding of the spirit and principle of the present disclosure, and the embodiments of the present disclosure are not limited in this respect. On the contrary, the embodiments of the present disclosure can be applied to any applicable scenario.
[0048] Figure 2 The flowchart of the configuration parameter determination method according to the embodiment of the present disclosure is schematically shown.
[0049] like Figure 2 As shown, the method 200 includes steps S201 to S205.
[0050] Step S201: Obtain a parameter document of a first operating environment from a first operating environment of an application, wherein the first operating environment is a current operating environment of the application.
[0051] Step S202: Acquire configuration rules of a second operating environment from a second operating environment of the application, wherein the second operating environment is a target operating environment to be migrated by the application.
[0052] Step S203: Based on the parameter document of the first operating environment and the configuration rules of the second operating environment, generate configuration parameters for the second operating environment to run the application.
[0053] For example, the first operating environment may be a cloud computing model, and the second operating environment may be a standardized operating environment. When the application is migrated from the cloud computing model to the standardized operating environment, the parameter document of the cloud computing model and the configuration rules of the standardized operating environment may be obtained to generate configuration parameters for running the application in the standardized operating environment.
[0054] Figure 3 The flowchart of generating configuration parameters when the second running environment runs an application in the configuration parameter determination method according to an embodiment of the present disclosure is schematically shown.
[0055] like Figure 3 As shown, the method 300 includes steps S301 to S303.
[0056] Step S301: Analyze the parameter document of the cloud computing model to generate a parameter list of the cloud computing model.
[0057] For example, a parameter document of a cloud computing model may be obtained, the parameter document of the cloud computing model including detailed parameters of the cloud computing model, and semantic analysis may be performed on the detailed parameters of the cloud computing model in the parameter document of the cloud computing model to generate a detailed parameter list of the cloud computing model.
[0058] Step S302: acquiring common variables and node variables of the standardized operating environment from the configuration rules of the standardized operating environment, and generating parameter dependencies when the standardized operating environment runs an application based on the common variables and node variables of the standardized operating environment.
[0059] For example, the common variables and node variables of the standardized operating environment can be obtained, the common variables and node variables of the standardized operating environment can be parsed to generate a data dependency graph, and then the data dependency graph can be identified to generate parameter dependencies when the standardized operating environment runs the application.
[0060] Step S303: adjusting the parameter list of the cloud computing model based on the parameter dependency when the standardized operating environment runs the application program, and generating configuration parameters when the standardized operating environment runs the application program.
[0061] Figure 4 The flowchart of generating configuration parameters when running an application in a standardized running environment in a configuration parameter determination method according to an embodiment of the present disclosure is schematically shown.
[0062] like Figure 4 As shown, the method 400 includes steps S401-S402.
[0063] Step S401: adjusting the parameter list of the cloud computing model based on the parameter dependency when the standardized operating environment runs the application program, and generating a parameter list of the standardized operating environment.
[0064] Step S402: configuring the parameter list of the standardized operating environment with environment variables of the standardized operating environment and version variables of the application program, and generating configuration parameters for the standardized operating environment to run the application program.
[0065] For example, the environment variables of the standardized operating environment may be different from the environment variables of the running application to be migrated, and the version variables of the application in the standardized operating environment may be different from the version variables of the running application to be migrated.
[0066] By configuring the environment variables of the standardized operating environment and the version variables of the application, the compatibility between the standardized operating environment and the application can be improved, and the adaptability of the standardized operating environment to the application can be enhanced.
[0067] By obtaining the public variables and node variables of the standardized operating environment, adjusting the parameter list of the cloud computing model, and generating configuration parameters suitable for running applications in the standardized operating environment, the accuracy of the configuration parameters when running applications in the standardized operating environment can be improved, thereby improving the robustness of application operation.
[0068] Return to reference Figure 2 In step S204, the configuration parameters of the first operating environment when running the application are obtained, and the consistency of the configuration parameters of the second operating environment when running the application and the configuration parameters of the first operating environment when running the application are checked.
[0069] For example, the configuration parameters when the cloud computing model runs the application can be obtained, and the configuration parameters when the standard environment runs the application and the configuration parameters when the cloud computing model runs the application can be checked for consistency. The configuration parameters when the cloud computing model runs the application generally include: parameter name, parameter value, parameter level, the name, parameter description, whether the parameter value is modified, whether the parameter value is overwritten, parameter value type, environment variables and version variables and other information. The parameter levels include application level, template level and template group level. An application in the cloud computing model can contain multiple templates, and the templates can be classified into template groups. Finally, this parameter will be operated according to whether the modification prompt is needed after the build package version is imported, and the version inheritance relationship will be judged by whether it is overwritten, and then the template will be started to read the value of the corresponding parameter, and the variable will be assigned according to the parameter level and the name, and finally the corresponding parameter will be used in the container operation.
[0070] Figure 5 The flowchart of the configuration parameter determination method according to the embodiment of the present disclosure for checking the consistency between the configuration parameters when the standardized environment runs the application and the configuration parameters when the cloud computing model runs the application is schematically shown.
[0071] like Figure 5 As shown, the method 500 includes steps S501 to S503.
[0072] Step S501, encoding the configuration parameters when the standardized environment runs the application, generating a plurality of standardized configuration parameter key-value pairs, wherein each standardized configuration parameter key-value pair has a standardized configuration parameter name as a key and a standardized configuration parameter value as a value.
[0073] For example, since parameter names are unique, the standardized configuration parameter name can be used as the key and the standardized configuration parameter value can be used as the value. The configuration parameters when running the application in the standardized environment can be encoded using hash coding to generate a standardized configuration parameter key-value pair for each parameter. Since it is hash coding, a standardized configuration hash value is generated for each parameter's standardized configuration parameter key-value pair.
[0074] Step S502, encode the configuration parameters of the cloud computing model when running the application, and generate multiple cloud computing model configuration parameter key-value pairs, wherein each cloud computing model configuration parameter key-value pair has a cloud computing model configuration parameter name as a key and a cloud computing model configuration parameter value as a value.
[0075] For example, the cloud computing model configuration parameter name can be used as the key and the cloud computing model configuration parameter value can be used as the value. The configuration parameters when the cloud computing model environment runs the application can be encoded in a hash coding manner to generate a cloud computing model configuration parameter key-value pair for each parameter. Since it is a hash coding, a cloud computing model configuration parameter key-value pair for each parameter generates a cloud computing model configuration hash value.
[0076] Step S503: performing consistency detection on the multiple standardized configuration parameter key-value pairs and the multiple cloud computing model configuration parameter key-value pairs.
[0077] Figure 6 The flowchart of performing consistency detection on multiple standardized configuration parameter key-value pairs and multiple cloud computing model configuration parameter key-value pairs in the configuration parameter determination method according to an embodiment of the present disclosure is schematically shown.
[0078] like Figure 6 As shown, the method 600 includes steps S601 to S604.
[0079] Step S601, obtaining standardized configuration parameter key-value pairs and cloud computing model configuration parameter key-value pairs having the same parameter name, and generating a plurality of detection key-value pairs in one-to-one correspondence.
[0080] Step S602, obtain the standardized configuration parameter values and cloud computing model configuration parameter values in each pair of detection key-value pairs in multiple detection key-value pairs, and determine whether the standardized configuration parameter values and cloud computing model configuration parameter values in each pair of detection key-value pairs in the multiple detection key-value pairs are consistent.
[0081] In addition, the standardized configuration hash value and the cloud computing model configuration hash value in each pair of detection key-value pairs in multiple detection key-value pairs can be obtained to determine whether the standardized configuration hash value and the cloud computing model configuration hash value in each pair of detection key-value pairs in the multiple detection key-value pairs are consistent.
[0082] Step S603: Obtain the number of detection key-value pairs whose standardized configuration parameter values are consistent with the cloud computing model configuration parameter values in the multiple detection key-value pairs.
[0083] In addition, the parameter names of the detection key-value pairs whose standardized configuration parameter values and cloud computing model configuration parameter values are inconsistent among the multiple detection key-value pairs can also be obtained and marked as reminders.
[0084] For example, you can use colors to mark parameters, and use the colors to make it easier to modify them. For example, you can use yellow to indicate inconsistent parameters, red to indicate missing parameters, and blue to indicate redundant parameters. You can also use artificial intelligence recognition models to identify the parameters that must be modified and the parameters that can be left unchanged in the inconsistent parameter names.
[0085] By marking and reminding the names of inconsistent parameters, abnormal configuration parameters can be quickly identified, which facilitates the optimization of target configuration parameters and further improves the reliability of target configuration parameters.
[0086] Step S604: If the number of detection key-value pairs in which the standardized configuration parameter value and the cloud computing model configuration parameter value are consistent among the multiple detection key-value pairs is greater than a preset threshold, the consistency check is passed.
[0087] By detecting the values of the standardized configuration parameter key-value pairs and the cloud computing model configuration parameter key-value pairs with the same key, consistency detection can be performed to improve the accuracy of consistency detection, while improving detection efficiency, saving CPU resources, and improving CPU utilization.
[0088] By using the method of encoding and generating key-value pairs for consistency detection, the execution efficiency of consistency detection can be improved, computer resources can be saved, the accuracy of consistency detection can be enhanced, and the reliability of configuration parameters can be further improved.
[0089] Return to reference Figure 2 In step S205, if the configuration parameters when the second operating environment runs the application pass the consistency check with the configuration parameters when the first operating environment runs the application, the configuration parameters when the second operating environment runs the application are determined to be the target configuration parameters when the second operating environment runs the application.
[0090] According to the disclosed embodiment, the configuration parameters of the target operating environment are generated by acquiring the parameter document of the current operating environment and the configuration rules of the target operating environment, and then the configuration parameters of the current operating environment are acquired to perform consistency check on the generated configuration parameters of the target operating environment. The technical problem that a large number of configuration parameters cannot be effectively checked when the application is migrated from the current operating environment to the target operating environment is solved. The method can accurately and reliably determine the target configuration parameters, which is convenient for effectively reducing manual verification errors, saving time costs, improving work efficiency, and achieving the technical effect of improving the stability and reliability of the application operation. The method does not need to sample and verify parameters when the parameter data volume is large and can be reused, saving computer resources and network resources, and improving the utilization rate of computer resources and network resources.
[0091] Figure 7 The structural block diagram of the configuration parameter determination device according to an embodiment of the present disclosure is schematically shown.
[0092] like Figure 7 As shown, the device 700 includes: a first acquisition module 701, a second acquisition module 702, a first generation module 703, a first detection module 704 and a determination module 705.
[0093] The first acquisition module 701 is used to acquire a parameter document of a first operating environment from a first operating environment of the application, wherein the first operating environment is the current operating environment of the application. In one embodiment, the first acquisition module 701 can be used to execute the step S201 described above, which will not be described in detail here.
[0094] The second acquisition module 702 is used to acquire the configuration rules of the second operating environment from the second operating environment of the application, wherein the second operating environment is the target operating environment to be migrated by the application. In one embodiment, the second acquisition module 702 can be used to execute the step S202 described above, which will not be repeated here.
[0095] The first generating module 703 is used to generate configuration parameters for the second operating environment to run the application based on the parameter document of the first operating environment and the configuration rules of the second operating environment. In one embodiment, the first generating module 703 can be used to execute the step S203 described above.
[0096] The first generating module 703 includes: a second generating module, a third generating module and a fourth generating module.
[0097] The second generation module is used to analyze the parameter document of the cloud computing service model and generate a parameter list of the cloud computing service model. In one embodiment, the second generation module can be used to execute step S301 described above, which will not be described in detail here.
[0098] The third generation module is used to obtain the common variables and node variables of the standardized operating environment from the configuration rules of the standardized operating environment, and generate parameter dependencies when the standardized operating environment runs the application based on the common variables and node variables of the standardized operating environment. In one embodiment, the third generation module can be used to execute step S302 described above, which will not be repeated here.
[0099] The fourth generation module is used to adjust the parameter list of the cloud computing service model based on the parameter dependency when the standardized operating environment runs the application program, and generate configuration parameters when the standardized operating environment runs the application program. In one embodiment, the fourth generation module can be used to execute step S303 described above.
[0100] The fourth generation module includes: a fifth generation module and a sixth generation module.
[0101] The fifth generation module is used to adjust the parameter list of the cloud computing service model based on the parameter dependency when the standardized operating environment runs the application program, and generate the parameter list of the standardized operating environment. In one embodiment, the fifth generation module can be used to execute step S401 described above, which will not be repeated here.
[0102] The sixth generation module is used to configure the environment variables of the standardized operating environment and the version variables of the application program for the parameter list of the standardized operating environment, and generate configuration parameters when the standardized operating environment runs the application program. In one embodiment, the sixth generation module can be used to execute step S402 described above, which will not be repeated here.
[0103] The first detection module 704 is used to obtain the configuration parameters when the first operating environment runs the application, and perform consistency detection on the configuration parameters when the second operating environment runs the application and the configuration parameters when the first operating environment runs the application. In one embodiment, the first detection module 704 can be used to execute the step S204 described above, which will not be repeated here.
[0104] The first detection module 704 includes: a seventh generation module, an eighth generation module and a second detection module.
[0105] The seventh generation module is used to encode the configuration parameters when the standardized environment runs the application program, and generate a plurality of standardized configuration parameter key-value pairs, wherein each standardized configuration parameter key-value pair has a standardized configuration parameter name as a key and a standardized configuration parameter value as a value. In one embodiment, the seventh generation module can be used to execute step S501 described above, which will not be described in detail here.
[0106] The eighth generation module is used to encode the configuration parameters when the cloud computing model runs the application program, and generate a plurality of cloud computing model configuration parameter key-value pairs, wherein each cloud computing model configuration parameter key-value pair has a cloud computing model configuration parameter name as a key and a cloud computing model configuration parameter value as a value. In one embodiment, the eighth generation module can be used to execute step S502 described above, which will not be described in detail here.
[0107] The second detection module is used to perform consistency detection on the plurality of standardized configuration parameter key-value pairs and the plurality of cloud computing model configuration parameter key-value pairs. In one embodiment, the second detection module can be used to execute step S503 described above.
[0108] The second detection module includes: a ninth generation module, a judgment module, a third acquisition module and a third detection module.
[0109] The ninth generation module is used to obtain the standardized configuration parameter key-value pairs and the cloud computing model configuration parameter key-value pairs with the same parameter name, and generate a plurality of detection key-value pairs corresponding to each other. In one embodiment, the ninth generation module can be used to execute the step S601 described above, which will not be described in detail here.
[0110] The judgment module is used to obtain the standardized configuration parameter value and the cloud computing model configuration parameter value in each detection key-value pair in the multiple detection key-value pairs, and judge whether the standardized configuration parameter value and the cloud computing model configuration parameter value in each detection key-value pair in the multiple detection key-value pairs are consistent. In one embodiment, the judgment module can be used to execute step S602 described above, which will not be repeated here.
[0111] The third acquisition module is used to acquire the number of detection key-value pairs whose standardized configuration parameter values are consistent with the cloud computing model configuration parameter values in the multiple detection key-value pairs. In one embodiment, the third acquisition module can be used to execute step S603 described above, which will not be repeated here.
[0112] The third detection module is used to pass the consistency detection if the number of detection key-value pairs whose standardized configuration parameter values and cloud computing model configuration parameter values are consistent among the multiple detection key-value pairs is greater than a preset threshold. In one embodiment, the third detection module can be used to execute step S604 described above, which will not be repeated here.
[0113] The determination module 705 is used to determine that the configuration parameters when the second operating environment runs the application are the target configuration parameters when the second operating environment runs the application if the configuration parameters when the second operating environment runs the application pass the consistency test with the configuration parameters when the first operating environment runs the application. In one embodiment, the determination module 705 can be used to execute the step S205 described above, which will not be repeated here.
[0114] According to an embodiment of the present disclosure, any multiple modules of the first acquisition module 701, the second acquisition module 702, the first generation module 703, the first detection module 704 and the determination module 705 can be combined into one module for implementation, or any one of the modules can be split into multiple modules. Alternatively, at least part of the functions of one or more of these modules can be combined with at least part of the functions of other modules and implemented in one module. According to an embodiment of the present disclosure, at least one of the first acquisition module 701, the second acquisition module 702, the first generation module 703, the first detection module 704 and the determination module 705 can be at least partially implemented as a hardware circuit, such as a field programmable gate array (FPGA), a programmable logic array (PLA), a system on a chip, a system on a substrate, a system on a package, an application specific integrated circuit (ASIC), or can be implemented by hardware or firmware such as any other reasonable way of integrating or packaging the circuit, or implemented in any one of the three implementation modes of software, hardware and firmware or in a proper combination of any of them. Alternatively, at least one of the first acquisition module 701, the second acquisition module 702, the first generation module 703, the first detection module 704 and the determination module 705 may be at least partially implemented as a computer program module, which may perform corresponding functions when executed.
[0115] Figure 8 A block diagram of an electronic device suitable for implementing a configuration parameter determination method according to an embodiment of the present disclosure is schematically shown.
[0116] like Figure 8 As shown, the electronic device 800 according to an embodiment of the present disclosure includes a processor 801, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 802 or a program loaded from a storage part 808 to a random access memory (RAM) 803. The processor 801 may include, for example, a general-purpose microprocessor (e.g., a CPU), an instruction set processor and / or a related chipset and / or a dedicated microprocessor (e.g., an application-specific integrated circuit (ASIC)), etc. The processor 801 may also include an onboard memory for caching purposes. The processor 801 may include a single processing unit or multiple processing units for performing different actions of the method flow according to an embodiment of the present disclosure.
[0117] In RAM803, various programs and data required for the operation of electronic device 800 are stored. Processor 801, ROM802 and RAM803 are connected to each other via bus 804. Processor 801 performs various operations of the method flow according to the embodiment of the present disclosure by executing the program in ROM802 and / or RAM803. It should be noted that the program can also be stored in one or more memories other than ROM802 and RAM 803. Processor 801 can also perform various operations of the method flow according to the embodiment of the present disclosure by executing the program stored in the one or more memories.
[0118] According to an embodiment of the present disclosure, the electronic device 800 may further include an input / output (I / O) interface 805, which is also connected to the bus 804. The electronic device 800 may further include one or more of the following components connected to the I / O interface 805: an input portion 806 including a keyboard, a mouse, etc.; an output portion 807 including a cathode ray tube (CRT), a liquid crystal display (LCD), etc., and a speaker, etc.; a storage portion 808 including a hard disk, etc.; and a communication portion 809 including a network interface card such as a LAN card, a modem, etc. The communication portion 809 performs communication processing via a network such as the Internet. A drive 810 is also connected to the I / O interface 805 as needed. A removable medium 811, such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc., is installed on the drive 810 as needed, so that a computer program read therefrom is installed into the storage portion 808 as needed.
[0119] The present disclosure also provides a computer-readable storage medium, which may be included in the device / apparatus / system described in the above embodiments; or may exist independently without being assembled into the device / apparatus / system. The above computer-readable storage medium carries one or more programs, and when the above one or more programs are executed, the method according to the embodiment of the present disclosure is implemented.
[0120] According to an embodiment of the present disclosure, a computer-readable storage medium may be a non-volatile computer-readable storage medium, for example, may include but is not limited to: a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination thereof. In the present disclosure, a computer-readable storage medium may be any tangible medium containing or storing a program, which may be used by or in combination with an instruction execution system, an apparatus or a device. For example, according to an embodiment of the present disclosure, a computer-readable storage medium may include the ROM802 and / or RAM803 described above and / or one or more memories other than ROM 802 and RAM 803.
[0121] The embodiment of the present disclosure also includes a computer program product, which includes a computer program, and the computer program contains program code for executing the method shown in the flowchart. When the computer program product is run in a computer system, the program code is used to enable the computer system to implement the configuration parameter determination method provided by the embodiment of the present disclosure.
[0122] The above functions defined in the system / device of the embodiment of the present disclosure are executed when the computer program is executed by the processor 801. According to the embodiment of the present disclosure, the system, device, module, unit, etc. described above can be implemented by a computer program module.
[0123] In one embodiment, the computer program may rely on tangible storage media such as optical storage devices, magnetic storage devices, etc. In another embodiment, the computer program may also be transmitted and distributed in the form of signals on a network medium, and downloaded and installed through the communication part 809, and / or installed from a removable medium 811. The program code contained in the computer program may be transmitted using any appropriate network medium, including but not limited to: wireless, wired, etc., or any suitable combination of the above.
[0124] In such an embodiment, the computer program can be downloaded and installed from the network through the communication part 809, and / or installed from the removable medium 811. When the computer program is executed by the processor 801, the above functions defined in the system of the embodiment of the present disclosure are performed. According to the embodiment of the present disclosure, the system, device, means, module, unit, etc. described above can be implemented by a computer program module.
[0125] According to an embodiment of the present disclosure, the program code for executing the computer program provided by the embodiment of the present disclosure can be written in any combination of one or more programming languages. Specifically, these computing programs can be implemented using high-level process and / or object-oriented programming languages, and / or assembly / machine languages. Programming languages include, but are not limited to, Java, C++, python, "C" language or similar programming languages. The program code can be executed entirely on the user computing device, partially on the user device, partially on the remote computing device, or entirely on the remote computing device or server. In the case of a remote computing device, the remote computing device can be connected to the user computing device through any type of network, including a local area network (LAN) or a wide area network (WAN), or can be connected to an external computing device (for example, using an Internet service provider to connect through the Internet).
[0126] The flow charts and block diagrams in the accompanying drawings illustrate the possible architecture, functions and operations of the systems, methods and computer program products according to various embodiments of the present disclosure. In this regard, each box in the flow chart or block diagram can represent a module, a program segment, or a part of a code, and the above-mentioned module, program segment, or a part of a code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram or flow chart, and the combination of the boxes in the block diagram or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0127] It will be appreciated by those skilled in the art that the features described in the various embodiments and / or claims of the present disclosure may be combined and / or combined in a variety of ways, even if such combinations and / or combinations are not explicitly described in the present disclosure. In particular, the features described in the various embodiments and / or claims of the present disclosure may be combined and / or combined in a variety of ways without departing from the spirit and teachings of the present disclosure. All of these combinations and / or combinations fall within the scope of the present disclosure.
[0128] The embodiments of the present disclosure are described above. However, these embodiments are only for the purpose of illustration and are not intended to limit the scope of the present disclosure. Although the embodiments are described above separately, this does not mean that the measures in the various embodiments cannot be used in combination to advantage. The scope of the present disclosure is defined by the attached claims and their equivalents. Without departing from the scope of the present disclosure, those skilled in the art may make various substitutions and modifications, which should all fall within the scope of the present disclosure.
Claims
1. A method for determining configuration parameters, characterized in that: The method includes: Acquire a parameter document of a first operating environment from a first operating environment of the application, wherein the first operating environment is a current operating environment of the application; Acquire a configuration rule of a second operating environment from a second operating environment of the application, wherein the second operating environment is a target operating environment to be migrated of the application; Based on the parameter document of the first operating environment and the configuration rules of the second operating environment, generate configuration parameters for the second operating environment to run the application; Acquire configuration parameters when the first operating environment runs the application, and perform consistency detection on the configuration parameters when the second operating environment runs the application and the configuration parameters when the first operating environment runs the application; and If the configuration parameters when the second operating environment runs the application pass the consistency check with the configuration parameters when the first operating environment runs the application, the configuration parameters when the second operating environment runs the application are determined to be the target configuration parameters when the second operating environment runs the application.
2. The method according to claim 1, characterized in that The first operating environment includes: a cloud computing service model, and the second operating environment includes: a standardized operating environment. Based on the parameter document of the first operating environment and the configuration rules of the second operating environment, the configuration parameters for the second operating environment to run the application program are generated, including: Analyzing the parameter document of the cloud computing service model to generate a parameter list of the cloud computing service model; Acquire common variables and node variables of the standardized operating environment from configuration rules of the standardized operating environment, and generate parameter dependencies when the standardized operating environment runs an application based on the common variables and node variables of the standardized operating environment; and The parameter list of the cloud computing service model is adjusted based on the parameter dependency when the standardized operating environment runs the application program, and the configuration parameters when the standardized operating environment runs the application program are generated.
3. The method according to claim 2, characterized in that The method further comprises: adjusting the parameter list of the cloud computing service model based on the parameter dependency relationship when the standardized operating environment runs the application program, and generating the configuration parameters when the standardized operating environment runs the application program, including: Adjusting the parameter list of the cloud computing service model based on the parameter dependency when the standardized operating environment runs the application program to generate a parameter list of the standardized operating environment; and The parameter list of the standardized operating environment is configured with environment variables of the standardized operating environment and version variables of the application program, and configuration parameters for the standardized operating environment to run the application program are generated.
4. The method according to claim 2, characterized in that: Performing consistency detection on configuration parameters when the second operating environment runs the application program and configuration parameters when the first operating environment runs the application program, including: Encoding the configuration parameters when the application is run in the standardized environment to generate a plurality of standardized configuration parameter key-value pairs, wherein each standardized configuration parameter key-value pair has a standardized configuration parameter name as a key and a standardized configuration parameter value as a value; Encoding the configuration parameters of the cloud computing model when running the application program to generate a plurality of cloud computing model configuration parameter key-value pairs, wherein each cloud computing model configuration parameter key-value pair has a cloud computing model configuration parameter name as a key and a cloud computing model configuration parameter value as a value; and A consistency check is performed on the multiple standardized configuration parameter key-value pairs and the multiple cloud computing model configuration parameter key-value pairs.
5. The method according to claim 4, characterized in that Performing consistency detection on the plurality of standardized configuration parameter key-value pairs and the plurality of cloud computing model configuration parameter key-value pairs includes: Obtaining standardized configuration parameter key-value pairs and cloud computing model configuration parameter key-value pairs having the same parameter name, and generating a plurality of detection key-value pairs corresponding to each other; Obtaining standardized configuration parameter values and cloud computing model configuration parameter values in each detection key-value pair in a plurality of detection key-value pairs, and determining whether the standardized configuration parameter values and cloud computing model configuration parameter values in each detection key-value pair in the plurality of detection key-value pairs are consistent; Obtaining the number of detection key-value pairs whose standardized configuration parameter values are consistent with the cloud computing model configuration parameter values in the plurality of detection key-value pairs; and If the number of detection key-value pairs whose standardized configuration parameter values and cloud computing model configuration parameter values are consistent among the multiple detection key-value pairs is greater than a preset threshold, the consistency check passes.
6. The method according to claim 5, characterized in that The method further includes: The parameter names of the detection key-value pairs whose standardized configuration parameter values and cloud computing model configuration parameter values are inconsistent among the multiple detection key-value pairs are obtained and marked as reminders.
7. A configuration parameter determination device, characterized in that: The device includes: A first acquisition module, used to acquire a parameter document of a first operating environment from a first operating environment of the application, wherein the first operating environment is a current operating environment of the application; A second acquisition module, used to acquire configuration rules of a second operating environment from a second operating environment of the application, wherein the second operating environment is a target operating environment to be migrated of the application; A first generating module, configured to generate configuration parameters for the second operating environment to run the application based on the parameter document of the first operating environment and the configuration rules of the second operating environment; A first detection module is used to obtain configuration parameters when the first operating environment runs the application, and perform consistency detection on the configuration parameters when the second operating environment runs the application and the configuration parameters when the first operating environment runs the application; and A determination module is used to determine that the configuration parameters when the second operating environment runs the application are the target configuration parameters when the second operating environment runs the application if the configuration parameters when the second operating environment runs the application pass the consistency check with the configuration parameters when the first operating environment runs the application.
8. An electronic device comprising: one or more processors; a memory for storing one or more computer programs, It is characterized in that the one or more processors execute the one or more computer programs to implement the steps of the method according to any one of claims 1 to 6.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program or instruction is executed by a processor, the steps of the method according to any one of claims 1 to 6 are implemented.
10. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 6 are implemented.