CN112769634B - Zookeeper-based laterally-expandable distributed system and development method - Google Patents

Zookeeper-based laterally-expandable distributed system and development method Download PDF

Info

Publication number
CN112769634B
CN112769634B CN202011450077.0A CN202011450077A CN112769634B CN 112769634 B CN112769634 B CN 112769634B CN 202011450077 A CN202011450077 A CN 202011450077A CN 112769634 B CN112769634 B CN 112769634B
Authority
CN
China
Prior art keywords
node
plug
master node
slave
instruction
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.)
Active
Application number
CN202011450077.0A
Other languages
Chinese (zh)
Other versions
CN112769634A (en
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.)
Aisino Corp
Original Assignee
Aisino Corp
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 Aisino Corp filed Critical Aisino Corp
Priority to CN202011450077.0A priority Critical patent/CN112769634B/en
Publication of CN112769634A publication Critical patent/CN112769634A/en
Application granted granted Critical
Publication of CN112769634B publication Critical patent/CN112769634B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/10Active monitoring, e.g. heartbeat, ping or trace-route
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/1095Replication or mirroring of data, e.g. scheduling or transport for data synchronisation between network nodes
    • YGENERAL 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
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE 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/00Energy efficient computing, e.g. low power processors, power management or thermal management

Abstract

The application discloses a Zookeeper-based laterally-expandable distributed system and a development method, wherein the system comprises an information interaction unit, a node management unit and a plug-in expansion unit; the information interaction unit is used for receiving a user instruction sent by a user, and loading a configuration file to obtain a configuration instruction; the node management unit utilizes the distributed coordination characteristic of the Zookeeper to manage the competition of the cluster nodes, and the master node is selected in an competing way, so that the master node is used as the brain of the system to control the business of the whole cluster; the plug-in expansion unit develops plug-ins at any node by using a plug-in mechanism, so that the service logic of a main system is not modified, and the development of the system is expanded, thereby achieving the characteristics of low coupling and high cohesion; the application provides a high-performance, high-availability, telescopic and extensible system based on a Zookeeper framework so as to solve the problem of high-concurrency access of an application system layer.

Description

Zookeeper-based laterally-expandable distributed system and development method
Technical Field
The application relates to the field of system development, in particular to a Zookeeper-based laterally-expandable distributed system and a development method.
Background
In the context of the rapid evolution of the internet today, the number of internet users is increasing, resulting in geometrically increasing access pressures, and single systems have failed to meet the high concurrency support. The method can perform longitudinal expansion or transverse expansion to meet high concurrency access in a data layer, a system layer and an access layer, and can perform targeted optimization on specific high concurrency modules, such as building a cache, a newly added load balancing system, newly added queue consumption and the like. However, there is currently no effective way to solve the high concurrency problem of the application system layer.
The application mainly develops a set of laterally-expandable distributed service development framework aiming at an application system layer so as to meet the requirements of a high-performance, high-availability, telescopic and expandable large website system. On the basis of this system framework, any system can be developed, such as business systems, service systems, interface systems supporting front-ends (apps, split front-ends), etc.
Disclosure of Invention
In order to solve the problem that the application system layer lacks an extensible framework and is difficult to cope with high concurrent access in the background technology, the application provides a Zookeeper-based laterally extensible distributed system, which comprises:
the information interaction unit is connected with the node management unit at one end; the information interaction unit is used for receiving a user instruction sent by a user, loading a configuration file to obtain a configuration instruction, and sending the user instruction and the configuration instruction to the node management unit;
the node management unit comprises a node operation module and a registration monitoring module; the node management unit adopts a Zookeeper framework;
the node operation module comprises 1 master node, M slave nodes and N load nodes; the M, N are all positive integers; the main node is used for sending a main node instruction and a main node heartbeat packet to the registration monitoring module according to the configuration instruction, and running a plug-in; the slave node is used for operating the plug-in unit according to the master node instruction, and judging whether to elect a new master node according to the master node heartbeat packet and a preset rule; the load node is used for sending a load distribution request to the registration monitoring module according to the main node instruction, the user instruction and the load algorithm;
one end of the registration monitoring module is connected with the node operation module and is used for sending the master node instruction to the slave node and the load node, sending the heartbeat packet of the master node to the slave node and sending the load distribution request to the master node and the slave node;
the plug-in extension unit is connected with the node management unit at one end; the plug-in expansion unit is used for autonomously developing plug-ins and providing the plug-ins for the node management unit.
Further, the system further comprises:
the system initialization unit is connected with the information interaction unit, the node management unit and the plug-in extension unit; the system initialization unit is used for realizing the functions of initializing the system during starting, background periodic scheduling task, health degree checking and service managed.
Further, the information interaction unit comprises a user instruction which is sent by a user in a web service access mode constructed based on a Dropwizard framework; the information interaction unit also supports dependency injection and tangent plane oriented functions realized based on the guide framework.
Further, the slave node is further configured to send a heartbeat packet of the slave node to the registration monitoring module; the monitoring module is also used for sending the heartbeat packet of the slave node to the master node; the master node is also used for judging whether the corresponding slave node operates normally or not according to the slave node heartbeat packet; and if the slave node is abnormally operated, removing the abnormal operation slave node information from the storage.
Further, the slave node judging whether to elect a new master node according to the master node heartbeat packet and a preset rule includes:
the M slave nodes detect the heartbeat packet of the master node, and if the P slave nodes judge that the master node runs abnormally, the master node is selected from the M slave nodes and acts as the master node; wherein, P is more than or equal to 1 and less than or equal to M.
Further, the autonomic development plug-in includes:
front-end and back-end separated plug-in development mode, namely back-end code plug-in development, front-end plug-in deployment mapping; front and back end code plug-in development without plug-in development separation.
A Zookeeper-based laterally extensible distributed development method comprises the following steps:
acquiring a user instruction and a configuration instruction;
according to the configuration instruction, the master node sends a master node heartbeat packet to the slave node, sends a master node instruction to the slave node and the load node, and operates the plug-in;
the slave node operates a plug-in according to the master node instruction, and judges whether to elect a new master node according to the master node heartbeat packet and a preset rule;
the load node sends a load distribution request to the master node and the slave node according to the master node instruction, the user instruction and the load algorithm;
the master node, the slave node and the load node are managed based on a Zookeeper;
and independently developing plug-ins under the master node and the slave nodes according to requirements.
Further, before the user instruction and the configuration instruction are acquired, the method further comprises:
initializing a system;
the master node, the slave node, and the load node register based on a Zookeeper.
Further, the user instruction is acquired in a web service access mode constructed based on the Dropwizard framework.
Further, the method further comprises:
the slave node sends a slave node heartbeat packet to the master node; the master node judges whether the corresponding slave node operates normally according to the slave node heartbeat packet; and if the slave node is abnormally operated, removing the abnormal operation slave node information from the storage.
Further, the number of the master nodes is 1, the number of the slave nodes is M, and the number of the load nodes is N; the M, N are all positive integers; the slave nodes judge whether to elect a new master node according to the master node heartbeat packet and a preset rule, wherein if P slave nodes judge that the master node operates abnormally according to the master node heartbeat packet, the slave nodes elect the master node and act as the master node from M slave nodes; wherein, P is more than or equal to 1 and less than or equal to M.
Further, the autonomic development plug-in includes:
front-end and back-end separated plug-in development mode, namely back-end code plug-in development, front-end plug-in deployment mapping; front and back end code plug-in development without plug-in development separation.
The beneficial effects of the application are as follows: the application provides a Zookeeper-based laterally-expandable distributed system and a development method, wherein the system comprises an information interaction unit, a node management unit and a plug-in expansion unit; the information interaction unit is used for receiving a user instruction sent by a user, and loading a configuration file to obtain a configuration instruction; the node management unit utilizes the distributed coordination characteristic of the Zookeeper to manage the competition of the cluster nodes, and the master node is selected in an competing way, so that the master node is used as the brain of the system to control the business of the whole cluster; the plug-in expansion unit develops plug-ins at any node by using a plug-in mechanism, so that the service logic of a main system is not modified, and the development of the system is expanded, thereby achieving the characteristics of low coupling and high cohesion; the application provides a high-performance, high-availability, telescopic and extensible system based on a Zookeeper framework so as to solve the problem of high-concurrency access of an application system layer.
Drawings
Exemplary embodiments of the present application may be more completely understood in consideration of the following drawings:
FIG. 1 is a block diagram of a laterally scalable, distributed system based on Zookeeper in accordance with an embodiment of the present application;
fig. 2 is a flowchart of a laterally extensible distributed development method based on Zookeeper according to an embodiment of the present application.
Detailed Description
The exemplary embodiments of the present application will now be described with reference to the accompanying drawings, however, the present application may be embodied in many different forms and is not limited to the examples described herein, which are provided to fully and completely disclose the present application and fully convey the scope of the application to those skilled in the art. The terminology used in the exemplary embodiments illustrated in the accompanying drawings is not intended to be limiting of the application. In the drawings, like elements/components are referred to by like reference numerals.
Unless otherwise indicated, terms (including technical and scientific terms) used herein have the same meaning as commonly understood by one of ordinary skill in the art. In addition, it will be understood that terms defined in commonly used dictionaries should be interpreted as having a meaning that is consistent with their meaning in the context of the relevant art and will not be interpreted in an idealized or overly formal sense.
Fig. 1 is a block diagram of a laterally scalable distributed system based on Zookeeper according to an embodiment of the present application. As shown in fig. 1, the system includes:
an information interaction unit 110, wherein one end of the information interaction unit 110 is connected with the node management unit 120; the information interaction unit 110 is configured to receive a user instruction sent by a user, load a configuration file to obtain a configuration instruction, and send the user instruction and the configuration instruction to the node management unit 120; specifically, the information interaction unit 110 in this example includes a user instruction that receives a user transmission in a manner of accessing a web service constructed based on a Dropwizard framework; the information interaction unit 110 also supports dependency injection and a section-oriented function realized based on a guide frame; the configuration file comprises relevant information of the master node and the slave nodes, relevant information of each node operation plugin, load node load distribution request information and the like; or the slave node may be automatically discovered when the system is started.
A node management unit 120, where the node management unit 120 includes a node operation module 1201 and a registration monitoring module 1202; the node management unit 120 adopts a Zookeeper framework;
the node operation module 1201 comprises 1 master node, M slave nodes and N load nodes; the M, N are all positive integers; the master node is configured to send a master node instruction and a master node heartbeat packet to the registration monitor module 1202 according to the configuration instruction, and run a plugin; the slave node is used for operating the plug-in unit according to the master node instruction, and judging whether to elect a new master node according to the master node heartbeat packet and a preset rule; the load node is configured to send a load distribution request to the registration monitor module 1202 according to the main node instruction, the user instruction, and the load algorithm;
further, the slave node is further configured to send a slave node heartbeat packet to the registration monitor module 1202; the monitoring module 1202 is further configured to send the heartbeat packet from the slave node to the master node; the master node is also used for judging whether the corresponding slave node operates normally or not according to the slave node heartbeat packet; if the slave node is abnormally operated, the information of the abnormally operated slave node is removed from the storage;
further, the slave node judging whether to elect a new master node according to the master node heartbeat packet and a preset rule includes:
the M slave nodes detect the heartbeat packet of the master node, and if the P slave nodes judge that the master node runs abnormally, the master node is selected from the M slave nodes and acts as the master node; wherein, P is more than or equal to 1 and less than or equal to M.
Specifically, in this example, M takes 20 and p takes 10, that is, if more than half of the slave nodes find that the master node is abnormally operated, the master node is selected from the slave nodes, and the selected master node acts as the master node;
one end of the registration monitoring module 1202 is connected with the node running module 1201, and is configured to send the master node instruction to the slave node and the load node, send the heartbeat packet of the master node to the slave node, and send the load distribution request to the master node and the slave node;
specifically, the registration monitor module 1202 in this example uses the distributed coordination feature of the Zookeeper to implement registration and monitoring on various nodes to manage competition of the cluster nodes, so that the master node serves as a brain of the system to control the service of the whole cluster.
A plug-in extension unit 130, wherein one end of the plug-in extension unit 130 is connected with the node management unit 120; the plug-in extension unit 130 is configured to autonomously develop a plug-in and provide the plug-in to the node management unit 120;
further, the autonomic development plug-in includes:
front-end and back-end separated plug-in development mode, namely back-end code plug-in development, front-end plug-in deployment mapping; front and back end code plug-in development without plug-in development separation; therefore, when the plug-in package is deployed, only the developed plug-in package is required to be deployed, so that the expanded service or the service provided by the outside can be met; the plug-in is mainly aimed at a certain task or external service, the configuration files of all the plug-ins are independent, the configuration files special for the plug-in can be customized, the maximum normal operation node number and the minimum normal operation number are configured in the plug-in configuration files, and when the node for operating the plug-in is hung off, the plug-in can be transferred to a service node which does not start the plug-in; when the plug-in is run by nodes that are not satisfied, i.e., all running nodes run the plug-in, and less than the minimum number of running nodes, the system generates an alarm.
A system initialization unit 140, where the system initialization unit 140 is connected to the information interaction unit 110, the node management unit 120, and the plug-in extension unit 130; the system initialization unit 110 is configured to implement functions including an initialization function at system startup, a background periodic scheduling task function, a health check function, and a service managed function;
specifically, the initializing function in this example includes initializing tasks such as registration binding before the plug-in is started; the background periodic scheduling task function comprises functions such as registration binding and the like; the health check function comprises the steps of detecting whether the plug-in running environment is healthy or not before starting, if so, testing the connection condition of a database, and if so, failing to start the system; the service managed functions include initiating a shutdown operation, such as establishing a connection with a database, etc.
Furthermore, the system performs encapsulation processing on part of the database, so that related operations can be directly performed without the need of adding configuration, package leading and other operations by a user; the database includes mysql, oracle, sqlServer, mongodb, etc.; while the system encapsulates and simplifies access to the redis cache and provides a mainstream toolkit, jackson, metrics, etc.
Fig. 2 is a flowchart of a laterally extensible distributed development method based on Zookeeper according to an embodiment of the present application. As shown in fig. 2, the method includes:
step 210, initializing a system; the system initialization comprises an initialization function when the system is started, a background periodic scheduling task function, a health degree checking function and a service managed function;
specifically, the initializing function in this example includes initializing tasks such as registration binding before the plug-in is started; the background periodic scheduling task function comprises functions such as registration binding and the like; the health check function comprises the steps of detecting whether the plug-in running environment is healthy or not before starting, if so, testing the connection condition of a database, and if so, failing to start the system; the service managed functions include initiating a shutdown operation, such as establishing a connection with a database, etc.
Step 220, registering the nodes; the master node, the slave node, and the load node register based on a Zookeeper.
Step 230, obtaining a user instruction and a configuration instruction; the user instruction comprises a specific service; specifically, the configuration instruction in this example includes relevant information of the master node and the slave node, relevant information of each node operation plugin, load node load distribution request information, and the like; the user instruction is acquired in a web service access mode constructed based on a Dropwizard framework.
Step 240, running the plug-in; according to the configuration instruction, a main node instruction is sent to the slave node and the load node, and a plug-in is operated; the slave node operates a plug-in according to the master node instruction;
further, the slave node sends a slave node heartbeat packet to the master node; the master node judges whether the corresponding slave node operates normally according to the slave node heartbeat packet; and if the slave node is abnormally operated, removing the abnormal operation slave node information from the storage.
Step 250, judging whether to elect a new master node; according to the configuration instruction, the master node sends a master node heartbeat packet to the slave node, and the slave node judges whether to elect a new master node according to the master node heartbeat packet and a preset rule;
further, the number of the master nodes is 1, the number of the slave nodes is M, and the number of the load nodes is N; the M, N are all positive integers; the slave nodes judge whether to elect a new master node according to the master node heartbeat packet and a preset rule, wherein if P slave nodes judge that the master node operates abnormally according to the master node heartbeat packet, the slave nodes elect the master node and act as the master node from M slave nodes; wherein, P is more than or equal to 1 and less than or equal to M.
Specifically, in this example, M takes 20 and p takes 10, that is, if more than half of the slave nodes find that the master node is abnormally operated, the master node is selected from the slave nodes, and the selected master node acts as the master node.
Step 260, sending a load distribution request; the load node sends a load distribution request to the master node and the slave node according to the master node instruction, the user instruction and the load algorithm;
furthermore, the master node, the slave node and the load node are managed based on the Zookeeper, and the registration and monitoring of various nodes are realized by utilizing the distributed coordination characteristic of the Zookeeper so as to manage the competition of the cluster nodes, so that the master node is used as a brain of a system to control the business of the whole cluster.
Step 270, autonomously developing plug-ins; independently developing plug-ins under the master node and the slave nodes according to requirements;
specifically, the autonomous development plugin in this example includes: front-end and back-end separated plug-in development mode, namely back-end code plug-in development, front-end plug-in deployment mapping; front and back end code plug-in development without plug-in development separation; therefore, when the plug-in package is deployed, only the developed plug-in package is required to be deployed, so that the expanded service or the service provided by the outside can be met; the plug-in is mainly aimed at a certain task or external service, the configuration files of all the plug-ins are independent, the configuration files special for the plug-in can be customized, the maximum normal operation node number and the minimum normal operation number are configured in the plug-in configuration files, and when the node for operating the plug-in is hung off, the plug-in can be transferred to a service node which does not start the plug-in; when the plug-in is run by nodes that are not satisfied, i.e., all running nodes run the plug-in, and less than the minimum number of running nodes, the system generates an alarm.
Furthermore, the system performs encapsulation processing on part of the database, so that related operations can be directly performed without the need of adding configuration, package leading and other operations by a user; the database includes mysql, oracle, sqlServer, mongodb, etc.; while the system encapsulates and simplifies access to the redis cache and provides a mainstream toolkit, jackson, metrics, etc.
In the description provided herein, numerous specific details are set forth. However, it is understood that embodiments of the disclosure may be practiced without these specific details. In some instances, well-known methods, structures and techniques have not been shown in detail in order not to obscure an understanding of this description.
Those skilled in the art will appreciate that the modules in the apparatus of the embodiments may be adaptively changed and disposed in one or more apparatuses different from the embodiments. The modules or units or components of the embodiments may be combined into one module or unit or component and, furthermore, they may be divided into a plurality of sub-modules or sub-units or sub-components. Any combination of all features disclosed in this specification (including any accompanying claims, abstract and drawings), and all of the processes or units of any method or apparatus so disclosed, may be used in combination, except insofar as at least some of such features and/or processes or units are mutually exclusive. Each feature disclosed in this specification (including any accompanying claims, abstract and drawings), may be replaced by alternative features serving the same, equivalent or similar purpose, unless expressly stated otherwise. Reference to step numbers in this specification is used solely to distinguish between steps and is not intended to limit the time or logical relationship between steps, including the various possible conditions unless the context clearly indicates otherwise.
Furthermore, those skilled in the art will appreciate that while some embodiments described herein include some features but not others included in other embodiments, combinations of features of different embodiments are meant to be within the scope of the disclosure and form different embodiments. For example, any of the embodiments claimed in the claims may be used in any combination.
Various component embodiments of the present disclosure may be implemented in hardware, or in software modules running on one or more processors, or in a combination thereof. The present disclosure may also be implemented as an apparatus or system program (e.g., a computer program and a computer program product) for performing a portion or all of the methods described herein. Such a program embodying the present disclosure may be stored on a computer readable medium, or may have the form of one or more signals. Such signals may be downloaded from an internet website, provided on a carrier signal, or provided in any other form.
It should be noted that the above-mentioned embodiments illustrate rather than limit the disclosure, and that those skilled in the art will be able to design alternative embodiments without departing from the scope of the appended claims. The word "comprising" does not exclude the presence of elements or steps not listed in a claim. The word "a" or "an" preceding an element does not exclude the presence of a plurality of such elements. The disclosure may be implemented by means of hardware comprising several distinct elements, and by means of a suitably programmed computer. In the unit claims enumerating several means, several of these means may be embodied by one and the same item of hardware.
The foregoing is merely a specific embodiment of the disclosure, and it should be noted that it will be apparent to those skilled in the art that various improvements, modifications, and variations can be made without departing from the spirit of the disclosure, and such improvements, modifications, and variations are considered to be within the scope of the application.

Claims (12)

1. A Zookeeper-based laterally scalable distributed system, the system comprising:
the information interaction unit is connected with the node management unit at one end; the information interaction unit is used for receiving a user instruction sent by a user, loading a configuration file to obtain a configuration instruction, and sending the user instruction and the configuration instruction to the node management unit;
the node management unit comprises a node operation module and a registration monitoring module; the node management unit adopts a Zookeeper framework;
the node operation module comprises 1 master node, M slave nodes and N load nodes; the M, N are all positive integers; the main node is used for sending a main node instruction and a main node heartbeat packet to the registration monitoring module according to the configuration instruction, and running a plug-in; the slave node is used for operating the plug-in unit according to the master node instruction, and judging whether to elect a new master node according to the master node heartbeat packet and a preset rule; the load node is used for sending a load distribution request to the registration monitoring module according to the main node instruction, the user instruction and the load algorithm;
one end of the registration monitoring module is connected with the node operation module and is used for sending the master node instruction to the slave node and the load node, sending the heartbeat packet of the master node to the slave node and sending the load distribution request to the master node and the slave node;
the plug-in extension unit is connected with the node management unit at one end; the plug-in expansion unit is used for autonomously developing plug-ins and providing the plug-ins for the node management unit.
2. The system of claim 1, wherein the system further comprises:
the system initialization unit is connected with the information interaction unit, the node management unit and the plug-in extension unit; the system initialization unit is used for realizing the functions of initializing the system during starting, background periodic scheduling task, health degree checking and service managed.
3. The system according to claim 1, wherein:
the information interaction unit comprises a user instruction which is sent by a user and is received in a web service access mode constructed based on a Dropwizard framework; the information interaction unit also supports dependency injection and tangent plane oriented functions realized based on the guide framework.
4. The system according to claim 1, wherein:
the slave node is also used for sending a heartbeat packet of the slave node to the registration monitoring module; the monitoring module is also used for sending the heartbeat packet of the slave node to the master node; the master node is also used for judging whether the corresponding slave node operates normally or not according to the slave node heartbeat packet; and if the slave node is abnormally operated, removing the abnormal operation slave node information from the storage.
5. The system of claim 1, wherein the slave node determining whether to elect a new master node according to the master node heartbeat packet and a preset rule comprises:
the M slave nodes detect the heartbeat packet of the master node, and if the P slave nodes judge that the master node runs abnormally, the master node is selected from the M slave nodes and acts as the master node; wherein, P is more than or equal to 1 and less than or equal to M.
6. The system of claim 1, wherein the autonomous development plugin comprises:
front-end and back-end separated plug-in development mode, namely back-end code plug-in development, front-end plug-in deployment mapping; front and back end code plug-in development without plug-in development separation.
7. A Zookeeper-based laterally scalable distributed development method, the method comprising:
acquiring a user instruction and a configuration instruction;
according to the configuration instruction, the master node sends a master node heartbeat packet to the slave node, sends a master node instruction to the slave node and the load node, and operates the plug-in;
the slave node operates a plug-in according to the master node instruction, and judges whether to elect a new master node according to the master node heartbeat packet and a preset rule;
the load node sends a load distribution request to the master node and the slave node according to the master node instruction, the user instruction and the load algorithm;
the master node, the slave node and the load node are managed based on a Zookeeper;
and independently developing plug-ins under the master node and the slave nodes according to requirements.
8. The method of claim 7, further comprising, prior to the obtaining the user instruction and the configuration instruction:
initializing a system;
the master node, the slave node, and the load node register based on a Zookeeper.
9. The method according to claim 7, wherein: the user instruction is acquired in a web service access mode constructed based on a Dropwizard framework.
10. The method of claim 7, wherein the method further comprises:
the slave node sends a slave node heartbeat packet to the master node; the master node judges whether the corresponding slave node operates normally according to the slave node heartbeat packet; and if the slave node is abnormally operated, removing the abnormal operation slave node information from the storage.
11. The method according to claim 7, wherein:
the number of the master nodes is 1, the number of the slave nodes is M, and the number of the load nodes is N; the M, N are all positive integers; the slave nodes judge whether to elect a new master node according to the master node heartbeat packet and a preset rule, wherein if P slave nodes judge that the master node operates abnormally according to the master node heartbeat packet, the slave nodes elect the master node and act as the master node from M slave nodes; wherein, P is more than or equal to 1 and less than or equal to M.
12. The method of claim 7, wherein the autonomic development plugin comprises:
front-end and back-end separated plug-in development mode, namely back-end code plug-in development, front-end plug-in deployment mapping; front and back end code plug-in development without plug-in development separation.
CN202011450077.0A 2020-12-09 2020-12-09 Zookeeper-based laterally-expandable distributed system and development method Active CN112769634B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011450077.0A CN112769634B (en) 2020-12-09 2020-12-09 Zookeeper-based laterally-expandable distributed system and development method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011450077.0A CN112769634B (en) 2020-12-09 2020-12-09 Zookeeper-based laterally-expandable distributed system and development method

Publications (2)

Publication Number Publication Date
CN112769634A CN112769634A (en) 2021-05-07
CN112769634B true CN112769634B (en) 2023-11-07

Family

ID=75693546

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011450077.0A Active CN112769634B (en) 2020-12-09 2020-12-09 Zookeeper-based laterally-expandable distributed system and development method

Country Status (1)

Country Link
CN (1) CN112769634B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113596187B (en) * 2021-06-25 2023-05-05 新浪技术(中国)有限公司 Domain name configuration management system

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104991760A (en) * 2014-12-23 2015-10-21 广州亦云信息技术有限公司 PaaS platform service management system based on distributed modular technology and realization method
WO2016169529A2 (en) * 2016-05-16 2016-10-27 白杨 Bai yang messaging port switch service
WO2018019023A1 (en) * 2016-07-27 2018-02-01 腾讯科技(深圳)有限公司 Data disaster recovery method, apparatus and system
WO2018036148A1 (en) * 2016-08-23 2018-03-01 东方网力科技股份有限公司 Server cluster system
CN108881489A (en) * 2018-08-03 2018-11-23 高新兴科技集团股份有限公司 A kind of coordination system and method for Distributed Services
CN109327509A (en) * 2018-09-11 2019-02-12 武汉魅瞳科技有限公司 A kind of distributive type Computational frame of the lower coupling of master/slave framework

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104991760A (en) * 2014-12-23 2015-10-21 广州亦云信息技术有限公司 PaaS platform service management system based on distributed modular technology and realization method
WO2016169529A2 (en) * 2016-05-16 2016-10-27 白杨 Bai yang messaging port switch service
WO2018019023A1 (en) * 2016-07-27 2018-02-01 腾讯科技(深圳)有限公司 Data disaster recovery method, apparatus and system
WO2018036148A1 (en) * 2016-08-23 2018-03-01 东方网力科技股份有限公司 Server cluster system
CN108881489A (en) * 2018-08-03 2018-11-23 高新兴科技集团股份有限公司 A kind of coordination system and method for Distributed Services
CN109327509A (en) * 2018-09-11 2019-02-12 武汉魅瞳科技有限公司 A kind of distributive type Computational frame of the lower coupling of master/slave framework

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
基于Bully算法的Redis集群选举方案优化;王芬;顾乃杰;黄增士;;计算机科学(10);全文 *

Also Published As

Publication number Publication date
CN112769634A (en) 2021-05-07

Similar Documents

Publication Publication Date Title
CN109471770B (en) System management method and device
US9110766B2 (en) Dynamically recommending changes to an association between an operating system image and an update group
US20150220411A1 (en) System and method for operating system agnostic hardware validation
US11175918B2 (en) Management protocol adapter
US8901960B2 (en) FPGA mounted apparatus and FPGA configuration method
US10956143B2 (en) Server updates
US8819708B2 (en) System and method to abstract hardware routing via a correlatable identifier
US9753809B2 (en) Crash management of host computing systems in a cluster
US10848839B2 (en) Out-of-band telemetry data collection
US10055280B2 (en) Discovery and remediation of a device via a peer device
US10459742B2 (en) System and method for operating system initiated firmware update via UEFI applications
US20170344429A1 (en) Remediation of a Device using an Embedded Server
US20160253501A1 (en) Method for Detecting a Unified Extensible Firmware Interface Protocol Reload Attack and System Therefor
CN112769634B (en) Zookeeper-based laterally-expandable distributed system and development method
US20220019524A1 (en) System and method for validating cloud-native applications for a production-ready deployment
CN102904946B (en) Method and device for managing nodes in cluster
CN112671601B (en) Interface monitoring system and method based on Zookeeper
US9274905B1 (en) Configuration tests for computer system
CN114281353A (en) Avoiding platform and service outages using deployment metadata
US11290341B2 (en) Dynamic resiliency framework
US10339076B2 (en) System and method for adaptable fabric consistency validation and issue mitigation in an information handling system
JP7389877B2 (en) Network optimal boot path method and system
US11144487B1 (en) Method to overload hardware pin for improved system management
US20240103954A1 (en) Dynamic adjustment of log level of microservices in hci environment
CN108021381A (en) The upgrading method for one-chip computer and device of equipment

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