CN114157662A - Cloud platform parameter adaptation method and device, terminal equipment and storage medium - Google Patents
Cloud platform parameter adaptation method and device, terminal equipment and storage medium Download PDFInfo
- Publication number
- CN114157662A CN114157662A CN202111322770.4A CN202111322770A CN114157662A CN 114157662 A CN114157662 A CN 114157662A CN 202111322770 A CN202111322770 A CN 202111322770A CN 114157662 A CN114157662 A CN 114157662A
- Authority
- CN
- China
- Prior art keywords
- parameter
- cloud platform
- cloud
- interface
- class
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/10—Protocols in which an application is distributed across nodes in the network
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L63/00—Network architectures or network communication protocols for network security
- H04L63/08—Network architectures or network communication protocols for network security for authentication of entities
- H04L63/083—Network architectures or network communication protocols for network security for authentication of entities using passwords
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L9/00—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
- H04L9/06—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols the encryption apparatus using shift registers or memories for block-wise or stream coding, e.g. DES systems or RC4; Hash functions; Pseudorandom sequence generators
- H04L9/0643—Hash functions, e.g. MD5, SHA, HMAC or f9 MAC
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L9/00—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
- H04L9/32—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials
- H04L9/3236—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials using cryptographic hash functions
- H04L9/3239—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials using cryptographic hash functions involving non-keyed hash functions, e.g. modification detection codes [MDCs], MD5, SHA or RIPEMD
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02D—CLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
- Y02D10/00—Energy efficient computing, e.g. low power processors, power management or thermal management
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Computer Security & Cryptography (AREA)
- Power Engineering (AREA)
- Computer Hardware Design (AREA)
- Computing Systems (AREA)
- General Engineering & Computer Science (AREA)
- Stored Programmes (AREA)
Abstract
The embodiment of the invention discloses a cloud platform parameter adaptation method, a device, terminal equipment and a storage medium, wherein the method comprises the steps of obtaining the cloud platform type of each cloud platform accessed to a multi-cloud management platform; the method comprises the steps that a parameter class statement corresponding to a parameter class of each interface on a multi-cloud management platform is obtained, the parameter class statement comprises a cloud platform type supported by the parameter corresponding to the parameter class, and when the multi-cloud management platform accesses a first cloud platform through a first interface, a first parameter corresponding to the first parameter class of the first interface and a first parameter class statement corresponding to the first parameter class are obtained; and filtering the first parameter to obtain a second parameter according to the cloud platform type of the first cloud platform and the first parameter class statement, and calling an adaptive parameter class corresponding to the first cloud platform according to the second parameter. The embodiment of the invention solves the technical problem that the interface of a multi-cloud management platform is difficult to develop and maintain because parameters supported by each cloud platform cannot be distinguished in the prior art.
Description
Technical Field
The embodiment of the application relates to the field of cloud platforms, in particular to a cloud platform parameter adaptation method and device, terminal equipment and a storage medium.
Background
With the rapid development of cloud computing technology, more and more manufacturers in China strive to lay out in the field of cloud platforms first. The cloud platform is also called a cloud computing platform, and is a service based on hardware resources and software resources, and provides computing, network and storage capabilities. Cloud computing platforms can be divided into 3 classes: the cloud computing platform comprises a storage type cloud platform taking data storage as a main part, a computing type cloud platform taking data processing as a main part and a comprehensive cloud computing platform taking computing and data storage processing into consideration. At present, a unified interface standard does not exist in the field of cloud computing, and with the increase of the number of manufacturers for manufacturing cloud platforms, how to adapt the interfaces of the cloud platforms of different manufacturers is a problem to be solved urgently by the current multi-cloud management platform. Most of interface parameters of the existing multi-cloud management platform adopt a union set of parameters of each cloud platform, however, the parameters supported by each cloud platform cannot be distinguished by adopting the method, so that the interface of the multi-cloud management platform is difficult to develop and maintain.
Disclosure of Invention
The embodiment of the invention provides a cloud platform parameter adaptation method, a cloud platform parameter adaptation device, terminal equipment and a storage medium, and solves the technical problem that in the prior art, the interface of a multi-cloud management platform is difficult to develop and maintain because parameters supported by each cloud platform cannot be distinguished.
In a first aspect, an embodiment of the present invention provides a cloud platform parameter adaptation method, including the following steps:
acquiring the cloud platform type of each cloud platform accessed to the multi-cloud management platform;
acquiring a parameter class statement corresponding to a parameter class of each interface according to each interface on the multi-cloud management platform, wherein the parameter class statement comprises a cloud platform type supported by a parameter corresponding to the parameter class, and the parameter class statement is a pre-annotated statement;
when the multi-cloud management platform accesses a first cloud platform through a first interface, acquiring a first parameter corresponding to a first parameter class of the first interface, and acquiring a first parameter class statement corresponding to the first parameter class;
and filtering the first parameter to obtain a second parameter according to the cloud platform type of the first cloud platform and the first parameter class statement, and calling an adaptive parameter class corresponding to the first cloud platform according to the second parameter.
Preferably, the specific process of acquiring the cloud platform type of each cloud platform accessing the multi-cloud management platform is as follows:
the method comprises the steps of obtaining interface calling authorization information of each cloud platform accessed to a multi-cloud management platform, wherein the interface calling authorization information comprises cloud platform types corresponding to the cloud platforms.
Preferably, the specific process of acquiring the interface call authorization information of each cloud platform accessing the multi-cloud management platform is as follows:
acquiring an authorization information ciphertext and a parameter signature MD5 value of each cloud platform accessed to the multi-cloud management platform through a multi-cloud platform filter;
and decrypting the authorization information ciphertext according to the parameter signature MD5 value to obtain the interface calling authorization information of each cloud platform.
Preferably, the specific process of obtaining, according to each interface on the multi-cloud management platform, the parameter class declaration corresponding to the parameter class of each interface is as follows:
determining an interface name of each interface according to each interface on the multi-cloud management platform;
acquiring a parameter class corresponding to each interface name;
and acquiring a parameter class declaration corresponding to the parameter class.
Preferably, after obtaining the parameter class corresponding to each interface name, before obtaining the parameter class declaration corresponding to each parameter class, the method further includes the following steps:
and injecting the parameter classes into a Spring container.
Preferably, the specific process of filtering the first parameter to obtain the second parameter according to the cloud platform type of the first cloud platform and the first parameter class declaration is as follows:
determining the cloud platform type supported by each first parameter according to the first parameter class statement, and putting the parameter name of the first parameter, which is not corresponding to the cloud platform type of the first cloud platform, of the cloud platform type supported in the first parameters into an exclusion array;
and filtering the first parameter according to the exclusion array to obtain a second parameter.
Preferably, the specific process of filtering the first parameter according to the ranking group to obtain the second parameter is as follows:
and deleting the first parameters matched with the parameter names in the exclusion array from the first parameters to obtain second parameters.
In a second aspect, an embodiment of the present invention provides a cloud platform parameter adaptation apparatus, including: the system comprises a type acquisition module, a statement acquisition module, a parameter acquisition module and a parameter filtering module;
the type acquisition module is used for acquiring the cloud platform type of each cloud platform accessed to the multi-cloud management platform;
the statement acquisition module is used for acquiring a parameter class statement corresponding to a parameter class of each interface according to each interface on the multi-cloud management platform, wherein the parameter class statement comprises a cloud platform type supported by a parameter corresponding to the parameter class, and the parameter class statement is a pre-annotated statement;
the parameter obtaining module is used for obtaining a first parameter corresponding to a first parameter class of a first interface and obtaining a first parameter class statement corresponding to the first parameter class when the multi-cloud management platform accesses the first cloud platform through the first interface;
the parameter filtering module is used for filtering the first parameter to obtain a second parameter according to the cloud platform type of the first cloud platform and the first parameter class statement, and calling an adaptive parameter class corresponding to the first cloud platform according to the second parameter.
In a third aspect, an embodiment of the present invention provides a terminal device, where the terminal device includes a processor and a memory;
the memory is used for storing a computer program and transmitting the computer program to the processor;
the processor is configured to execute a cloud platform parameter adaptation method according to instructions in the computer program according to the first aspect.
In a fourth aspect, embodiments of the present invention provide a storage medium storing computer-executable instructions, which when executed by a computer processor, are configured to perform a cloud platform parameter adaptation method as described in the first aspect.
In the foregoing, an embodiment of the present invention provides a cloud platform parameter adaptation method, an apparatus, a terminal device, and a storage medium, where the method includes the following steps: acquiring the cloud platform type of each cloud platform accessed to the multi-cloud management platform; acquiring a parameter class statement corresponding to a parameter class of each interface according to each interface on the multi-cloud management platform, wherein the parameter class statement comprises a cloud platform type supported by a parameter corresponding to the parameter class, and the parameter class statement is a pre-annotated statement; when the multi-cloud management platform accesses the first cloud platform through the first interface, acquiring a first parameter corresponding to a first parameter class of the first interface, and acquiring a first parameter class statement corresponding to the first parameter class; and filtering the first parameter to obtain a second parameter according to the cloud platform type of the first cloud platform and the first parameter class statement, and calling an adaptive parameter class corresponding to the first cloud platform according to the second parameter.
According to the embodiment of the invention, the parameter class statement is annotated in advance, and the cloud platform type supported by the parameter corresponding to each parameter class is determined in the parameter class statement, so that when a subsequent multi-cloud management platform accesses a first cloud platform through a first interface, only the first parameter class statement corresponding to the first parameter class needs to be obtained, and then the first parameter corresponding to the first parameter class of the first interface can be filtered according to the cloud platform type of the first cloud platform and the first parameter class statement to obtain the second parameter. According to the embodiment of the invention, even when the interface parameters are disordered due to the inconsistent parameters of a plurality of cloud manufacturers, the parameters corresponding to each cloud platform can be screened out, so that development and maintenance of the interface functions by developers are facilitated, the usability and readability of the interface of the multi-cloud platform are improved, and the technical problem that the interface of the multi-cloud management platform is difficult to develop and maintain due to the fact that the parameters supported by each cloud platform cannot be distinguished in the prior art is solved.
Drawings
Fig. 1 is a schematic flowchart of a cloud platform parameter adaptation method according to an embodiment of the present invention.
Fig. 2 is a schematic structural diagram of a cloud platform parameter adaptation device according to an embodiment of the present invention.
Fig. 3 is a schematic structural diagram of a terminal device according to an embodiment of the present invention.
Detailed Description
The following description and the annexed drawings set forth in detail certain illustrative embodiments of the application so as to enable those skilled in the art to practice them. The examples merely typify possible variations. Individual components and functions are optional unless explicitly required, and the sequence of operations may vary. Portions and features of some embodiments may be included in or substituted for those of others. The scope of the embodiments of the present application includes the full ambit of the claims, as well as all available equivalents of the claims. Embodiments may be referred to herein, individually or collectively, by the term "invention" merely for convenience and without intending to voluntarily limit the scope of this application to any single invention or inventive concept if more than one is in fact disclosed. Herein, relational terms such as first and second, and the like may be used solely to distinguish one entity or action from another entity or action without requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, or terminal apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed. The embodiments are described in a progressive manner, each embodiment focuses on differences from other embodiments, and the same and similar parts among the embodiments are referred to each other. For the structures, products and the like disclosed by the embodiments, the description is relatively simple because the structures, the products and the like correspond to the parts disclosed by the embodiments, and the relevant parts can be just described by referring to the method part.
Example one
As shown in fig. 1, fig. 1 is a flowchart of a cloud platform parameter adaptation method according to an embodiment of the present invention. The cloud platform parameter adaptation method provided by the embodiment of the invention can be executed by cloud platform parameter adaptation equipment, the cloud platform parameter adaptation equipment can be realized in a software and/or hardware mode, and the cloud platform parameter adaptation equipment can be composed of two or more physical entities or one physical entity. For example, the cloud platform parameter adaptation device can be a computer, an upper computer, a tablet and other devices. The method comprises the following steps:
Generally, a plurality of cloud platforms are connected to a multi-cloud management platform, and the multi-cloud management platform can access or manage the connected cloud platforms. In this embodiment, first, the cloud platform type of each cloud platform accessed to the multi-cloud management platform needs to be acquired, for example, the cloud platform a, the cloud platform B and the cloud platform C accessed to the multi-cloud management platform are included, the cloud platform type acquired from the cloud platform a is an ari public cloud, the cloud platform type acquired from the cloud platform B is an Tencent cloud, and the cloud platform type acquired from the cloud platform C is a Huacheng cloud.
On the basis of the above embodiment, the specific process of acquiring the cloud platform type of each cloud platform accessing the multi-cloud management platform is as follows:
the method comprises the steps of obtaining interface calling authorization information of each cloud platform accessed to the multi-cloud management platform, wherein the interface calling authorization information comprises cloud platform types corresponding to the cloud platforms.
It should be further explained that, in order to enable the multi-cloud management platform to access the cloud platforms, first, the interface call authorization information of each cloud platform needs to be acquired, and the multi-cloud management platform can access the corresponding cloud platform through different interfaces by calling the authorization information according to the interfaces. The interface calling authorization information comprises the cloud platform type of the corresponding cloud platform, so that the cloud platform type of the cloud platform can be obtained when the multi-cloud management platform accesses the cloud platform.
On the basis of the above embodiment, the obtaining of the interface call authorization information of each cloud platform accessing the multi-cloud management platform is performed by steps 1011 and 1012, and the specific process is as follows:
step 1011, obtaining the authorization information ciphertext and the parameter signature MD5 value of each cloud platform accessed to the multi-cloud management platform through the multi-cloud platform filter.
Firstly, the authorization information ciphertext and the parameter signature MD5 value of each cloud platform accessing the multi-cloud management platform are acquired through the cloud platform filter, and the cloud platform filter has the advantages that the authorization information ciphertext can be prevented from being leaked, and the parameter signature MD5 value can be prevented from being tampered.
And 1012, decrypting the authorization information ciphertext according to the parameter signature MD5 value to obtain the interface calling authorization information of each cloud platform.
After the authorization information ciphertext and the parameter signature MD5 value are obtained, the parameter signature MD5 value is used for decrypting the authorization information ciphertext to obtain interface calling authorization information. In one embodiment, the interface call authorization information includes a cloud platform type, a login ID, and a login password, and the format is as follows:
{"providerType":"xxxx","accessKeyId":"xxxx","accessKeySecret":"xxxxx"}
here, providerType represents a cloud platform type, accessKeyId represents a login ID, and accessKeySecret represents a login password.
102, acquiring a parameter class statement corresponding to each parameter class of each interface according to each interface on the multi-cloud management platform, wherein the parameter class statement comprises a cloud platform type supported by a parameter corresponding to the parameter class, and the parameter class statement is a pre-annotated statement.
After the type of each cloud platform is obtained, according to each interface on the multi-cloud management platform, a parameter class declaration corresponding to each parameter class of each interface is further obtained. It should be further noted that a plurality of interfaces are arranged on the multi-cloud management platform, the multi-cloud management platform accesses different cloud platforms through the interfaces, for example, virtual machine creation interfaces and the like, each interface corresponds to at least one parameter class, each parameter class corresponds to a parameter class declaration annotated in advance, and each parameter class declaration annotates a cloud platform type supported by a parameter corresponding to each parameter class. For example, in one embodiment, the parameter class a corresponds to two parameters, which are a parameter B and a parameter C, respectively, and then the cloud platform types supported by the parameter B and the parameter C are marked in the parameter class declaration of the parameter class a.
On the basis of the above embodiment, the specific process of obtaining the parameter class declaration corresponding to each parameter class of each interface according to each interface on the multi-cloud management platform is executed in step 1021-:
step 1021, determining an interface name of each interface according to each interface on the multi-cloud management platform.
First, an interface name of each interface on the multi-cloud management platform needs to be determined, for example, the interface name for creating the virtual machine interface is createestance.
Step 1022, obtain the parameter class corresponding to each interface name.
And after the interface name of each interface is obtained, further obtaining all the parameter classes corresponding to each interface name according to the interface name. Illustratively, for creating a virtual machine interface, the corresponding parameter class acquired according to the interface name createinstance.do is ecsccreateinsatancerequest.
And 1023, acquiring a parameter class statement corresponding to the parameter class.
After the parameter class of each interface is obtained, the parameter class declaration of each parameter class can be obtained. For example, in one embodiment, annotating a parameter class that creates a virtual machine interface results in a parameter class declaration as follows:
in this embodiment, the parameter class ecsventinattancerequest is annotated in the virtual machine creation interface, the parameter corresponding to the parameter class includes a regionID and a cpu, the cloud platform types supported by the regionID are ALIYUN _ PUBLIC (ariloc), TENCENT (tenceing cloud), HWCLOUD _ PUBLIC (wawter cloud), and azeure (amazon cloud), and the cloud platform type supported by the cpu is OpenStack.
In one embodiment, after obtaining the parameter class corresponding to each interface name, before obtaining the parameter class declaration corresponding to each parameter class, the method further comprises the following steps:
and injecting the parameter classes into the Spring containers.
In this embodiment, all the parameter classes are also injected into the Spring container, so that the Spring container can manage and configure all the parameter classes.
When the multi-cloud management platform accesses the first cloud platform through the first interface, a first parameter corresponding to a first parameter class of the first interface is obtained, and a first parameter class statement corresponding to the first parameter class is obtained. Illustratively, in one embodiment, when the multi-cloud management platform accesses the a1 cloud platform through the X interface, a first parameter corresponding to a parameter class for creating a virtual machine interface is obtained, and at least one of the first parameter exists, such as a parameter B and a parameter C. Meanwhile, a first parameter class declaration corresponding to the first parameter class needs to be obtained, where the first parameter class declaration is that the cloud platform types supported by the parameter B are a1, a2, and A3, and the cloud platform type supported by the parameter C is a 4.
And 104, filtering the first parameter to obtain a second parameter according to the cloud platform type of the first cloud platform and the first parameter class statement, and calling an adaptive parameter class corresponding to the first cloud platform according to the second parameter.
After the first parameter and the first parameter class declaration are obtained, the cloud platform type of the first cloud platform is determined, then, the first parameters which are different from the cloud platform type and the first cloud platform type and are supported in all the first parameters are filtered according to the cloud platform type of the first cloud platform and the first parameter declaration, so that second parameters needed by the first cloud platform are obtained, and an adaptive parameter class corresponding to the first cloud platform is called according to the second parameters to achieve the corresponding function.
On the basis of the above embodiment, the specific process of filtering the first parameter to obtain the second parameter according to the cloud platform type of the first cloud platform and the first parameter class declaration is executed in steps 1041 to 102, and includes:
step 1041, according to the first parameter class declaration, determining the cloud platform type supported by each first parameter, and putting the parameter name of the first parameter, which is not corresponding to the cloud platform type supported in the first parameter and the cloud platform type of the first cloud platform, into an exclusion array.
In this embodiment, first, the cloud platform type supported by each first parameter is determined according to the first parameter class declaration, and then, the parameter name of the first parameter, which is not corresponding to the cloud platform type of the first cloud platform, of the cloud platform types supported by all the first parameters is put into the exclusion array.
Illustratively, in one embodiment, when the multi-cloud management platform accesses the a1 cloud platform through the X interface, the first parameter includes a parameter B and a parameter C, the types of the cloud platforms supported by the parameter B are determined to be a1, a2 and A3 according to the first parameter declaration, and the type of the cloud platform supported by the parameter C is determined to be a 4. Then, of all the first parameters, the parameter name of the first parameter with the supported cloud platform type not corresponding to the a1 cloud platform is put into an exclusion array, that is, the parameter name of the parameter C is put into the exclusion array in all the first parameters.
1042, filtering the first parameter according to the ranking group to obtain a second parameter.
After the exclusion array is obtained, the first parameter can be filtered according to the parameter name in the exclusion array, so that the parameter required by the first cloud platform is obtained.
On the basis of the above embodiment, the specific process of filtering the first parameter according to the ranking group to obtain the second parameter is as follows:
and deleting the first parameters matched with the parameter names in the exclusion array from the first parameters to obtain second parameters.
In this embodiment, all the first parameters are traversed, and if the first parameters matched with the parameter names in the exclusion array exist, the first parameters are deleted, so that the second parameters are obtained. For example, if the parameter name in the exclusion array is the regionID, the first parameter matching the regionID is deleted from all the first parameters, resulting in the second parameter.
As described above, in the embodiment of the present invention, by annotating the parameter class declaration in advance, the cloud platform type supported by the parameter corresponding to each parameter class is determined in the parameter class declaration, so that when the subsequent multi-cloud management platform accesses the first cloud platform through the first interface, only the first parameter class declaration corresponding to the first parameter class needs to be obtained, and then the first parameter corresponding to the first parameter class of the first interface can be filtered according to the cloud platform type of the first cloud platform and the first parameter class declaration, so as to obtain the second parameter. According to the embodiment of the invention, even when the interface parameters are disordered due to the inconsistent parameters of a plurality of cloud manufacturers, the parameters corresponding to each cloud platform can be screened out, so that development and maintenance of the interface functions by developers are facilitated, the usability and readability of the interface of the multi-cloud platform are improved, and the technical problem that the interface of the multi-cloud management platform is difficult to develop and maintain due to the fact that the parameters supported by each cloud platform cannot be distinguished in the prior art is solved.
Example two
As shown in fig. 2, fig. 2 is a schematic structural diagram of a cloud platform parameter adaptation apparatus provided in an embodiment of the present invention, including: a type acquisition module 201, a statement acquisition module 202, a parameter acquisition module 203 and a parameter filtering module 204;
the type obtaining module 201 is configured to obtain a cloud platform type of each cloud platform accessing the multi-cloud management platform;
the declaration obtaining module 202 is configured to obtain, according to each interface on the multi-cloud management platform, a parameter class declaration corresponding to a parameter class of each interface, where the parameter class declaration includes a cloud platform type supported by a parameter corresponding to the parameter class, and the parameter class declaration is a declaration annotated in advance;
the parameter obtaining module 203 is configured to obtain a first parameter corresponding to a first parameter class of a first interface and obtain a first parameter class statement corresponding to the first parameter class when the multi-cloud management platform accesses the first cloud platform through the first interface;
the parameter filtering module 204 is configured to filter the first parameter to obtain a second parameter according to the cloud platform type of the first cloud platform and the first parameter class declaration, and call an adaptation parameter class corresponding to the first cloud platform according to the second parameter.
On the basis of the foregoing embodiment, the type obtaining module 201 is configured to obtain the cloud platform types of each cloud platform accessing the multi-cloud management platform specifically as follows:
the method and the device are used for obtaining interface calling authorization information of each cloud platform accessed to the multi-cloud management platform, wherein the interface calling authorization information comprises the cloud platform type of the corresponding cloud platform.
On the basis of the foregoing embodiment, the specific steps of the type obtaining module 201 being configured to obtain the interface call authorization information of each cloud platform accessing the multi-cloud management platform are as follows:
the system comprises a multi-cloud platform filter, a parameter signature MD5 and a management server, wherein the multi-cloud platform filter is used for acquiring an authorization information ciphertext and a parameter signature MD5 value of each cloud platform accessed to the multi-cloud management platform; and decrypting the authorization information ciphertext according to the parameter signature MD5 value to obtain the interface calling authorization information of each cloud platform.
On the basis of the foregoing embodiment, the declaration obtaining module 202 is configured to obtain, according to each interface on the multi-cloud management platform, a parameter class declaration corresponding to a parameter class of each interface, specifically:
the method comprises the steps of determining an interface name of each interface according to each interface on the multi-cloud management platform; acquiring a parameter class corresponding to each interface name; and acquiring a parameter class declaration corresponding to the parameter class.
On the basis of the foregoing embodiment, the declaration obtaining module 202 is configured to, after obtaining the parameter class corresponding to each interface name, and before obtaining the parameter class declaration corresponding to each parameter class, further:
and injecting the parameter classes into the Spring containers.
On the basis of the foregoing embodiment, the parameter filtering module 204 is configured to filter the first parameter according to the cloud platform type of the first cloud platform and the first parameter class declaration to obtain a second parameter, specifically:
the parameter name of the first parameter, which is not corresponding to the cloud platform type of the first cloud platform, is put into the exclusion array; and filtering the first parameter according to the ranking group to obtain a second parameter.
On the basis of the foregoing embodiment, the parameter filtering module 204 is configured to filter the first parameter according to the ranking group, and obtain the second parameter specifically as follows:
and deleting the first parameter matched with the parameter name in the exclusion array from the first parameters to obtain second parameters.
EXAMPLE III
The present embodiment further provides a terminal device, as shown in fig. 3, a terminal device 30, where the terminal device includes a processor 300 and a memory 301;
the memory 301 is used for storing a computer program 302 and transmitting the computer program 302 to the processor;
the processor 300 is configured to execute the steps in one cloud platform parameter adaptation method embodiment described above according to the instructions in the computer program 302.
Illustratively, the computer program 302 may be partitioned into one or more modules/units that are stored in the memory 301 and executed by the processor 300 to accomplish the present application. The one or more modules/units may be a series of computer program instruction segments capable of performing specific functions, which are used to describe the execution process of the computer program 302 in the terminal device 30.
The terminal device 30 may be a desktop computer, a notebook, a palm computer, a cloud server, or other computing devices. The terminal device 30 may include, but is not limited to, a processor 300 and a memory 301. Those skilled in the art will appreciate that fig. 3 is merely an example of the terminal device 30, and does not constitute a limitation of the terminal device 30, and may include more or less components than those shown, or combine some of the components, or different components, for example, the terminal device 30 may further include an input-output device, a network access device, a bus, etc.
The Processor 300 may be a Central Processing Unit (CPU), other general purpose Processor, a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), an off-the-shelf Programmable Gate Array (FPGA) or other Programmable logic device, discrete Gate or transistor logic, discrete hardware components, etc. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
The storage 301 may be an internal storage unit of the terminal device 30, such as a hard disk or a memory of the terminal device 30. The memory 301 may also be an external storage terminal device of the terminal device 30, such as a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card), and the like, which are provided on the terminal device 30. Further, the memory 301 may also include both an internal storage unit and an external storage device of the terminal device 30. The memory 301 is used for storing the computer program and other programs and data required by the terminal device 30. The memory 301 may also be used to temporarily store data that has been output or is to be output.
It is clear to those skilled in the art that, for convenience and brevity of description, the specific working processes of the above-described systems, apparatuses and units may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In the several embodiments provided in the present application, it should be understood that the disclosed system, apparatus and method may be implemented in other manners. For example, the above-described apparatus embodiments are merely illustrative, and for example, the division of the units is only one logical division, and other divisions may be realized in practice, for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, and can also be realized in a form of a software functional unit.
The integrated unit, if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: a U disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing computer programs.
Example four
Embodiments of the present invention also provide a storage medium containing computer-executable instructions, which when executed by a computer processor, are configured to perform a cloud platform parameter adaptation method, the method including the following steps:
acquiring the cloud platform type of each cloud platform accessed to the multi-cloud management platform;
acquiring a parameter class statement corresponding to a parameter class of each interface according to each interface on the multi-cloud management platform, wherein the parameter class statement comprises a cloud platform type supported by a parameter corresponding to the parameter class, and the parameter class statement is a pre-annotated statement;
when the multi-cloud management platform accesses a first cloud platform through a first interface, acquiring a first parameter corresponding to a first parameter class of the first interface, and acquiring a first parameter class statement corresponding to the first parameter class;
and filtering the first parameter to obtain a second parameter according to the cloud platform type of the first cloud platform and the first parameter class statement, and calling an adaptive parameter class corresponding to the first cloud platform according to the second parameter.
It should be noted that the foregoing is only a preferred embodiment of the present invention and the technical principles applied. Those skilled in the art will appreciate that the embodiments of the present invention are not limited to the specific embodiments described herein, and that various obvious changes, adaptations, and substitutions are possible, without departing from the scope of the embodiments of the present invention. Therefore, although the embodiments of the present invention have been described in more detail through the above embodiments, the embodiments of the present invention are not limited to the above embodiments, and many other equivalent embodiments may be included without departing from the concept of the embodiments of the present invention, and the scope of the embodiments of the present invention is determined by the scope of the appended claims.
Claims (10)
1. A cloud platform parameter adaptation method is characterized by comprising the following steps:
acquiring the cloud platform type of each cloud platform accessed to the multi-cloud management platform;
acquiring a parameter class statement corresponding to a parameter class of each interface according to each interface on the multi-cloud management platform, wherein the parameter class statement comprises a cloud platform type supported by a parameter corresponding to the parameter class, and the parameter class statement is a pre-annotated statement;
when the multi-cloud management platform accesses a first cloud platform through a first interface, acquiring a first parameter corresponding to a first parameter class of the first interface, and acquiring a first parameter class statement corresponding to the first parameter class;
and filtering the first parameter to obtain a second parameter according to the cloud platform type of the first cloud platform and the first parameter class statement, and calling an adaptive parameter class corresponding to the first cloud platform according to the second parameter.
2. The method according to claim 1, wherein the specific process of obtaining the cloud platform type of each cloud platform accessing the multi-cloud management platform comprises:
the method comprises the steps of obtaining interface calling authorization information of each cloud platform accessed to a multi-cloud management platform, wherein the interface calling authorization information comprises cloud platform types corresponding to the cloud platforms.
3. The method for adapting cloud platform parameters according to claim 2, wherein the specific process for acquiring the interface call authorization information of each cloud platform accessing the multi-cloud management platform is as follows:
acquiring an authorization information ciphertext and a parameter signature MD5 value of each cloud platform accessed to the multi-cloud management platform through a multi-cloud platform filter;
and decrypting the authorization information ciphertext according to the parameter signature MD5 value to obtain the interface calling authorization information of each cloud platform.
4. The method according to claim 1, wherein the specific process of obtaining, according to each interface on the multi-cloud management platform, the parameter class declaration corresponding to the parameter class of each interface is as follows:
determining an interface name of each interface according to each interface on the multi-cloud management platform;
acquiring a parameter class corresponding to each interface name;
and acquiring a parameter class declaration corresponding to the parameter class.
5. The method according to claim 4, wherein after obtaining the parameter class corresponding to each interface name, and before obtaining the parameter class declaration corresponding to each parameter class, the method further comprises the following steps:
and injecting the parameter classes into a Spring container.
6. The method according to claim 1, wherein the specific process of filtering the first parameter to obtain the second parameter according to the cloud platform type of the first cloud platform and the first parameter class declaration comprises:
determining the cloud platform type supported by each first parameter according to the first parameter class statement, and putting the parameter name of the first parameter, which is not corresponding to the cloud platform type of the first cloud platform, of the cloud platform type supported in the first parameters into an exclusion array;
and filtering the first parameter according to the exclusion array to obtain a second parameter.
7. The cloud platform parameter adaptation method according to claim 6, wherein the specific process of filtering the first parameter according to the ranking group to obtain the second parameter is as follows:
and deleting the first parameters matched with the parameter names in the exclusion array from the first parameters to obtain second parameters.
8. A cloud platform parameter adaptation device, comprising: the system comprises a type acquisition module, a statement acquisition module, a parameter acquisition module and a parameter filtering module;
the type acquisition module is used for acquiring the cloud platform type of each cloud platform accessed to the multi-cloud management platform;
the statement acquisition module is used for acquiring a parameter class statement corresponding to a parameter class of each interface according to each interface on the multi-cloud management platform, wherein the parameter class statement comprises a cloud platform type supported by a parameter corresponding to the parameter class, and the parameter class statement is a pre-annotated statement;
the parameter obtaining module is used for obtaining a first parameter corresponding to a first parameter class of a first interface and obtaining a first parameter class statement corresponding to the first parameter class when the multi-cloud management platform accesses the first cloud platform through the first interface;
the parameter filtering module is used for filtering the first parameter to obtain a second parameter according to the cloud platform type of the first cloud platform and the first parameter class statement, and calling an adaptive parameter class corresponding to the first cloud platform according to the second parameter.
9. A terminal device, characterized in that the terminal device comprises a processor and a memory;
the memory is used for storing a computer program and transmitting the computer program to the processor;
the processor is configured to execute a cloud platform parameter adaptation method according to any one of claims 1-7 according to instructions in the computer program.
10. A storage medium storing computer-executable instructions, which when executed by a computer processor, are configured to perform a cloud platform parameter adaptation method as claimed in any one of claims 1 to 7.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202111322770.4A CN114157662B (en) | 2021-11-09 | 2021-11-09 | Cloud platform parameter adaptation method, device, terminal equipment and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202111322770.4A CN114157662B (en) | 2021-11-09 | 2021-11-09 | Cloud platform parameter adaptation method, device, terminal equipment and storage medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN114157662A true CN114157662A (en) | 2022-03-08 |
CN114157662B CN114157662B (en) | 2023-08-29 |
Family
ID=80459797
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202111322770.4A Active CN114157662B (en) | 2021-11-09 | 2021-11-09 | Cloud platform parameter adaptation method, device, terminal equipment and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN114157662B (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111858101A (en) * | 2020-07-28 | 2020-10-30 | 平安医疗健康管理股份有限公司 | Cloud architecture system-oriented adaptation method, device, equipment and storage medium |
Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20120311571A1 (en) * | 2011-05-31 | 2012-12-06 | Morgan Christopher Edwin | Systems and methods for tracking cloud installation information using cloud-aware kernel of operating system |
CN107493310A (en) * | 2016-06-13 | 2017-12-19 | 腾讯科技(深圳)有限公司 | A kind of cloud resource processing method and cloud management platform |
CN107659624A (en) * | 2017-09-06 | 2018-02-02 | 国云科技股份有限公司 | A kind of isomery cloud management system and method suitable for cloud computing |
CN108449418A (en) * | 2018-03-29 | 2018-08-24 | 新华三云计算技术有限公司 | A kind of mixed cloud platform management system and method |
CN110213092A (en) * | 2019-05-21 | 2019-09-06 | 深信服科技股份有限公司 | Resource access method, platform management equipment, storage medium and the device of mixed cloud |
US20210084108A1 (en) * | 2018-05-31 | 2021-03-18 | Huawei Technologies Co., Ltd. | Data processing method, multi-cloud management system, and related device |
-
2021
- 2021-11-09 CN CN202111322770.4A patent/CN114157662B/en active Active
Patent Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20120311571A1 (en) * | 2011-05-31 | 2012-12-06 | Morgan Christopher Edwin | Systems and methods for tracking cloud installation information using cloud-aware kernel of operating system |
CN107493310A (en) * | 2016-06-13 | 2017-12-19 | 腾讯科技(深圳)有限公司 | A kind of cloud resource processing method and cloud management platform |
CN107659624A (en) * | 2017-09-06 | 2018-02-02 | 国云科技股份有限公司 | A kind of isomery cloud management system and method suitable for cloud computing |
CN108449418A (en) * | 2018-03-29 | 2018-08-24 | 新华三云计算技术有限公司 | A kind of mixed cloud platform management system and method |
US20210084108A1 (en) * | 2018-05-31 | 2021-03-18 | Huawei Technologies Co., Ltd. | Data processing method, multi-cloud management system, and related device |
CN110213092A (en) * | 2019-05-21 | 2019-09-06 | 深信服科技股份有限公司 | Resource access method, platform management equipment, storage medium and the device of mixed cloud |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111858101A (en) * | 2020-07-28 | 2020-10-30 | 平安医疗健康管理股份有限公司 | Cloud architecture system-oriented adaptation method, device, equipment and storage medium |
CN111858101B (en) * | 2020-07-28 | 2023-05-26 | 深圳平安医疗健康科技服务有限公司 | Cloud architecture system-oriented adaptation method, device, equipment and storage medium |
Also Published As
Publication number | Publication date |
---|---|
CN114157662B (en) | 2023-08-29 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN108268253B (en) | Interface code generation method and terminal equipment | |
CN110601880B (en) | Cloud platform, service processing method, command interface and computer equipment | |
CN107798038B (en) | Data response method and data response equipment | |
CN113489713B (en) | Network attack detection method, device, equipment and storage medium | |
WO2019109518A1 (en) | Data list uploading method and terminal thereof | |
WO2019051948A1 (en) | Method, apparatus, server, and storage medium for processing monitoring data | |
CN112035471B (en) | Transaction processing method and computer equipment | |
CN114531477B (en) | Method and device for configuring functional components, computer equipment and storage medium | |
CN107656750A (en) | Update of plug-in method and device | |
CN111464513A (en) | Data detection method, device, server and storage medium | |
CN111767270A (en) | Data migration method, device, server and storage medium | |
CN111338716A (en) | Data processing method and device based on rule engine and terminal equipment | |
CN114157662B (en) | Cloud platform parameter adaptation method, device, terminal equipment and storage medium | |
CN110851334A (en) | Flow statistical method, electronic device, system and medium | |
CN110855525A (en) | Flow statistical method, electronic device, system and medium | |
CN109032685A (en) | A kind of method and terminal accelerating Android system starting | |
CN117707478A (en) | Demand management method, device, equipment and storage medium | |
CN111046393B (en) | Vulnerability information uploading method and device, terminal equipment and storage medium | |
CN110503504B (en) | Information identification method, device and equipment of network product | |
CN112306507A (en) | Picture resource processing method, device, terminal and storage medium | |
CN115098297B (en) | Consistent snapshot generation method and system for cloud primary storage data volume | |
US20220327242A1 (en) | Data management method and apparatus | |
CN110874365A (en) | Information query method and related equipment thereof | |
CN110362294A (en) | Development task executes method, apparatus, electronic equipment and storage medium | |
CN114124524A (en) | Cloud platform permission setting method and device, terminal equipment and storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |