CN109325013B - Data management method and device of distributed system - Google Patents

Data management method and device of distributed system Download PDF

Info

Publication number
CN109325013B
CN109325013B CN201810757664.0A CN201810757664A CN109325013B CN 109325013 B CN109325013 B CN 109325013B CN 201810757664 A CN201810757664 A CN 201810757664A CN 109325013 B CN109325013 B CN 109325013B
Authority
CN
China
Prior art keywords
data packet
sent
command
historical
distributed system
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
CN201810757664.0A
Other languages
Chinese (zh)
Other versions
CN109325013A (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.)
China Unionpay Co Ltd
Original Assignee
China Unionpay 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 China Unionpay Co Ltd filed Critical China Unionpay Co Ltd
Priority to CN201810757664.0A priority Critical patent/CN109325013B/en
Publication of CN109325013A publication Critical patent/CN109325013A/en
Application granted granted Critical
Publication of CN109325013B publication Critical patent/CN109325013B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/54Interprogram communication
    • G06F9/543User-generated data transfer, e.g. clipboards, dynamic data exchange [DDE], object linking and embedding [OLE]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/54Interprogram communication
    • G06F9/545Interprogram communication where tasks reside in different layers, e.g. user- and kernel-space

Abstract

The embodiment of the invention relates to the technical field of data processing, in particular to a data management method and device of a distributed system, which are used for increasing the data transmission efficiency in the distributed system. The embodiment of the invention comprises the following steps: determining identification information of a command to be sent; acquiring the content of a data packet to be sent corresponding to the command to be sent from a mapping table according to the identification information; the mapping table is a mapping relation between a command determined according to a historical data packet and the content of the data packet; constructing the data packet to be sent; and transmitting the data packet to be transmitted in a distributed system.

Description

Data management method and device of distributed system
Technical Field
The present invention relates to the field of data processing technologies, and in particular, to a data management method and apparatus for a distributed system.
Background
In existing distributed system environments, configuration and operation typically involve operations on multiple hosts. In an existing distributed system, a user operates through a graphical interface or a command line interface, and the system needs to convert the operation of the graphical interface into a command at an application layer, then send the command from the application layer to a transport layer, and convert the command into a transport layer packet at the transport layer. The process has more steps and low efficiency, and has the risk of improper operation.
Disclosure of Invention
The application provides a data management method and device of a distributed system, which are used for increasing the data transmission efficiency in the distributed system.
The data management method for the distributed system provided by the embodiment of the invention comprises the following steps:
determining identification information of a command to be sent;
acquiring the content of a data packet to be sent corresponding to the command to be sent from a mapping table according to the identification information; the mapping table is a mapping relation between a command determined according to a historical data packet and the content of the data packet;
constructing the data packet to be sent;
and transmitting the data packet to be transmitted in a distributed system.
Optionally, before determining the identification information of the command to be sent, the method further includes:
capturing historical data packets in a distributed system;
analyzing the historical data packet and determining a historical command corresponding to the historical data packet;
and establishing the mapping table.
Optionally, the analyzing the historical data packet and determining the historical command corresponding to the historical data packet includes:
separating the packet header and the data content of the historical data packet;
and extracting a history command corresponding to the history data packet from the data content through a matching algorithm.
Optionally, the sending the data packet to be sent includes:
determining the priority of the data packet to be sent;
according to the priority of the data packet to be sent, the data packet to be sent is placed in a queue to be sent;
and after the length of the queue to be sent reaches a threshold value, all data packets to be sent in the queue to be sent are sent in the distributed system in sequence.
An embodiment of the present invention further provides a data management apparatus for a distributed system, including:
the determining unit is used for determining the identification information of the command to be sent;
the mapping unit is used for acquiring the content of a data packet to be sent corresponding to the command to be sent from a mapping table according to the identification information; the mapping table is a mapping relation between a command determined according to a historical data packet and the content of the data packet;
the construction unit is used for constructing the data packet to be sent;
and the sending unit is used for sending the data packet to be sent in a distributed system.
Optionally, the system further includes a establishing unit, configured to:
capturing historical data packets in a distributed system;
analyzing the historical data packet and determining a historical command corresponding to the historical data packet;
and establishing the mapping table.
Optionally, the establishing unit is specifically configured to:
separating the packet header and the data content of the historical data packet;
and extracting a history command corresponding to the history data packet from the data content through a matching algorithm.
Optionally, the sending unit is specifically configured to:
determining the priority of the data packet to be sent;
according to the priority of the data packet to be sent, the data packet to be sent is placed in a sending queue;
and after the length of the sending queue reaches a threshold value, sending all data packets to be sent in the sending queue in the distributed system in sequence.
An embodiment of the present invention further provides an electronic device, including:
at least one processor; and the number of the first and second groups,
a memory communicatively coupled to the at least one processor; wherein the content of the first and second substances,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the above-described method.
Embodiments of the present invention also provide a non-transitory computer-readable storage medium storing computer instructions for causing a computer to perform the above method.
In the embodiment of the invention, a mapping table is established at first, and the mapping table is the mapping relation between the command determined according to the historical data packet and the content of the data packet. And when the command needs to be sent, generating a corresponding data packet according to the command requirement and the mapping table. Specifically, the identification information of the command to be sent is determined, the content of the data packet to be sent corresponding to the command to be sent is obtained from the mapping table according to the identification information, then the data packet to be sent is constructed, and the data packet to be sent is sent in the distributed system. Embodiments of the present invention download traditional communications from the application layer to the transport layer. In the prior art, commands are communicated at an application layer through a script or a command line, the commands are packaged into a data packet form and transmitted at a transmission layer, the process from graphic interface operation to command operation conversion and from command operation to data packet conversion are omitted, and the data transmission efficiency in a distributed system is improved. On the other hand, in the conventional mode, a plurality of nodes of the distributed system input commands simultaneously and convert the commands into data packets, but in the embodiment of the invention, one node converts command line commands into data packets at one time, so that resources in the distributed system are saved. In addition, in the traditional mode, a plurality of nodes are sent to the plurality of nodes, but the embodiment of the invention sends one node to the plurality of nodes, thereby saving the network bandwidth and avoiding the problem of message asynchronization.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings needed to be used in the description of the embodiments will be briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without inventive exercise.
Fig. 1 is a schematic flowchart of a data management method of a distributed system according to an embodiment of the present invention;
fig. 2 is a schematic diagram of a transmission flow of a data packet to be transmitted according to an embodiment of the present invention;
FIG. 3 is a schematic flow diagram of a distributed Hadoop building process of a Linux cluster provided by an embodiment of the present invention;
fig. 4 is a schematic structural diagram of a data management apparatus of a distributed system according to an embodiment of the present invention;
fig. 5 is a schematic structural diagram of an electronic device according to an embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention clearer, the present invention will be described in further detail with reference to the accompanying drawings, and it is apparent that the described embodiments are only a part of the embodiments of the present invention, not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
The embodiment of the invention provides a data management method of a lower-level distributed system, wherein the level in network communication is between an application layer and a network layer. In the traditional distributed system, data is transmitted at an application layer, and the embodiment of the invention builds a data management tool of the distributed system at a transmission layer. In the generation stage of the data packet, the embodiment of the invention does not need to use the nodes in the distributed system, and only needs to be connected with the distributed system cluster intranet when the data packet is sent.
The embodiment of the invention provides a data management method of a distributed system. As shown in fig. 1, a data management method of a distributed system provided in an embodiment of the present invention includes the following steps:
step 101, determining identification information of a command to be sent.
102, acquiring the content of a data packet to be sent corresponding to the command to be sent from a mapping table according to the identification information; the mapping table is the mapping relation between the command determined according to the historical data packet and the data packet content.
And 103, constructing the data packet to be sent.
And step 104, transmitting the data packet to be transmitted in a distributed system.
In the embodiment of the invention, a mapping table is established at first, and the mapping table is the mapping relation between the command determined according to the historical data packet and the content of the data packet. And when the command needs to be sent, generating a corresponding data packet according to the command requirement and the mapping table. Specifically, the identification information of the command to be sent is determined, the content of the data packet to be sent corresponding to the command to be sent is obtained from the mapping table according to the identification information, then the data packet to be sent is constructed, and the data packet to be sent is sent in the distributed system. Embodiments of the present invention download traditional communications from the application layer to the transport layer. In the prior art, commands are communicated at an application layer through a script or a command line, the commands are packaged into a data packet form and transmitted at a transmission layer, the process from graphic interface operation to command operation conversion and from command operation to data packet conversion are omitted, and the data transmission efficiency in a distributed system is improved. On the other hand, in the conventional mode, a plurality of nodes of the distributed system input commands simultaneously and convert the commands into data packets, but in the embodiment of the invention, one node converts command line commands into data packets at one time, so that resources in the distributed system are saved. In addition, in the traditional mode, a plurality of nodes are sent to the plurality of nodes, but the embodiment of the invention sends one node to the plurality of nodes, thereby saving the network bandwidth and avoiding the problem of message asynchronization.
In the implementation of the present invention, the identification information of the command to be sent may be a keyword of the command to be sent. In the mapping table, multiple keys of a command may correspond to the function of the command, which in turn corresponds to a packet. Therefore, the content of the data packet can be constructed according to the keyword of the command to be sent.
In the embodiment of the present invention, a mapping table is required to be used in the process of packaging the command into the data packet, and the mapping table is constructed by the following method in the embodiment of the present invention, that is, before determining the identification information of the command to be sent in step 101, the method further includes:
capturing historical data packets in a distributed system;
analyzing the historical data packet and determining a historical command corresponding to the historical data packet;
and establishing the mapping table.
Specifically, the embodiment of the invention records the data packet corresponding to the command in the distributed system. If the content of the data packet is encrypted, the key is extracted from the key folder corresponding to the system, and the data packet is decrypted. And storing the data packets into a database after decryption, sorting the data packets according to the sending time of the data packets, and storing the data packets in different data tables according to corresponding priorities. The data packets in the database may be discarded after the mapping table is completed, or the data packets in the database may be retained for checking the accuracy of the newly generated data packets. And then analyzing the captured historical data packet, finding out a historical command corresponding to the historical data packet, establishing a mapping relation between the historical data packet and the corresponding historical command, and storing the mapping relation into a mapping table. The main contents stored in the mapping table may include, but are not limited to: data packet ID, function, variable, socket of master node or central node communication process in the distributed system, socket of slave node or regional node communication process, mapping relation and the like.
Optionally, analyzing the historical data packet, and determining a historical command corresponding to the historical data packet includes:
separating the packet header and the data content of the historical data packet;
and extracting a history command corresponding to the history data packet from the data content through a matching algorithm.
Specifically, the header and data content of each level of the historical data packet are first separated by the network hierarchy. And then extracting key information in the data content, wherein the key information comprises a source address, a destination address, a source port number, a destination port number, a protocol version and the like of the historical data packet. The contents of the history data packet are then analyzed by a matching algorithm for relation to the history command. And checking the contents spliced in the front and back and middle of the character string in the historical data packet, extracting the historical command corresponding to the historical data packet from the contents, obtaining the mapping relation between the historical data packet and the historical command, and storing the mapping relation in a mapping table. In the mapping table, the commands are identified by one or more keywords and correspond to functions. Thus, the corresponding data packet can be determined by using the key word of the command to be sent.
After the mapping table is obtained, a corresponding data packet can be generated according to the command. The required information requires a sender IP address, a receiver IP address, and a variable string in addition to the data content corresponding to the command. Firstly, determining a data packet ID of a data packet to be sent according to a keyword of a command to be sent, and extracting information corresponding to the data packet ID from a database. And then converting the variable character string into the content of the data packet to be sent through the operation described by the corresponding mapping relation in the mapping table. And then adding corresponding data frames, wherein the data frames are generated by the port of the sender and the port of the receiver. And finally, the IP address of the sender and the IP address of the receiver are added to generate a data packet to be sent. And if the content of the data packet to be transmitted needs to be encrypted, encrypting the data packet to be transmitted through the public key of the host of the opposite side or the negotiated secret key.
Furthermore, the embodiment of the invention can control the transmission priority of the data packet to be sent. Step 104, sending the data packet to be sent, including:
determining the priority of the data packet to be sent;
according to the priority of the data packet to be sent, the data packet to be sent is placed in a queue to be sent;
and after the length of the queue to be sent reaches a threshold value, all data packets to be sent in the queue to be sent are sent in the distributed system in sequence.
The embodiment of the invention can control the transmission priority of the data packet to be transmitted, so that the data packet with higher priority can be transmitted quickly, thereby improving the real-time property. Specifically, after a new data packet to be sent is generated, the new data packet to be sent is placed at a corresponding position of a queue to be sent, such as a head of the queue, a middle of the queue, or a tail of the queue, according to the priority of the data packet to be sent. And after the queue to be sent reaches a certain length, sequentially sending all the data packets to be sent in the queue to be sent according to the sequence. Optionally, if the priority of the data packet to be sent is the highest level, the data packet to be sent is not placed in the queue to be sent, and is directly sent.
The transmission flow of the data packet to be transmitted is shown in fig. 2, and includes the following steps:
step 201, generating a data packet to be sent.
Step 202, determining whether the data packet to be sent needs to be sent immediately, if so, executing step 206, otherwise, executing step 203.
Step 203, calculating the position of the data packet in the queue to be sent according to the priority of the data packet to be sent.
And step 204, adding the data packet to be sent to a corresponding position in a queue to be sent.
Step 205, determining whether the length of the queue to be sent reaches a threshold, if yes, executing step 206, otherwise, executing step 201.
And step 206, sending the data packet to be sent.
In the embodiment of the invention, after the data packet to be sent is sent, whether the execution is successful can be judged according to the result returned by the receiver. If no reply is received due to a timeout, retransmission is required. The data packet to be sent can also be set as that the receiver does not reply, and only the receiver needs to be confirmed to receive the data packet.
In order to more clearly understand the present invention, the following takes Linux (an operating system) cluster building distributed Hadoop (a distributed system infrastructure) as an example to describe the above flow in detail. The specific steps are shown in fig. 3, and include:
step 301, capturing historical data packets. Specifically, when the hadoop is established in the command line, network monitoring software such as Wireshark or Fiddler is used for recording the transmitted data packet. And then, going to a folder-/. ssh/, where each host key is located, saving the id _ rsa.pub in the folder, and decrypting the monitored data packet to obtain a plaintext.
Step 302, store these decrypted historical data packets into a database. If the number of the historical data packets is small, the historical data packets can be stored in internal memory databases such as Ignite and Redis, and the historical data can be released after step 303 is completed, so that the processing speed is increased. If the historical data packet is large or the data packet to be transmitted needs to be checked after a new data packet is generated, the historical data packet can be stored in a traditional database or a data file.
Step 303, analyzing the historical data packet. And separating the packet header and the data content of the historical data packet, and extracting the IP address and the port in the packet header.
And step 304, generating a mapping relation between the historical command and the historical data packet, and adding the mapping relation into a mapping table. And identifying host names, databases, data tables and the like in the data content, and extracting the context and the corresponding relation between the data packet and the key words of the command. Specifically, the format of the data content is analyzed to determine whether decoding using base64, Unicode, and UTF-8 is required. The location of the history command in the history data packet is then found by string matching methods such as KMP and Boyer-Moore algorithm. If the historical command cannot be found, the other characters are inserted into the historical data packet in the mapping process, so that the starting position of the stable interval data in the data content is found by using a subsequence matching method, and the corresponding historical command is determined by using the stable interval data. And representing the historical data packet and the historical command into a mapping relation and storing the historical data packet and the historical command into a mapping table according to the sequence number. The function description items in the mapping table need to be added manually by operation and maintenance personnel, and only a prompt function is provided, and the function implementation is not influenced when the function description items are not added. The mapping table content intercept is shown in table 1.
TABLE 1
Figure BDA0001727115390000091
And 305, when a new cluster environment is met and hadoop needs to be deployed, finding the data content of the corresponding data packet from the mapping table according to the key words of the command needing to be sent, and replaying the data content in sequence to generate the data packet. When generating a packet, variables such as a host name and an IP address need to be substituted. If the command in configuration is that the content needs to be modified, such as setting a password, establishing a database name, etc., the corresponding mapping relation is searched to generate a proper data packet. Meanwhile, due to the difference of the number of machines and the configuration, the length of the newly generated data packet sequence can be different. When a new data packet is generated, a check data packet can be generated according to the mapping relation and the instruction in the initial configuration, and compared with the historical data packet to verify the correctness of the mapping table generated according to the historical data packet.
Step 306, selecting whether to encrypt according to the configuration of the distributed system communication. Encryption needs to be performed by acquiring corresponding keys according to addresses of the transmitting party and the receiving party.
And 307, playing back the newly generated data packet by using a tool such as netcat, libnet, Winpcap or Kelai data packet player and the like, so as to finish Hadoop configuration among the distributed clusters.
And 308, according to the received feedback message, confirming the successful delivery of the data packet and finishing the transmission.
It should be noted that any node device may be used in the generation process of the data packet, and the transmission of the data packet only needs to be in the distributed cluster intranet environment, and is not limited to the node device in the distributed cluster.
An embodiment of the present invention further provides a data management apparatus for a distributed system, as shown in fig. 4, including:
a determining unit 401, configured to determine identification information of a command to be sent;
a mapping unit 402, configured to obtain, according to the identification information, content of a to-be-sent data packet corresponding to the to-be-sent command from a mapping table; the mapping table is a mapping relation between a command determined according to a historical data packet and the content of the data packet;
a constructing unit 403, configured to construct the data packet to be sent;
a sending unit 404, configured to send the data packet to be sent in a distributed system.
Further, a establishing unit 405 is further included for:
capturing historical data packets in a distributed system;
analyzing the historical data packet and determining a historical command corresponding to the historical data packet;
and establishing the mapping table.
Further, the establishing unit 405 is specifically configured to:
separating the packet header and the data content of the historical data packet;
and extracting a history command corresponding to the history data packet from the data content through a matching algorithm.
Further, the sending unit 404 is specifically configured to:
determining the priority of the data packet to be sent;
according to the priority of the data packet to be sent, the data packet to be sent is placed in a sending queue;
and after the length of the sending queue reaches a threshold value, sending all data packets to be sent in the sending queue in the distributed system in sequence.
Based on the same principle, the present invention also provides an electronic device, as shown in fig. 5, including:
the system comprises a processor 501, a memory 502, a transceiver 503 and a bus interface 504, wherein the processor 501, the memory 502 and the transceiver 503 are connected through the bus interface 504;
the processor 501 is configured to read the program in the memory 502, and execute the following method:
determining identification information of a command to be sent;
acquiring the content of a data packet to be sent corresponding to the command to be sent from a mapping table according to the identification information; the mapping table is a mapping relation between a command determined according to a historical data packet and the content of the data packet;
constructing the data packet to be sent;
and transmitting the data packet to be transmitted in a distributed system.
Further, the processor 501 is specifically configured to:
capturing historical data packets in a distributed system;
analyzing the historical data packet and determining a historical command corresponding to the historical data packet;
and establishing the mapping table.
Further, the processor 501 is specifically configured to:
separating the packet head and the data content of the historical data packet;
and extracting a history command corresponding to the history data packet from the data content through a matching algorithm.
Further, the processor 501 is specifically configured to:
determining the priority of the data packet to be sent;
according to the priority of the data packet to be sent, the data packet to be sent is placed in a queue to be sent;
and after the length of the queue to be sent reaches a threshold value, all data packets to be sent in the queue to be sent are sent in the distributed system in sequence.
The present invention is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
While preferred embodiments of the present invention have been described, additional variations and modifications in those embodiments may occur to those skilled in the art once they learn of the basic inventive concepts. Therefore, it is intended that the appended claims be interpreted as including preferred embodiments and all such alterations and modifications as fall within the scope of the invention.
It will be apparent to those skilled in the art that various changes and modifications may be made in the present invention without departing from the spirit and scope of the invention. Thus, if such modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include such modifications and variations.

Claims (10)

1. A method for managing data in a distributed system, comprising:
determining identification information of a command to be sent;
acquiring the data packet content of the data packet to be sent corresponding to the command to be sent from a mapping table according to the identification information; the mapping table is a mapping relation between a command determined according to a historical data packet and the content of the data packet; the command corresponding to the historical data packet is obtained by checking the contents spliced in the historical data packet before, after and in the middle of the character string; the mapping table includes: data packet ID, function, variable, socket of master node or central node communication process in distributed system, socket of slave node or regional node communication process, and mapping relation;
constructing the data packet to be sent;
sending the data packet to be sent in a distributed system;
wherein constructing the to-be-transmitted data packet comprises:
and converting the variable character string into the content of a data packet to be sent through the operation described by the variables in the mapping table and the corresponding mapping relation, and then adding the sender port, the receiver port, the sender IP address and the receiver IP address to generate the data packet to be sent.
2. The method of claim 1, wherein prior to determining the identification information for the command to be sent, further comprising:
capturing historical data packets in a distributed system;
analyzing the historical data packet and determining a historical command corresponding to the historical data packet;
and establishing the mapping table.
3. The method of claim 2, wherein said analyzing said historical data packet to determine a historical command to which said historical data packet corresponds comprises:
separating the packet header and the data content of the historical data packet;
and extracting a history command corresponding to the history data packet from the data content through a matching algorithm.
4. The method according to any one of claims 1 to 3, wherein said transmitting the data packet to be transmitted comprises:
determining the priority of the data packet to be sent;
according to the priority of the data packet to be sent, the data packet to be sent is placed in a queue to be sent;
and after the length of the queue to be sent reaches a threshold value, all data packets to be sent in the queue to be sent are sent in the distributed system in sequence.
5. A data management apparatus for a distributed system, comprising:
the determining unit is used for determining the identification information of the command to be sent;
the mapping unit is used for acquiring the data packet content of the data packet to be sent corresponding to the command to be sent from a mapping table according to the identification information; the mapping table is a mapping relation between a command determined according to a historical data packet and the content of the data packet; the command corresponding to the historical data packet is obtained by checking the contents spliced in the historical data packet before, after and in the middle of the character string; the mapping table includes: data packet ID, function, variable, socket of master node or central node communication process in distributed system, socket of slave node or regional node communication process, and mapping relation;
the construction unit is used for constructing the data packet to be sent;
a sending unit, configured to send the data packet to be sent in a distributed system;
the construction unit is specifically configured to:
and converting the variable character string into the content of a data packet to be sent through the operation described by the variables in the mapping table and the corresponding mapping relation, and then adding the sender port, the receiver port, the sender IP address and the receiver IP address to generate the data packet to be sent.
6. The apparatus of claim 5, further comprising a setup unit to:
capturing historical data packets in a distributed system;
analyzing the historical data packet and determining a historical command corresponding to the historical data packet;
and establishing the mapping table.
7. The apparatus according to claim 6, wherein the establishing unit is specifically configured to:
separating the packet header and the data content of the historical data packet;
and extracting a history command corresponding to the history data packet from the data content through a matching algorithm.
8. The apparatus according to any one of claims 5 to 7, wherein the sending unit is specifically configured to:
determining the priority of the data packet to be sent;
according to the priority of the data packet to be sent, the data packet to be sent is placed in a sending queue;
and after the length of the sending queue reaches a threshold value, sending all data packets to be sent in the sending queue in the distributed system in sequence.
9. An electronic device, comprising:
at least one processor; and the number of the first and second groups,
a memory communicatively coupled to the at least one processor; wherein the content of the first and second substances,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the method of any one of claims 1-4.
10. A non-transitory computer readable storage medium storing computer instructions for causing a computer to perform the method of any one of claims 1 to 4.
CN201810757664.0A 2018-07-11 2018-07-11 Data management method and device of distributed system Active CN109325013B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810757664.0A CN109325013B (en) 2018-07-11 2018-07-11 Data management method and device of distributed system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810757664.0A CN109325013B (en) 2018-07-11 2018-07-11 Data management method and device of distributed system

Publications (2)

Publication Number Publication Date
CN109325013A CN109325013A (en) 2019-02-12
CN109325013B true CN109325013B (en) 2022-07-08

Family

ID=65263648

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810757664.0A Active CN109325013B (en) 2018-07-11 2018-07-11 Data management method and device of distributed system

Country Status (1)

Country Link
CN (1) CN109325013B (en)

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102404306A (en) * 2010-09-19 2012-04-04 腾讯科技(深圳)有限公司 Protocol configuration method and device
CN104111955A (en) * 2013-04-22 2014-10-22 中国银联股份有限公司 Combined inquiring method oriented to Hbase database
CN104268277A (en) * 2014-10-15 2015-01-07 北京国双科技有限公司 Data reading method and device for database
CN105550263A (en) * 2015-12-05 2016-05-04 百势软件(北京)有限公司 Assignment method and device in object-relational mapping
CN105956481A (en) * 2015-09-17 2016-09-21 中国银联股份有限公司 Data processing method and device
CN107463657A (en) * 2017-07-28 2017-12-12 腾讯科技(深圳)有限公司 File operation method and terminal

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8458218B2 (en) * 2010-09-13 2013-06-04 Sybase, Inc. Incremental data transfer in a database management system

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102404306A (en) * 2010-09-19 2012-04-04 腾讯科技(深圳)有限公司 Protocol configuration method and device
CN104111955A (en) * 2013-04-22 2014-10-22 中国银联股份有限公司 Combined inquiring method oriented to Hbase database
CN104268277A (en) * 2014-10-15 2015-01-07 北京国双科技有限公司 Data reading method and device for database
CN105956481A (en) * 2015-09-17 2016-09-21 中国银联股份有限公司 Data processing method and device
CN105550263A (en) * 2015-12-05 2016-05-04 百势软件(北京)有限公司 Assignment method and device in object-relational mapping
CN107463657A (en) * 2017-07-28 2017-12-12 腾讯科技(深圳)有限公司 File operation method and terminal

Also Published As

Publication number Publication date
CN109325013A (en) 2019-02-12

Similar Documents

Publication Publication Date Title
US10862871B2 (en) Hardware-accelerated payload filtering in secure communication
US10747721B2 (en) File management/search system and file management/search method based on block chain
CN111201754B (en) Device for providing cryptographically protected and filtered and ordered collection of transaction data sets for links of a blockchain
EP3211852A1 (en) Ssh protocol-based session parsing method and system
CN110995513B (en) Data sending and receiving method in Internet of things system, internet of things equipment and platform
US20200213331A1 (en) Data service system
CN110059055B (en) File storage and reading method and device based on distributed private cloud
CN111061685B (en) Log query method and device, node equipment and storage medium
US11831763B2 (en) Methods, systems, and computer readable media for utilizing predetermined encryption keys in a test simulation environment
CN110830442A (en) Message processing method, device and gateway
CN115118705A (en) Industrial edge management and control platform based on micro-service
US10129360B2 (en) Unified data networking across heterogeneous networks
CN106254392B (en) Communication method based on dynamically customizable exT L V message transmission protocol
CN101753456B (en) Method and system for detecting flow of peer-to-peer network
CN107835080B (en) Distributed system data collection method and data signature generation method
CN111327561A (en) Authentication method, system, authentication server, and computer-readable storage medium
CN109325013B (en) Data management method and device of distributed system
CN112667586B (en) Method, system, equipment and medium for synchronizing data based on stream processing
CN113922972B (en) Data forwarding method and device based on MD5 identification code
WO2020106326A1 (en) Extending encrypted traffic analytics with traffic flow data
CN114785805A (en) Data transmission method and device, electronic equipment and storage medium
JP2019029921A (en) Transmitter, receiver, and communication method
CN111182085B (en) Method, system, device and storage medium for controlling message forwarding based on multi-stage flow table
CN112350920A (en) Instant communication system based on block chain
CN104980352A (en) Routing method and device for multiline computer room

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