Unlock instant, AI-driven research and patent intelligence for your innovation.

Method and apparatus for allocating nodes

A technology for assigning nodes and nodes, which is applied in the computer field and can solve problems such as long time consumption, communication timeout, and increased load

Active Publication Date: 2021-03-30
GUANGZHOU KUGOU COMP TECH CO LTD
View PDF6 Cites 0 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0004] In this way, when the primary shard is assigned to the primary node, the primary node will increase the disk read and write load and increase the load when optimizing the index, so that the primary node will spend a long time when optimizing the index, which will lead to The communication of other nodes times out, causing other nodes to mistakenly think that the master node is faulty, and the master node is re-elected, which reduces the stability of the ES cluster

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Method and apparatus for allocating nodes
  • Method and apparatus for allocating nodes
  • Method and apparatus for allocating nodes

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0046] In order to make the object, technical solution and advantages of the present invention clearer, the implementation manner of the present invention will be further described in detail below in conjunction with the accompanying drawings.

[0047] An embodiment of the present invention provides a method for allocating nodes, and the execution subject of the method may be a server. Among them, the server is a server outside the ES cluster, which can belong to the management server of the ES cluster, and an application program (which can be called middleware) is set in the server, which can be used to execute the following figure 1 In the steps shown, the server may be provided with a processor, a memory, and a transceiver, etc., the processor may be used for processing the process of allocating nodes, and the memory may be used for storing data required and generated during the process of allocating nodes, and sending and receiving can be used to receive as well as send da...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The present application provides a method and apparatus for allocating nodes, belonging to the field of computer technology. The method comprises: when allocating nodes to the primary slice of a new index, a first set of indexes in the ES cluster that are open and have aliases may be obtained, a first set of indexes is then filtered, a second index set is obtained, the node name of the node wherethe primary slice of each index in the second index set is located may then be determined, and a node name of a master node in the ES cluster is obtained, the node name of the node where the primary fragment of each index is located and the node name of the primary node are notified to the primary node. When the primary node allocates nodes for the primary fragment of each index, the nodes in theES cluster other than the node where the primary fragment of each index in the second index set is located and the primary node is preferentially selected by the primary node. With the present application, the stability of the ES cluster can be improved.

Description

technical field [0001] The invention relates to the field of computer technology, in particular to a method and device for allocating nodes. Background technique [0002] ElasticSearch (search engine, ES) cluster is an open source, distributed, Restful search engine based on Lucene, generally used in cloud computing, to achieve real-time search, stability, reliability, fast and easy installation and use. [0003] In related technologies, an ElasticSearch cluster includes multiple nodes, and there is a master node among the multiple nodes. The master node is responsible for allocating fragments. The fragments include primary fragments and replica fragments. The replica fragments are copied from the master fragments. When creating an index, generally a preset number of primary shards are assigned to the index, and the preset number of shards are allocated to the nodes in the ES cluster according to the principle of load balancing. [0004] In this way, when the primary shard ...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
Patent Type & Authority Patents(China)
IPC IPC(8): G06F16/22G06F16/27G06F15/16H04L29/08
CPCG06F15/161H04L67/1004
Inventor 钟旺
Owner GUANGZHOU KUGOU COMP TECH CO LTD