CN112286904A - Cluster migration method and device and storage medium - Google Patents

Cluster migration method and device and storage medium Download PDF

Info

Publication number
CN112286904A
CN112286904A CN202011064011.8A CN202011064011A CN112286904A CN 112286904 A CN112286904 A CN 112286904A CN 202011064011 A CN202011064011 A CN 202011064011A CN 112286904 A CN112286904 A CN 112286904A
Authority
CN
China
Prior art keywords
cluster
instruction
sending
message
permission
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202011064011.8A
Other languages
Chinese (zh)
Inventor
石鹏
宋磊
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Dami Technology Co Ltd
Original Assignee
Beijing Dami Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Dami Technology Co Ltd filed Critical Beijing Dami Technology Co Ltd
Priority to CN202011064011.8A priority Critical patent/CN112286904A/en
Publication of CN112286904A publication Critical patent/CN112286904A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/21Design, administration or maintenance of databases
    • G06F16/214Database migration support
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/27Replication, distribution or synchronisation of data between databases or within a distributed database system; Distributed database system architectures therefor
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/60Protecting data
    • G06F21/62Protecting access to data via a platform, e.g. using keys or access control rules
    • G06F21/6218Protecting access to data via a platform, e.g. using keys or access control rules to a system of files or objects, e.g. local or distributed file system or database

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • General Physics & Mathematics (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Computing Systems (AREA)
  • Health & Medical Sciences (AREA)
  • Bioethics (AREA)
  • General Health & Medical Sciences (AREA)
  • Computer Hardware Design (AREA)
  • Computer Security & Cryptography (AREA)
  • Software Systems (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The application discloses a cluster migration method, a device and a storage medium, wherein the cluster migration method comprises the following steps: sending a first instruction to a user side, wherein the first instruction is used for indicating the user to read messages of a first cluster and a second cluster at the same time; the second cluster is a cluster created based on the first cluster; changing the authority of the second cluster from unreadable to writable to readable and writable based on the configuration information of the second cluster; and sending a second instruction to a server, wherein the second instruction is used for instructing the server to stop writing the message into the first cluster and start writing the message into the first cluster. According to the scheme, the configuration automation is realized, the manual operation and maintenance cost is greatly reduced, the stability risk possibly brought by manual operation is avoided, the message migration process basically has no perception on the service, synchronous data is not needed, and the message loss caused by data migration from the original cluster to the target cluster is avoided.

Description

Cluster migration method and device and storage medium
Technical Field
The present application relates to the field of cluster migration technologies, and in particular, to a cluster migration method, an apparatus, and a storage medium.
Background
Clusters may be migrated for some service needs, e.g., clusters that originally used the ali room now need to be migrated to the Tencent room. The existing solutions at present are: firstly, a cluster is newly built, then data in the original cluster is synchronized to the new cluster by using a data synchronization tool such as a mirror, and then the flow is cut off in a low peak period. However, the above solution requires more manual operations, increases the stability risk that the manual operations may bring, and the user using the service during the low peak period may obviously perceive the short interruption of the service. Meanwhile, when mirror synchronous data is adopted, messages may be lost if the network is unstable.
Disclosure of Invention
In order to solve the foregoing problems, embodiments of the present application provide a cluster migration method, apparatus, and storage medium.
In a first aspect, an embodiment of the present application provides a cluster migration method, including the following steps:
sending a first instruction to a user side, wherein the first instruction is used for indicating the user to read messages of a first cluster and a second cluster at the same time; the second cluster is a cluster created based on the first cluster;
changing the authority of the second cluster from unreadable to writable to readable and writable based on the configuration information of the second cluster;
and sending a second instruction to a server, wherein the second instruction is used for instructing the server to stop writing the message into the first cluster and start writing the message into the first cluster.
Optionally, the sending a second instruction to a server, where the second instruction is used to instruct the server to stop writing a message to the first cluster and start writing a message to the second cluster, and the method further includes:
sending a second permission modification instruction to the first cluster, wherein the second permission modification instruction is used for instructing the first cluster to change the permission from read-write to read-only.
Optionally, after sending a second permission modification instruction to the first cluster, the second permission modification instruction being configured to instruct the first cluster to change the permission from read-write to read-only, the method further includes:
and after the user side finishes reading all the messages of the first cluster, sending a third permission modification instruction to the first cluster, wherein the third permission modification instruction is used for indicating the first cluster to change the permission from read-only to unreadable.
Optionally, after the user end finishes reading all the messages of the first cluster, sending a third permission modification instruction to the first cluster, where the third permission modification instruction is used to instruct the first cluster to change the permission from read-only to unreadable, the method further includes:
and sending a third instruction to the user side, wherein the third instruction is used for indicating the user side to stop reading the message from the first cluster.
Optionally, the sending a third instruction to the user side, where the third instruction is used to instruct the user side to stop reading the message to the first cluster, further includes:
and generating migration completion reminding information, and sending the migration completion reminding information to a user terminal of a preset manager.
Optionally, after creating the second cluster based on the first cluster, before sending the first instruction to the user side, the method further includes:
creating a second cluster and acquiring configuration information of the first cluster;
creating the configuration information of the first cluster in the second cluster.
Optionally, the changing, based on the configuration information of the second cluster, the permission of the second cluster from unreadable to writable to readable to writable includes:
and sending a first permission modification instruction to the second cluster, wherein the first permission modification instruction is used for indicating the second cluster to change the permission from unreadable to writable to readable and writable.
In a second aspect, an embodiment of the present application provides a cluster migration apparatus, including:
the first instruction sending module is used for sending a first instruction to a user side after a second cluster is created based on a first cluster, wherein the first instruction is used for indicating the user side to read messages of the first cluster and the second cluster at the same time;
the first permission modification module is used for changing the permission of the second cluster from unreadable to writable to readable and writable based on the configuration information of the second cluster;
and the second instruction sending module is used for sending a second instruction to the server, wherein the second instruction is used for indicating the server to stop writing the message into the first cluster and start writing the message into the second cluster.
In a third aspect, an embodiment of the present application provides a cluster migration apparatus, including a memory, a processor, and a computer program stored on the memory and executable on the processor, where the processor implements the steps of any one of the above methods when executing the computer program.
In a fourth aspect, the present application provides a storage medium having a computer program stored thereon, where the computer program is executed by a processor to implement the steps of any one of the above methods.
In one or more embodiments of the present application, a second cluster is created based on a first cluster, configuration information of the first cluster is obtained, and the configuration information is created in the second cluster; sending a first instruction to a consumer, the first instruction being used to instruct the consumer to read messages of the first cluster and the second cluster simultaneously; changing the authority of the second cluster from being unreadable and writable to being readable and writable based on the configuration information; sending a second instruction to a producer, wherein the second instruction is used for instructing the producer to stop writing messages into the first cluster and start writing messages into the second cluster; and after the producer stops writing the message into the first cluster and starts writing the message into the second cluster, the permission of the first cluster is changed from read-write to read-only based on the configuration information. In the cluster migration scheme, the management platform firstly creates and configures a second cluster which is related to the first cluster and has the same configuration, then a consumer subscribes the first cluster and the second cluster at the same time, the authority of the second cluster is changed into readable and writable, the consumer can read information from the first cluster and also can read information from the second cluster, and then a producer changes the authority of the first cluster into read-only after changing the first cluster into the second cluster, so that the configuration automation is realized, the manual operation and maintenance cost is greatly reduced, the stability risk possibly brought by manual operation is avoided, the service is basically not sensed in the message migration process, synchronous data is not needed, and the condition that the information is lost due to data migration from the original cluster to a target cluster is avoided.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed to be used in the embodiments will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and it is obvious for those skilled in the art to obtain other drawings without creative efforts.
Fig. 1 is a schematic architecture diagram of a cluster migration system according to an embodiment of the present application;
fig. 2 is a schematic flowchart of a cluster migration method according to an embodiment of the present application;
fig. 3 is a schematic flowchart of another cluster migration method according to an embodiment of the present application;
fig. 4 is a schematic structural diagram of a cluster migration apparatus according to an embodiment of the present application;
fig. 5 is a schematic structural diagram of a cluster migration apparatus according to an embodiment of the present application.
Detailed Description
The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application.
In the following description, the terms "first" and "second" are used for descriptive purposes only and are not intended to indicate or imply relative importance. The following description provides embodiments of the present application, where different embodiments may be substituted or combined, and thus the present application is intended to include all possible combinations of the same and/or different embodiments described. Thus, if one embodiment includes feature A, B, C and another embodiment includes feature B, D, then this application should also be considered to include an embodiment that includes one or more of all other possible combinations of A, B, C, D, even though this embodiment may not be explicitly recited in text below.
The following description provides examples, and does not limit the scope, applicability, or examples set forth in the claims. Changes may be made in the function and arrangement of elements described without departing from the scope of the disclosure. Various examples may omit, substitute, or add various procedures or components as appropriate. For example, the described methods may be performed in an order different than the order described, and various steps may be added, omitted, or combined. Furthermore, features described with respect to some examples may be combined into other examples.
It should be noted that kafka is a message system based on publish and subscribe. It is commonly referred to as a "distributed commit log" or "distributed streaming platform". It is characterized by the ability to provide high throughput for both distribution and subscription. Kafka can produce about 25 thousand messages per second (50MB) and process 55 thousand messages per second (110 MB). Whereas kafka generally consists of three parts: the kafka cluster comprises a kafka producer (producer, i.e. a generator of a message), a kafka cluster and a kafka consumer (consumer, i.e. a consumer of the message), wherein the kafka producer is responsible for writing the message into the kafka cluster, one or more brokers (i.e. caching agents) are contained in the kafka cluster, and one or more servers in the kafka cluster are collectively called a borker), and the kafka consumer is responsible for reading the message written in the kafka cluster and consuming the message. The examples of the present application will be explained by taking kafka as an example.
Referring to fig. 1, fig. 1 is a schematic structural diagram of a cluster migration system according to an embodiment of the present disclosure.
As shown in fig. 1, the cluster migration system may include a management platform 101, a producer 102, a consumer 103, a first cluster 104, and a second cluster 105.
A cluster may have multiple servers, and one server may be regarded as a spoke, i.e. the first cluster 104 and the second cluster 105 may be a server group integrating multiple servers. Wherein, the topic related configuration and authority of the cluster can be changed only after receiving the instruction sent by the management platform 101.
The producer 102 is a message producer, and is a client that sends a message to a broker in the cluster, and may specifically be a server on which the producer client is mounted. The producer 102 can send a message to the already associated cluster, but the producer 102 can only change its associated object after receiving the instruction sent by the management platform 101.
The consumer 103 is a message consumer, and is a client that fetches a message from a browser in the cluster, and may specifically be a user terminal on which the consumer client is mounted. The consumer 103 can receive messages to the already subscribed clusters, but the consumer 103 can change the objects to which it subscribes only after receiving instructions sent by the management platform 101.
For example, when a teacher wants to send a red packet to students in a class group, a terminal used by the teacher to send the red packet is the producer 102, a red packet message is sent to a cluster corresponding to the cluster provided with the red packet theme, a terminal used by the students to receive the red packet is the consumer 103, and the consumer 103 can obtain the red packet message sent by the teacher from the cluster provided with the red packet theme to complete the pickup of the red packet.
The management platform 101 is a management system responsible for the whole cluster migration workflow, and may send instructions to the producer 102, the consumer 103, the first cluster 104, and the second cluster 105 through communication links, so as to implement functions such as sending a message object to the producer 102, changing a message object subscribed by the consumer 103, and modifying topic rights in a cluster, where the management platform 101 may be a server loaded with management system software.
It should be noted that, one or more producers 102 and/or consumers 103 may be provided, the number of the producers 102 and/or consumers 103 in the cluster migration system shown in fig. 1 is only an example, and in a specific implementation, the cluster migration system may include any number of the producers 102 and/or consumers 103, which is not limited in this application.
Referring to fig. 2, fig. 2 is a schematic flowchart of a cluster migration method provided in an embodiment of the present application, where in the embodiment of the present application, the method includes:
s201, sending a first instruction to a user side, wherein the first instruction is used for instructing the user to read messages of a first cluster and a second cluster at the same time, and the second cluster is a cluster created based on the first cluster.
In this embodiment of the present application, after the second cluster is created and configured, it is not associated with any producer or consumer at this moment, that is, no producer writes a message into the second cluster, and no consumer reads or writes a message into the second cluster. The management platform sends a first instruction to the consumer, the consumer subscribes to the second cluster after receiving the first instruction, and the consumer can subscribe to the messages of the first cluster and the second cluster simultaneously after receiving the first instruction because the consumer previously subscribes to the first cluster.
S202, changing the authority of the second cluster from non-readable and writable to readable and writable based on the configuration information of the second cluster.
In the embodiment of the present application, in an initial state, a topic authority of a second cluster previously created via a management platform is in a non-readable and writable state, and under the authority, even if a consumer subscribes to the second cluster, the consumer cannot read a message in the second cluster. Therefore, the management platform changes the topic authority of the second cluster from unreadable to writable to readable and writable based on the topic configuration information configured by the second cluster.
In an implementation manner, step S202 specifically includes:
and sending a first permission modification instruction to the second cluster, wherein the first permission modification instruction is used for indicating the second cluster to change the permission from unreadable to writable to readable and writable.
In the embodiment of the application, the management platform sends the first permission modification instruction to the second cluster, and after the second cluster receives the first permission modification instruction, the second cluster changes the topic permission of the second cluster from the initial unreadable state to the readable state, so that the second cluster can be written with a message by a producer and can also be read by a consumer.
S203, sending a second instruction to a server, wherein the second instruction is used for instructing the server to stop writing the message into the first cluster and start writing the message into the first cluster.
In this embodiment of the present application, in order to perform cluster migration, on the premise that the above steps ensure that the topoc configuration of the second cluster is the same as the topoc configuration of the first cluster, the consumer subscribes to the second cluster, and the second cluster is in a readable and writable state, the management platform sends a second instruction to the producer, and after receiving the second instruction, the producer stops writing the message to the first cluster and starts writing the message to the second cluster at the same time, so that transition of writing the message to the object by the producer is achieved.
In an embodiment, after step S203, the method further includes:
and after the producer stops writing the message into the first cluster and starts writing the message into the second cluster, the permission of the first cluster is changed from read-write to read-only based on the configuration information.
In this embodiment of the application, after the message write object of the producer is changed to the second cluster, the first cluster will not be written with new messages any more, and at this time, the management platform will change the topic authority of the first cluster from read-write to read-only, so that the first cluster can only allow the consumer to continue reading the unread messages in the first cluster.
Through the process, the new message generated by the producer is written into the second cluster and is further read by the consumer continuously, the migration of the clusters is completed, the remaining messages which are not read in the first cluster can still be read by the consumer continuously, the message in the first cluster cannot be lost due to the migration of the first cluster to the second cluster, the configuration automation is realized, and the stability risk possibly caused by manual operation and maintenance is avoided.
Referring to fig. 3, fig. 3 is a schematic flowchart of another cluster migration method provided in the embodiment of the present application, and as shown in fig. 3, in the embodiment of the present application, the method may further include:
s301, creating a second cluster, acquiring configuration information of the first cluster, and creating the configuration information of the first cluster in the second cluster.
In this embodiment of the present application, when cluster migration is required, the management platform creates a second cluster based on the original cluster, that is, the first cluster, and the number of brokers of the created second cluster is the same as the number of brokers of the first cluster. The created second cluster is not configured in the initial state, and the management platform acquires the topic configuration information of the first cluster and creates the topic configuration information with the same content as the topic configuration information in the second cluster. topic is a different classification of message sources of a processing resource, which can be understood as a topic, each producer can issue some messages to a topic (topic), and a second cluster can write the same kind of messages as in a first cluster after creating the same topic configuration as in the first cluster.
S302, sending a first instruction to a user side, wherein the first instruction is used for indicating the user to read messages of a first cluster and a second cluster at the same time.
The specific process is shown in step S201, and is not described herein again.
S303, changing the authority of the second cluster from unreadable to writable to readable and writable based on the configuration information of the second cluster.
The specific process is shown in step S202, and is not described herein again.
S304, sending a second instruction to a server, wherein the second instruction is used for instructing the server to stop writing the message into the first cluster and start writing the message into the first cluster.
The specific process is shown in step S203, and is not described herein again.
S305, sending a second permission modification instruction to the first cluster, wherein the second permission modification instruction is used for instructing the first cluster to change the permission from read-write to read-only.
In this embodiment of the application, after the message write object of the producer is changed to the second cluster, the first cluster will not be written with new messages any more, and at this time, the management platform will change the topic authority of the first cluster from read-write to read-only, so that the first cluster can only allow the consumer to continue reading the unread messages in the first cluster.
S306, after the user side finishes reading all the messages of the first cluster, sending a third permission modification instruction to the first cluster, wherein the third permission modification instruction is used for indicating the first cluster to change the permission from read-only to unreadable.
In the embodiment of the application, since the consumer subscribes to the first cluster and the second cluster at the same time, the consumer reads new messages from the second cluster and reads the remaining unread messages in the first cluster. After the consumer completely reads the messages in the first cluster, the management platform changes the topic authority of the first cluster from a read-only state to a non-readable-writable state because the first cluster can not be written with the messages, i.e. the first cluster can not have new messages to be read by the consumer any more. The specific way for the management platform to modify the topic permission of the first cluster is that the management platform sends a third permission modification instruction to the first cluster, and the topic permission of the first cluster is changed into unreadable after the first cluster receives the third permission modification instruction.
S307, sending a third instruction to the user side, where the third instruction is used to instruct the user side to stop reading the message from the first cluster.
In the embodiment of the application, after the topic authority of the first cluster is modified to be unreadable, the consumer does not need to subscribe to the first cluster again because the first cluster cannot be read and written and the first cluster does not have a new message to be read. The management platform sends a third instruction to the consumer, and the consumer stops reading the message from the first cluster after receiving the third instruction.
And S308, generating migration completion reminding information, and sending the migration completion reminding information to a preset user terminal of a manager.
In the embodiment of the application, because the cluster migration is realized by the communication between the management platform and the first cluster, the second cluster, the producer and the consumer, the management platform generates the migration completion reminding information after the cluster migration is finished. The management platform can manually store the user terminal ID corresponding to the manager who needs to send the migration completion reminding information after the migration is completed in advance, and when the migration completion reminding information needs to be sent, the management platform can directly obtain the user terminal ID and send the migration completion reminding information to the user terminal corresponding to the user terminal ID. The migration completion reminding information may be a piece of text, voice or picture, for example, it may be a text message containing the word "cluster migration completed".
Through the process, after the rest messages in the first cluster are completely read, the authority of the first cluster is modified and the association between the first cluster and the consumer is disconnected, so that the first cluster is separated from the whole body after the first cluster is migrated, and the follow-up maintenance and other work of the first cluster by a manager is facilitated.
The cluster migration apparatus provided in the embodiment of the present application will be described in detail below with reference to fig. 4. It should be noted that, the cluster migration apparatus shown in fig. 4 is used for executing the method of the embodiments shown in fig. 2 to fig. 3 of the present application, and for convenience of description, only the portion related to the embodiments of the present application is shown, and details of the specific technology are not disclosed, please refer to the embodiments shown in fig. 2 to fig. 3 of the present application.
Referring to fig. 4, fig. 4 is a schematic structural diagram of a cluster migration apparatus provided in an embodiment of the present application, and as shown in fig. 4, the cluster migration apparatus includes:
a first sending module 401, configured to send a first instruction to a user side, where the first instruction is used to instruct the user to read messages of a first cluster and a second cluster at the same time; the second cluster is a cluster created based on the first cluster;
a first permission changing module 402, configured to change permission of the second cluster from unreadable to writable to readable and writable based on configuration information of the second cluster;
a second sending module 403, configured to send a second instruction to a server, where the second instruction is used to instruct the server to stop writing a message to the first cluster and start writing a message to the first cluster.
In an implementation manner, the first permission changing module 402 is specifically configured to:
and sending a first permission modification instruction to the second cluster, wherein the first permission modification instruction is used for indicating the second cluster to change the permission from unreadable to writable to readable and writable.
In one embodiment, the apparatus further comprises:
and the second permission modification module is used for sending a second permission modification instruction to the first cluster, wherein the second permission modification instruction is used for indicating the first cluster to change the permission from read-write to read-only.
In one embodiment, the second permission modification module includes:
and the sending unit is used for sending a third permission modification instruction to the first cluster after the user side finishes reading all the messages of the first cluster, wherein the third permission modification instruction is used for indicating the first cluster to change the permission from read-only to unreadable.
In one embodiment, the sending unit includes:
a sending element, configured to send a third instruction to a user side, where the third instruction is used to instruct the user side to stop reading a message from the first cluster.
In one embodiment, the transmitting element is specifically configured to:
and generating migration completion reminding information, and sending the migration completion reminding information to a user terminal of a preset manager.
In one embodiment, the apparatus further comprises:
the creating module is used for creating a second cluster and acquiring the configuration information of the first cluster;
a configuration module to create the configuration information of the first cluster in the second cluster.
It is clear to a person skilled in the art that the solution according to the embodiments of the present application can be implemented by means of software and/or hardware. The "unit" and "module" in this specification refer to software and/or hardware that can perform a specific function independently or in cooperation with other components, where the hardware may be, for example, a Field-Programmable Gate Array (FPGA), an Integrated Circuit (IC), or the like.
Each processing unit and/or module in the embodiments of the present application may be implemented by an analog circuit that implements the functions described in the embodiments of the present application, or may be implemented by software that executes the functions described in the embodiments of the present application.
Referring to fig. 5, a schematic structural diagram of a cluster migration apparatus according to an embodiment of the present application is shown, where the cluster migration apparatus may be used to implement the cluster migration method in the foregoing embodiment. As shown in fig. 5, the cluster migration apparatus 500 may include: at least one central processor 501, at least one network interface 504, a user interface 503, a memory 505, at least one communication bus 502.
Wherein a communication bus 502 is used to enable connective communication between these components.
The user interface 503 may include a Display screen (Display) and a Camera (Camera), and the optional user interface 503 may also include a standard wired interface and a wireless interface.
The network interface 504 may optionally include a standard wired interface, a wireless interface (e.g., WI-FI interface), among others.
The central processor 501 may include one or more processing cores. The central processor 501 connects various parts within the entire terminal 500 using various interfaces and lines, and performs various functions of the terminal 500 and processes data by executing or executing instructions, programs, code sets, or instruction sets stored in the memory 505 and calling data stored in the memory 505. Optionally, the central Processing unit 501 may be implemented in at least one hardware form of Digital Signal Processing (DSP), Field-Programmable Gate Array (FPGA), and Programmable Logic Array (PLA). The Central Processing Unit 501 may integrate one or a combination of a Central Processing Unit (CPU), a Graphics Processing Unit (GPU), a modem, and the like. Wherein, the CPU mainly processes an operating system, a user interface, an application program and the like; the GPU is used for rendering and drawing the content required to be displayed by the display screen; the modem is used to handle wireless communications. It is to be understood that the modem may not be integrated into the central processing unit 501, and may be implemented by a single chip.
The Memory 505 may include a Random Access Memory (RAM) or a Read-Only Memory (Read-Only Memory). Optionally, the memory 505 includes a non-transitory computer-readable medium. The memory 505 may be used to store instructions, programs, code sets, or instruction sets. The memory 505 may include a stored program area and a stored data area, wherein the stored program area may store instructions for implementing an operating system, instructions for at least one function (such as a touch function, a sound playing function, an image playing function, etc.), instructions for implementing the various method embodiments described above, and the like; the storage data area may store data and the like referred to in the above respective method embodiments. The memory 505 may alternatively be at least one memory device located remotely from the aforementioned central processor 501. As shown in fig. 5, memory 505, which is a type of computer storage medium, may include an operating system, a network communication module, a user interface module, and program instructions.
The present application also provides a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, performs the steps of the above-described method. The computer-readable storage medium may include, but is not limited to, any type of disk including floppy disks, optical disks, DVD, CD-ROMs, microdrive, and magneto-optical disks, ROMs, RAMs, EPROMs, EEPROMs, DRAMs, VRAMs, flash memory devices, magnetic or optical cards, nanosystems (including molecular memory ICs), or any type of media or device suitable for storing instructions and/or data.
It should be noted that, for simplicity of description, the above-mentioned method embodiments are described as a series of acts or combination of acts, but those skilled in the art will recognize that the present application is not limited by the order of acts described, as some steps may occur in other orders or concurrently depending on the application. Further, those skilled in the art should also appreciate that the embodiments described in the specification are preferred embodiments and that the acts and modules referred to are not necessarily required in this application.
In the foregoing embodiments, the descriptions of the respective embodiments have respective emphasis, and for parts that are not described in detail in a certain embodiment, reference may be made to related descriptions of other embodiments.
In the embodiments provided in the present application, it should be understood that the disclosed apparatus may be implemented in other manners. For example, the above-described embodiments of the apparatus are merely illustrative, and for example, the division of the units is only one type of division of logical functions, and there may be other divisions when actually implementing, for example, a plurality of units or components may be combined or may be integrated into another system, or some features may be omitted, or not implemented. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection of some service interfaces, devices or units, and may be an electrical 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 application 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 memory. Based on such understanding, the technical solution of the present application may be substantially implemented or a part of or all or part of the technical solution contributing to the prior art may be embodied in the form of a software product stored in a memory, and including several 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 described in the embodiments of the present application. And the aforementioned memory comprises: various media capable of storing program codes, such as a usb disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a removable hard disk, a magnetic disk, or an optical disk.
Those skilled in the art will appreciate that all or part of the steps in the methods of the above embodiments may be implemented by a program, which is stored in a computer-readable memory, and the memory may include: flash disks, Read-Only memories (ROMs), Random Access Memories (RAMs), magnetic or optical disks, and the like.
The above description is only an exemplary embodiment of the present disclosure, and the scope of the present disclosure should not be limited thereby. That is, all equivalent changes and modifications made in accordance with the teachings of the present disclosure are intended to be included within the scope of the present disclosure. Embodiments of the present disclosure will be readily apparent to those skilled in the art from consideration of the specification and practice of the disclosure herein. This application is intended to cover any variations, uses, or adaptations of the disclosure following, in general, the principles of the disclosure and including such departures from the present disclosure as come within known or customary practice within the art to which the disclosure pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the disclosure being indicated by the following claims.

Claims (10)

1. A method of cluster migration, comprising:
sending a first instruction to a user side, wherein the first instruction is used for indicating the user to read messages of a first cluster and a second cluster at the same time; the second cluster is a cluster created based on the first cluster;
changing the authority of the second cluster from unreadable to writable to readable and writable based on the configuration information of the second cluster;
and sending a second instruction to a server, wherein the second instruction is used for instructing the server to stop writing the message into the first cluster and start writing the message into the first cluster.
2. The method according to claim 1, wherein the changing the authority of the second cluster from unreadable to writable based on the configuration information of the second cluster comprises:
and sending a first permission modification instruction to the second cluster, wherein the first permission modification instruction is used for indicating the second cluster to change the permission from unreadable to writable to readable and writable.
3. The method of claim 1, wherein after sending a second instruction to a server, the second instruction being used to instruct the server to stop writing messages to the first cluster and start writing messages to the second cluster, further comprising:
sending a second permission modification instruction to the first cluster, wherein the second permission modification instruction is used for instructing the first cluster to change the permission from read-write to read-only.
4. The method of claim 3, wherein after sending a second permission modification instruction to the first cluster, the second permission modification instruction being used to instruct the first cluster to change the permission from read-write to read-only, further comprising:
and after the user side finishes reading all the messages of the first cluster, sending a third permission modification instruction to the first cluster, wherein the third permission modification instruction is used for indicating the first cluster to change the permission from read-only to unreadable.
5. The method according to claim 4, wherein after the user side finishes reading all the messages of the first cluster, the method further includes sending a third permission modification instruction to the first cluster, where the third permission modification instruction is used to instruct the first cluster to change the permission from read-only to unreadable, and further including:
and sending a third instruction to the user side, wherein the third instruction is used for indicating the user side to stop reading the message from the first cluster.
6. The method according to claim 5, wherein after sending a third instruction to the user side, the third instruction being used to instruct the user side to stop reading the message to the first cluster, the method further comprises:
and generating migration completion reminding information, and sending the migration completion reminding information to a user terminal of a preset manager.
7. The method according to claim 1, wherein the sending of the first instruction to the user side is configured to instruct the user to read messages of the first cluster and the second cluster at the same time; before the second cluster is a cluster created based on the first cluster, the method further includes:
creating a second cluster and acquiring configuration information of the first cluster;
creating the configuration information of the first cluster in the second cluster.
8. A cluster migration apparatus, comprising:
the first instruction sending module is used for sending a first instruction to a user side after a second cluster is created based on a first cluster, wherein the first instruction is used for indicating the user side to read messages of the first cluster and the second cluster at the same time;
the first permission modification module is used for changing the permission of the second cluster from unreadable to writable to readable and writable based on the configuration information of the second cluster;
and the second instruction sending module is used for sending a second instruction to the server, wherein the second instruction is used for indicating the server to stop writing the message into the first cluster and start writing the message into the second cluster.
9. A cluster migration apparatus comprising a memory, a processor and a computer program stored on the memory and executable on the processor, wherein the processor implements the steps of the method according to any one of claims 1 to 7 when executing the computer program.
10. A computer-readable storage medium, on which a computer program is stored which, when being executed by a processor, carries out the steps of the method according to any one of claims 1 to 7.
CN202011064011.8A 2020-09-30 2020-09-30 Cluster migration method and device and storage medium Pending CN112286904A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011064011.8A CN112286904A (en) 2020-09-30 2020-09-30 Cluster migration method and device and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011064011.8A CN112286904A (en) 2020-09-30 2020-09-30 Cluster migration method and device and storage medium

Publications (1)

Publication Number Publication Date
CN112286904A true CN112286904A (en) 2021-01-29

Family

ID=74422697

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011064011.8A Pending CN112286904A (en) 2020-09-30 2020-09-30 Cluster migration method and device and storage medium

Country Status (1)

Country Link
CN (1) CN112286904A (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113268466A (en) * 2021-06-07 2021-08-17 上海数禾信息科技有限公司 Method and system for smoothly migrating message cluster
CN113282391A (en) * 2021-05-21 2021-08-20 北京京东振世信息技术有限公司 Cluster switching method, cluster switching device, electronic equipment and readable storage medium
CN113590040A (en) * 2021-07-29 2021-11-02 郑州阿帕斯数云信息科技有限公司 Data processing method, device, equipment and storage medium
CN113590602A (en) * 2021-07-30 2021-11-02 上海微盟企业发展有限公司 Message duplicate removal method, device, equipment and storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106997306A (en) * 2016-01-26 2017-08-01 阿里巴巴集团控股有限公司 Physical machine Data Migration to high in the clouds methods, devices and systems
CN109842636A (en) * 2017-11-24 2019-06-04 阿里巴巴集团控股有限公司 Cloud service moving method, device and electronic equipment
US20190222640A1 (en) * 2018-01-17 2019-07-18 International Business Machines Corporation Migration of durable clients in a clustered publish/subscribe system
CN111078127A (en) * 2018-10-22 2020-04-28 阿里巴巴集团控股有限公司 Data migration method, system and device
CN111224819A (en) * 2019-12-30 2020-06-02 上海汇付数据服务有限公司 Distributed messaging system

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106997306A (en) * 2016-01-26 2017-08-01 阿里巴巴集团控股有限公司 Physical machine Data Migration to high in the clouds methods, devices and systems
CN109842636A (en) * 2017-11-24 2019-06-04 阿里巴巴集团控股有限公司 Cloud service moving method, device and electronic equipment
US20190222640A1 (en) * 2018-01-17 2019-07-18 International Business Machines Corporation Migration of durable clients in a clustered publish/subscribe system
CN111078127A (en) * 2018-10-22 2020-04-28 阿里巴巴集团控股有限公司 Data migration method, system and device
CN111224819A (en) * 2019-12-30 2020-06-02 上海汇付数据服务有限公司 Distributed messaging system

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113282391A (en) * 2021-05-21 2021-08-20 北京京东振世信息技术有限公司 Cluster switching method, cluster switching device, electronic equipment and readable storage medium
CN113282391B (en) * 2021-05-21 2023-09-26 北京京东振世信息技术有限公司 Cluster switching method, cluster switching device, electronic equipment and readable storage medium
CN113268466A (en) * 2021-06-07 2021-08-17 上海数禾信息科技有限公司 Method and system for smoothly migrating message cluster
CN113590040A (en) * 2021-07-29 2021-11-02 郑州阿帕斯数云信息科技有限公司 Data processing method, device, equipment and storage medium
CN113590040B (en) * 2021-07-29 2024-03-19 郑州阿帕斯数云信息科技有限公司 Data processing method, device, equipment and storage medium
CN113590602A (en) * 2021-07-30 2021-11-02 上海微盟企业发展有限公司 Message duplicate removal method, device, equipment and storage medium

Similar Documents

Publication Publication Date Title
CN112286904A (en) Cluster migration method and device and storage medium
US10949158B2 (en) Screenshot method and apparatus
CN111079047B (en) Web-oriented page construction system
CN112286723A (en) Computer room disaster recovery control method, terminal and storage medium
CN113110829B (en) Multi-UI component library data processing method and device
CN109410083A (en) Information sharing method and device and storage medium
CN112291082A (en) Computer room disaster recovery processing method, terminal and storage medium
CN111324480A (en) Large host transaction fault positioning system and method
CN105094824A (en) Display method for notification messages on intelligent watch and intelligent watch
CN113760611B (en) System site switching method and device, electronic equipment and storage medium
CN113342330A (en) Front-end engineering generation method and device
CN113672488A (en) Log text processing method and device
CN110908739B (en) Method, device and equipment for realizing data docking with third-party Launcher
CN111782204B (en) Batch scheduling editing method and device
CN111736825B (en) Information display method, device, equipment and storage medium
CN113434423B (en) Interface testing method and device
CN113986087B (en) Video rendering method based on subscription
CN111401006A (en) Document playing method, device and system and computer readable storage medium
CN112367535B (en) Generation method and device of active user interface
CN110290517B (en) Digital media wireless wifi communication point reading system and method
CN112035162A (en) Configuration file batch modification method and device
CN112905464A (en) Application running environment data processing method and device
CN111953847A (en) Client message risk reminding method, device and system
CN115955450B (en) Instant message display and push method and device, electronic equipment and storage medium
CN111447258B (en) Method, device and equipment for scheduling offline tasks 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