Disclosure of Invention
In view of the foregoing, it is necessary to provide a hybrid cloud system, a hybrid cloud disk application method, and a data storage method that can reduce the difficulty of hybrid cloud storage development.
A hybrid cloud system, the system comprising:
the Kubernetes container service module is used for managing Kubernetes clusters to acquire cloud disk application requests;
the mixed cloud SCI plug-in is used for sending an API request to the mixed cloud pipe module according to the cloud disk application request;
and the mixed cloud pipe module is used for acquiring the cloud manufacturer API interface according to the cloud manufacturer identifier in the API request, and applying for and creating a cloud disk according to the cloud manufacturer API interface.
In one embodiment, the hybrid cloud system further comprises: the Iaas service modules of the cloud manufacturers are used for providing management cloud resources; the hybrid cloud management module is further configured to apply for releasing management cloud resources to the Iaas service module; the container cloud service module is used for applying the management cloud resources to the hybrid cloud pipe module, the management cloud resources are used for creating Kubernetes clusters, the Kubernetes clusters run on the Kubernetes container service module of each cloud manufacturer, and the Kubernetes clusters are managed through the Kubernetes container service module.
In one embodiment, the hybrid cloud CSI plugin realizes creation, mounting and deletion of a cloud disk by calling an interface of the hybrid cloud tube module.
In one embodiment, the hybrid cloud pipe module is configured to manage cloud resources of a plurality of cloud manufacturers and provide a unified API interface for a user terminal.
In one embodiment, the container cloud service module is further configured to delete the kubernetes cluster.
A hybrid cloud disk application method, the method comprising:
the method comprises the steps that a kubernetes cluster managed by a container cloud service module obtains a cloud disk application request;
the mixed cloud SCI plug-in monitors a cloud disk application request of the container cloud service module, and sends an API request to the mixed cloud pipe module according to the cloud disk application request;
and the mixed cloud management module acquires the cloud manufacturer API interface according to the cloud manufacturer identifier in the API request, and applies for and creates a cloud disk according to the cloud manufacturer API interface.
In one embodiment, the obtaining, by the kubernetes cluster managed by the container cloud service module, a cloud disk application request includes: receiving an initial cloud disk application request sent by a user terminal; the kubernetes cluster managed by the container cloud service module defines a persistent volume statement according to the initial cloud disk application request and generates a cloud disk application request; the persistent volume declaration is used for describing a cloud disk to be applied in the initial cloud disk application request.
A method of data storage, the method comprising:
inputting a persistent volume statement into a container group running in a kubernetes cluster, and generating a data storage request; the Kubernetes clusters run on a Kubernetes container service module of each cloud manufacturer;
the mixed cloud SCI plug-in monitors a data storage request of the container cloud service module, calls an API (application program interface) of the mixed cloud pipe module according to the data storage request, and loads a cloud disk on an Iaas service module corresponding to a cloud manufacturer identifier in the data storage request through the API of the mixed cloud pipe module;
kubernetes cluster controls the container group to run on the Iaas service module;
and the mixed cloud SCI plug-in loads a cloud disk into the container group through the mixed cloud pipe module API interface, and writes data in the data storage request into the cloud disk through the container group.
A computer device comprising a memory storing a computer program and a processor which when executing the computer program performs the steps of:
the method comprises the steps that a kubernetes cluster managed by a container cloud service module obtains a cloud disk application request;
the mixed cloud SCI plug-in monitors a cloud disk application request of the container cloud service module, and sends an API request to the mixed cloud pipe module according to the cloud disk application request;
and the mixed cloud management module acquires the cloud manufacturer API interface according to the cloud manufacturer identifier in the API request, and applies for and creates a cloud disk according to the cloud manufacturer API interface.
A computer readable storage medium having stored thereon a computer program which when executed by a processor performs the steps of:
the method comprises the steps that a kubernetes cluster managed by a container cloud service module obtains a cloud disk application request;
the mixed cloud SCI plug-in monitors a cloud disk application request of the container cloud service module, and sends an API request to the mixed cloud pipe module according to the cloud disk application request;
and the mixed cloud management module acquires the cloud manufacturer API interface according to the cloud manufacturer identifier in the API request, and applies for and creates a cloud disk according to the cloud manufacturer API interface.
According to the hybrid cloud system, the hybrid cloud disk application method and the data storage method, the hybrid cloud SCI plug-in sends the API request to the hybrid cloud pipe module to apply for the API interfaces of all cloud manufacturers to create the cloud disk, the hybrid cloud SCI plug-in can shield the differences of the API interfaces of all cloud manufacturers and provide uniform API interfaces for users to realize hybrid cloud storage, the hybrid cloud SCI plug-in can be installed on kubernetes clusters of any cloud manufacturer, and when the hybrid cloud system is developed, only one hybrid cloud SCI plug-in needs to be developed, cloud disk services of all cloud manufacturers can be used, and the development efficiency of the system is improved.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more apparent, the present application will be further described in detail with reference to the accompanying drawings and examples. It should be understood that the specific embodiments described herein are for purposes of illustration only and are not intended to limit the present application.
As shown in fig. 1, a schematic structural diagram of a hybrid cloud system in the prior art is provided, in the present hybrid cloud system, in the process of implementing cloud storage of data by each cloud manufacturer, kubernetes clusters are basically created by directly calling IAAS layer services of each cloud manufacturer, or a catalog for creating and managing kubernetes clusters is directly called by directly calling a kubernetes cluster creation interface of each cloud manufacturer, or an interface application resource creation cluster of a hybrid transport pipe is called. For the CSI plugin, each cloud vendor provides its own CSI plugin to ensure normal creation of kubernetes. And the parameters of the CSI plug-in of each cloud manufacturer are different, the CSI plug-in and the usage of each cloud manufacturer are required to be known when the kubernetes cluster is installed in the hybrid cloud system, and some cloud manufacturers do not provide the CSI plug-in to the outside and the hybrid cloud system is required to be developed.
In one embodiment, kubernetes is an open source for managing containerized applications on multiple hosts in a cloud platform, the goal of Kubernetes is to make deploying containerized applications simple and efficient, and Kubernetes provides a mechanism for application deployment, planning, updating, and maintenance; the CSI plug-in is a container storage interface, and the kubernetes are conveniently connected to the kubernetes by all cloud manufacturers through the standard container storage interface introduced by the kubernetes, so that the kubernetes are operated by all cloud service providers; the hybrid cloud management (hybrid cloud management module) is responsible for uniformly managing various cloud services of each cloud manufacturer, including creating a virtual machine, creating a network, creating a cloud disk and the like; the container cloud service (container cloud service module) can create, manage and delete kubernetes clusters in various cloud factories based on the hybrid cloud management, and the container cloud service provides unified life cycle management of the kubernetes clusters.
In one embodiment, as shown in fig. 2, there is provided a hybrid cloud system comprising: the Kubernetes container service module is used for managing Kubernetes clusters to acquire cloud disk application requests; the mixed cloud SCI plug-in is used for sending an API request to the mixed cloud pipe module according to the cloud disk application request; and the mixed cloud pipe module is used for acquiring the cloud manufacturer API interface according to the cloud manufacturer identifier in the API request, and applying for and creating a cloud disk according to the cloud manufacturer API interface.
The user terminal sends a cloud disk application request to the Kubernetes cluster through the Kubernetes container service module, wherein the cloud disk application request comprises a cloud manufacturer identifier, a cloud disk size and the like. After monitoring a cloud disk application request in the kubernetes cluster, the hybrid cloud SCI plug-in applies an API interface to the hybrid cloud pipe for creating a cloud disk. In fig. 2, the Kubernetes container service module and the hybrid cloud pipe module omit the module two words.
In the hybrid cloud system, the mixed cloud SCI plug-in unit sends the API request to the hybrid cloud pipe module to apply for the API interfaces of all cloud manufacturers to create the cloud disk, the mixed cloud SCI plug-in unit can shield the differences of the API interfaces of all cloud manufacturers, and provide a unified API interface for users to realize hybrid cloud storage, and the mixed cloud SCI plug-in unit can be installed on kubernetes clusters of any cloud manufacturer.
In one embodiment, the hybrid cloud system further comprises: the Iaas service modules of the cloud manufacturers are used for providing management cloud resources; the hybrid cloud management module is further configured to apply for releasing management cloud resources to the Iaas service module; the container cloud service module is used for applying the management cloud resources to the hybrid cloud pipe module, the management cloud resources are used for creating Kubernetes clusters, the Kubernetes clusters run on the Kubernetes container service module of each cloud manufacturer, and the Kubernetes clusters are managed through the Kubernetes container service module.
Wherein the Iaas (Infrastructure as a Service) service module is an infrastructure service module. In fig. 2, the Iaas service module, the hybrid cloud management module, the container cloud service module, and the Kubernetes container service module omit the module two words.
In one embodiment, the hybrid cloud CSI plugin realizes creation, mounting and deletion of a cloud disk by calling an interface of the hybrid cloud tube module.
In one embodiment, the hybrid cloud pipe module is configured to manage cloud resources of a plurality of cloud manufacturers and provide a unified API interface for a user terminal.
In one embodiment, the container cloud service module is further configured to delete the kubernetes cluster.
In one embodiment, as shown in fig. 3, there is provided a hybrid cloud disk application method, the method including:
s310, a kubernetes cluster managed by the container cloud service module acquires a cloud disk application request.
S320, the mixed cloud SCI plug-in monitors a cloud disk application request of the container cloud service module, and sends an API request to the mixed cloud pipe module according to the cloud disk application request.
S330, the hybrid cloud management module obtains the cloud manufacturer API interface according to the cloud manufacturer identifier in the API request, and applies for and creates a cloud disk according to the cloud manufacturer API interface.
In one embodiment, the obtaining, by the kubernetes cluster managed by the container cloud service module, a cloud disk application request includes: receiving an initial cloud disk application request sent by a user terminal; the kubernetes cluster managed by the container cloud service module defines a persistent volume statement according to the initial cloud disk application request and generates a cloud disk application request; the persistent volume declaration is used for describing a cloud disk to be applied in the initial cloud disk application request. The user terminal comprises a mobile phone terminal, a computer terminal and the like.
In one embodiment, as shown in fig. 4, there is provided a data storage method, wherein the method includes:
s410, inputting a persistent volume statement into a container group running in a kubernetes cluster, and generating a data storage request; the Kubernetes cluster runs on a Kubernetes container service module of each cloud manufacturer.
S420, a hybrid cloud SCI plug-in monitors a data storage request of the container cloud service module, calls a hybrid cloud pipe module API interface according to the data storage request, and loads a cloud disk on an Iaas service module corresponding to a cloud manufacturer identifier in the data storage request through the hybrid cloud pipe module API interface;
s430, controlling the container group to run on the Iaas service module by using a kubernetes cluster;
s440, the hybrid cloud SCI plug-in loads a cloud disk into the container group through the API interface of the hybrid cloud pipe module, and writes data in the data storage request into the cloud disk through the container group.
The container group (POD) is a container instance running in Kubernetes, and a user can write a program of the user and run in Kubernetes after the container is containerized. A persistent volume declaration (PVC) is a declaration stored by a user that consumes Persistent Volume (PV) resources that can request specific storage space and access patterns; for a user actually using storage, the storage implementation details of the bottom layer do not need to be concerned, and only the persistent volume declaration needs to be directly used.
It should be understood that, although the steps in the flowcharts of fig. 3-4 are shown in order as indicated by the arrows, these steps are not necessarily performed in order as indicated by the arrows. The steps are not strictly limited to the order of execution unless explicitly recited herein, and the steps may be executed in other orders. Moreover, at least some of the steps in fig. 3-4 may include multiple steps or stages that are not necessarily performed at the same time, but may be performed at different times, nor does the order in which the steps or stages are performed necessarily performed in sequence, but may be performed alternately or alternately with at least a portion of the steps or stages in other steps or other steps.
For specific limitations of the hybrid cloud disk application method and the data storage method, reference may be made to the above limitation of the hybrid cloud system, and no further description is given here. The various modules in the hybrid cloud system described above may be implemented in whole or in part by software, hardware, and combinations thereof. The above modules may be embedded in hardware or may be independent of a processor in the computer device, or may be stored in software in a memory in the computer device, so that the processor may call and execute operations corresponding to the above modules.
In one embodiment, a computer device is provided, which may be a server, the internal structure of which may be as shown in fig. 5. The computer device includes a processor, a memory, and a network interface connected by a system bus. Wherein the processor of the computer device is configured to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, computer programs, and a database. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage media. The network interface of the computer device is used for communicating with an external terminal through a network connection. The computer program, when executed by a processor, implements a hybrid cloud disk application method or a data storage method.
It will be appreciated by those skilled in the art that the structure shown in fig. 5 is merely a block diagram of some of the structures associated with the present application and is not limiting of the computer device to which the present application may be applied, and that a particular computer device may include more or fewer components than shown, or may combine certain components, or have a different arrangement of components.
In an embodiment, there is also provided a computer device comprising a memory and a processor, the memory having stored therein a computer program, the processor implementing the steps of the method embodiments described above when the computer program is executed.
In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored which, when executed by a processor, carries out the steps of the method embodiments described above.
Those skilled in the art will appreciate that implementing all or part of the above described methods may be accomplished by way of a computer program stored on a non-transitory computer readable storage medium, which when executed, may comprise the steps of the embodiments of the methods described above. Any reference to memory, storage, database, or other medium used in embodiments provided herein may include at least one of non-volatile and volatile memory. The nonvolatile Memory may include Read-Only Memory (ROM), magnetic tape, floppy disk, flash Memory, optical Memory, or the like. Volatile memory can include random access memory (Random Access Memory, RAM) or external cache memory. By way of illustration, and not limitation, RAM can be in the form of a variety of forms, such as static random access memory (Static Random Access Memory, SRAM) or dynamic random access memory (Dynamic Random Access Memory, DRAM), and the like.
The technical features of the above embodiments may be arbitrarily combined, and all possible combinations of the technical features in the above embodiments are not described for brevity of description, however, as long as there is no contradiction between the combinations of the technical features, they should be considered as the scope of the description.
The above examples merely represent a few embodiments of the present application, which are described in more detail and are not to be construed as limiting the scope of the invention. It should be noted that it would be apparent to those skilled in the art that various modifications and improvements could be made without departing from the spirit of the present application, which would be within the scope of the present application. Accordingly, the scope of protection of the present application is to be determined by the claims appended hereto.