CN112995095A - Data processing method, device and computer readable storage medium - Google Patents

Data processing method, device and computer readable storage medium Download PDF

Info

Publication number
CN112995095A
CN112995095A CN201911281040.7A CN201911281040A CN112995095A CN 112995095 A CN112995095 A CN 112995095A CN 201911281040 A CN201911281040 A CN 201911281040A CN 112995095 A CN112995095 A CN 112995095A
Authority
CN
China
Prior art keywords
data
sender
receiver
identification
target
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.)
Granted
Application number
CN201911281040.7A
Other languages
Chinese (zh)
Other versions
CN112995095B (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.)
Beijing Jingdong Qianshi Technology Co Ltd
Original Assignee
Beijing Jingdong Qianshi Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Jingdong Qianshi Technology Co Ltd filed Critical Beijing Jingdong Qianshi Technology Co Ltd
Priority to CN201911281040.7A priority Critical patent/CN112995095B/en
Publication of CN112995095A publication Critical patent/CN112995095A/en
Application granted granted Critical
Publication of CN112995095B publication Critical patent/CN112995095B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/16Implementation or adaptation of Internet protocol [IP], of transmission control protocol [TCP] or of user datagram protocol [UDP]
    • H04L69/164Adaptation or special uses of UDP protocol
    • 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/12Protocols specially adapted for proprietary or special-purpose networking environments, e.g. medical networks, sensor networks, networks in vehicles or remote metering networks
    • 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/133Protocols for remote procedure calls [RPC]

Abstract

The disclosure provides a data processing method, a data processing device and a computer readable storage medium, and relates to the technical field of unmanned vehicles. The data processing method comprises the following steps: the data sending method comprises the steps that a first discovery message is broadcasted to a preset port of a local network by a data sending party, and the first discovery message comprises an identification of the data sending party, a network address of the data sending party, a process identification of the data sending party and a theme identification of the data sending party; the data receiving side broadcasts a second discovery message to a preset port of the local network, wherein the second discovery message comprises an identifier of a data receiving side, a network address of the data receiving side, a remote procedure call server port address of the data receiving side, a process identifier of the data receiving side and a theme identifier of the data receiving side; and the local network monitors a preset port and stores the first discovery message and the second discovery message. The method and the device can improve the stability of the unmanned vehicle communication system and save the resource consumption of the unmanned vehicle communication system.

Description

Data processing method, device and computer readable storage medium
Technical Field
The present disclosure relates to the field of unmanned vehicles, and in particular, to a data processing method and apparatus, and a computer-readable storage medium.
Background
A conventional communication System of the unmanned vehicle employs an ROS (robot Operating System). ROS is UDP (User Datagram Protocol) communication based on a server-client network structure.
The Master node masters all relevant publish and subscribe information, and all messages need to be transmitted by the Master node. Therefore, once the master node is abnormal, the on-line communication system of the unmanned vehicle stops running, and the stability of the communication system of the unmanned vehicle is poor.
Meanwhile, since UDP is mainly real-time and efficient, and whether transmitted data is successfully transmitted or not is not checked, the ROS system cannot guarantee that a communication message can be successfully received. This causes a problem of packet loss in unmanned in-vehicle communication using the ROS.
In addition, the ROS system is based on UDP, and all communications within and within the same station are networked via UDP, which consumes a lot of system resources.
The solution of multiple master nodes is adopted, and the online communication system of the unmanned vehicle is required to maintain the multiple master nodes simultaneously. Once the current master node is abnormal, it is immediately replaced with a backup master node. The disadvantage of this solution is that the system resources consumed are too large because the master node itself consumes a lot of system resources, and maintaining multiple master nodes at the same time.
Disclosure of Invention
The technical problem that this disclosure solved is how this disclosure can improve unmanned vehicle communication system's stability, and the resource consumption of saving unmanned vehicle communication system.
According to an aspect of the embodiments of the present disclosure, there is provided a data processing method, including: the method comprises the steps that a data sending direction broadcasts a first discovery message to a preset port of a local network, wherein the first discovery message comprises an identification of a data sending party, a network address of the data sending party, a process identification of the data sending party and a theme identification of the data sending party; the data receiving side broadcasts a second discovery message to a preset port of the local network, wherein the second discovery message comprises an identifier of a data receiving side, a network address of the data receiving side, a remote procedure call server port address of the data receiving side, a process identifier of the data receiving side and a theme identifier of the data receiving side; the data sender and the data sender are located at the same node or different nodes of the distributed unmanned vehicle communication system; and the local network monitors the preset port and stores the first discovery message and the second discovery message.
In some embodiments, the data processing method further comprises: a data sender acquires a data sender, wherein the data sender comprises an in-process data sending interface, an inter-process data sending interface and an inter-machine data sending interface; a data receiver acquires a data receiver; and the data receiver registers the subject identification of the data receiver and the callback function of the data receiver in the notification center.
In some embodiments, the data processing method further comprises: the data sender inputs the target data and the subject identification of the data sender into the data sender; the data sender queries the local network by using the subject identifier of the data sender to acquire the network address and the process identifier of the data receiver subscribed with the target data and acquire the network address and the process identifier of the data sender; the data sender sends the target data and the subject identification of the data sender to the data receiver according to the network address and the process identification of the data receiver subscribed with the target data and the network address and the process identification of the data sender; the data receiver sends the theme identification of the data sender to a notification center; and the notification center triggers a callback function of a data receiver subscribed with the target data by using the theme identification of the data sender so as to process the target data in the data receiver.
In some embodiments, the sending, by the data sender, the target data and the subject identifier of the data sender to the data receiver according to the network address and the process identifier of the data receiver subscribed with the target data and the network address and the process identifier of the data sender includes: under the condition that the network address of the data receiver subscribed with the target data is the same as the network address of the data sender, and the process identification of the data receiver subscribed with the target data is the same as the process identification of the data sender, the in-process data sending interface of the data sender sends the target data and the subject identification of the data sender to the data receiver of the current process.
In some embodiments, the sending, by the data sender, the target data and the subject identifier of the data sender to the data receiver according to the network address and the process identifier of the data receiver subscribed with the target data and the network address and the process identifier of the data sender includes: under the condition that the network address of a data receiver subscribed with target data is the same as the network address of a data sender and the process identification of the data receiver subscribed with the target data is different from the process identification of the data sender, an inter-process data sending interface of a data sender writes the target data and the subject identification of the data sender into a dynamically allocated memory block and sends the address of the memory block to a local network; the data receiver receives the address of the memory block, and reads the memory block to obtain target data and the theme identification of the data sender; and the data receiver sends the target data and the subject identification of the data sender to the data receiver.
In some embodiments, sending the target data and the subject identification of the data sender to the data receiver by the data receiver comprises: and after the data receiver verifies that the subject identification of the data receiver comprises the subject identification of the data sender, the target data and the subject identification of the data sender are sent to the data receiver.
In some embodiments, when the data transmitter transmits the address of the memory block to the local network, the data transmitter also transmits a check code of the memory block; the data receiver sends the target data and the subject identification of the data sender to the data receiver, and the data receiver comprises: the data receiving party receives the check code of the memory block and verifies the data in the memory block by using the check code of the memory block; and after the data receiver successfully verifies, the data receiver sends the target data and the subject identification of the data sender to the data receiver.
In some embodiments, the sending, by the data sender, the target data and the subject identifier of the data sender to the data receiver according to the network address and the process identifier of the data receiver subscribed with the target data and the network address and the process identifier of the data sender includes: under the condition that the network address of a data receiver subscribing the target data is different from the network address of a data sender, a data sending interface between machines of the data sender sends the target data and the subject identification of the data sender to a remote procedure call server through a remote procedure call client; and the remote procedure call server sends the target data and the subject identification of the data sender to the data receiver.
In some embodiments, the sending, by the data sender, the target data and the subject identifier of the data sender to the data receiver according to the network address and the process identifier of the data receiver subscribed with the target data and the network address and the process identifier of the data sender further includes: the data sender queries the local network by using the subject identification of the data sender to acquire the port address of the remote procedure call server of the data receiver subscribed with the target data; the data transmitter determines an address of a remote procedure call server using a port address and a network address of the remote procedure call server of the data receiver subscribed to the target data.
According to another aspect of the embodiments of the present disclosure, there is provided a data processing apparatus including: a data sender configured to: broadcasting a first discovery message to a preset port of a local network, wherein the first discovery message comprises an identifier of a data sender, a network address of the data sender, a process identifier of the data sender and a subject identifier of the data sender; a data receiver configured to: broadcasting a second discovery message to a preset port of a local network, wherein the second discovery message comprises an identifier of a data receiver, a network address of the data receiver, a remote procedure call server port address of the data receiver, a process identifier of the data receiver and a theme identifier of the data receiver; the data sender and the data sender are located at the same node or different nodes of the distributed unmanned vehicle communication system; and the local network is configured to monitor the preset port and store the first discovery message and the second discovery message.
In some embodiments, the data processing apparatus further comprises a data transmitter, a data receiver, a notification center; the data sender is further configured to: acquiring a data transmitter, wherein the data transmitter comprises an in-process data transmitting interface, an inter-process data transmitting interface and an inter-machine data transmitting interface; the data receiver is further configured to: acquiring a data receiver; and registering the subject identification of the data receiver and the callback function of the data receiver in the notification center.
In some embodiments, the data sender is further configured to: acquiring a data transmitter, and inputting target data and a subject identification of the data transmitter into the data transmitter; the data transmitter is configured to: inquiring a local network by using the subject identification of the data sender to acquire the network address and the process identification of the data receiver subscribed with the target data and acquire the network address and the process identification of the data sender; according to the network address and the process identification of the data receiver subscribed with the target data and the network address and the process identification of the data sender, sending the target data and the subject identification of the data sender to the data receiver; the data receiver is configured to: the theme identification of the data sender is sent to a notification center; the notification center is configured to: and triggering a callback function of a data receiver subscribed with the target data by using the topic identification of the data sender so as to process the target data in the data receiver.
In some embodiments, the data transmitter is configured to: under the condition that the network address of the data receiver subscribed with the target data is the same as the network address of the data sender, and the process identification of the data receiver subscribed with the target data is the same as the process identification of the data sender, the in-process data sending interface of the data sender sends the target data and the subject identification of the data sender to the data receiver of the current process.
In some embodiments, the data transmitter is configured to: under the condition that the network address of a data receiver subscribed with target data is the same as the network address of a data sender and the process identification of the data receiver subscribed with the target data is different from the process identification of the data sender, an inter-process data sending interface of a data sender writes the target data and the subject identification of the data sender into a dynamically allocated memory block and sends the address of the memory block to a local network; the data receiver is further configured to: receiving the address of the memory block, and reading the memory block to obtain target data and a theme identifier of a data sender; and sending the target data and the subject identification of the data sender to the data receiver.
In some embodiments, the data receiver is configured to: and after the theme identification of the data receiver is verified to contain the theme identification of the data sender, the target data and the theme identification of the data sender are sent to the data receiver.
In some embodiments, the data transmitter is configured to: when the address of the memory block is sent to the local network, the check code of the memory block is also sent; the data receiver is configured to: receiving the check code of the memory block, and verifying the data in the memory block by using the check code of the memory block; and after the verification is successful, sending the target data and the subject identification of the data sender to the data receiver.
In some embodiments, the data processing apparatus further comprises a remote procedure call server; the data transmitter is configured to: under the condition that the network address of a data receiver subscribing the target data is different from the network address of a data sender, a data sending interface between machines of the data sender sends the target data and the subject identification of the data sender to a remote procedure call server through a remote procedure call client; and the remote procedure call server sends the target data and the subject identification of the data sender to the data receiver.
In some embodiments, the data transmitter is further configured to: inquiring a local network by using the subject identification of the data sender to acquire the remote procedure call server port address of the data receiver subscribed with the target data; and determining the address of the remote procedure call server by utilizing the port address and the network address of the remote procedure call server of the data receiver subscribed with the target data.
According to still another aspect of an embodiment of the present disclosure, there is provided a data processing apparatus including: a memory; and a processor coupled to the memory, the processor configured to perform the aforementioned data processing method based on instructions stored in the memory.
According to still another aspect of the embodiments of the present disclosure, there is provided a computer-readable storage medium, wherein the computer-readable storage medium stores computer instructions, and the instructions, when executed by a processor, implement the aforementioned data processing method.
The method and the device can improve the stability of the unmanned vehicle communication system and save the resource consumption of the unmanned vehicle communication system.
Other features of the present disclosure and advantages thereof will become apparent from the following detailed description of exemplary embodiments thereof, which proceeds with reference to the accompanying drawings.
Drawings
In order to more clearly illustrate the embodiments of the present disclosure or the technical solutions in the prior art, the drawings needed to be used in the description of the embodiments or the prior art will be briefly introduced below, it is obvious that the drawings in the following description are only some embodiments of the present disclosure, and for those skilled in the art, other drawings can be obtained according to the drawings without inventive exercise.
Fig. 1 shows a schematic diagram of the connection relationship of the respective machines.
Fig. 2 shows a message flow diagram of a process.
Fig. 3 shows a flow diagram of a data processing method of some embodiments of the present disclosure.
FIG. 4 shows a flow diagram of a data processing method according to further embodiments of the present disclosure.
Fig. 5 shows a schematic structural diagram of a data processing apparatus according to some embodiments of the present disclosure.
Fig. 6 shows a schematic structural diagram of a data processing apparatus according to further embodiments of the present disclosure.
Detailed Description
The technical solutions in the embodiments of the present disclosure will be clearly and completely described below with reference to the drawings in the embodiments of the present disclosure, and it is obvious that the described embodiments are only a part of the embodiments of the present disclosure, and not all of the embodiments. The following description of at least one exemplary embodiment is merely illustrative in nature and is in no way intended to limit the disclosure, its application, or uses. All other embodiments, which can be derived by a person skilled in the art from the embodiments disclosed herein without making any creative effort, shall fall within the protection scope of the present disclosure.
To solve the above problem, the present disclosure provides an intelligent distributed communication system. The intelligent distributed communication system runs on each machine on one or more processes, each process comprises one or more nodes. It will be understood by those skilled in the art that all threads of the same process share the memory of the process, and that the memory of different processes are independent of each other.
Fig. 1 shows a schematic diagram of the connection relationship of the respective machines. As shown in fig. 1, there is a network connection between machine 1 and machine 2; the network address of the machine 1 is 192.168.1.1, and the process A and the process B run on the machine 1; machine 2 has a network address of 192.168.1.2, and process C and process D run on machine 2. Fig. 2 shows a message flow diagram of a process. As shown in fig. 2, a plurality of nodes exist in the process a, and a plurality of data senders and data receivers exist in each node. Each data sender corresponds to one theme, and each data receiver corresponds to one or more themes. Messages of different topics may have the same or different message types. Assuming that the theme 1 is a camera and the theme 2 is a graphical interface, the message types corresponding to the theme 1 and the theme 2 are both pictures, and the message types are in one-to-one correspondence with the message senders. The message sender comprises an in-process message sending interface, an inter-process message sending interface and an inter-machine message sending interface. The inter-process message sending interface is in signal connection with the memory distributor, and the inter-machine message sending interface is in signal connection with the remote procedure call client. The remote procedure call client may send a message to the local network and the remote procedure call server may receive the message from the local network and send it to the message receiver. The message receiver is connected with the notification center through signals, and the notification center is connected with the message receiver through signals. As can be seen from the figure, the Master node does not exist in the intelligent distributed communication system provided by the present disclosure.
Some embodiments of the disclosed data processing method are described below with reference to fig. 3 to introduce a data subscription process of an intelligent distributed communication system.
Fig. 3 shows a flow diagram of a data processing method of some embodiments of the present disclosure. As shown in fig. 3, the present embodiment includes steps S301 to S303.
In step S301, the data transmission side broadcasts a first discovery message to a preset port M of the local network.
The first discovery message comprises an identification of a data sender, a network address of the data sender, a process identification of the data sender and a subject identification of the data sender.
In step S302, the data receiving side broadcasts a second discovery message to a preset port M of the local network.
The second discovery message comprises an identifier of the data receiver, a network address of the data receiver, a remote procedure call server port address of the data receiver, a process identifier of the data receiver and a subject identifier of the data receiver.
Those skilled in the art will appreciate that the data sender and the data sender may be located at the same node or different nodes of the distributed unmanned vehicle communication system. The data sender may use RTPS (Real Time Publish subscription Protocol) when broadcasting the first discovery message and the data receiver broadcasts the second discovery message.
In step S303, the local network monitors the predetermined port M and stores the first discovery message and the second discovery message.
Since there may be a plurality of data senders and a plurality of data receivers, the local network may receive a plurality of first discovery messages and a plurality of second discovery messages. The home network will save all the heard discovery messages.
The embodiment can autonomously discover the data sender and the data receiver and realize the data subscription of the data receiver to the data sender. According to the embodiment, a UDP (user Datagram protocol) is not adopted any more, the stability of the unmanned vehicle communication system can be improved, and the resource consumption of the unmanned vehicle communication system is saved.
In some embodiments, the data processing method further includes steps S304 to S306.
In step S304, the data transmitting side acquires the data transmitter.
If no data sender exists, the data sender may create a data sender. The data transmitter comprises an intra-process data transmission interface, an inter-process data transmission interface and an inter-machine data transmission interface.
In step S305, the data receiver acquires the data receiver.
If no data receiver exists, the data sender may create a data receiver.
In step S306, the data receiving side registers the subject identifier of the data receiving side and the callback function of the data receiving side in the notification center.
The notification center may store the registered callback functions through a hash table. And after the successful registration, the notification center stores a key value relationship between the subject identification of the data receiver and the callback function of the data receiver, wherein the key is a hash value of the subject identification of the data receiver, and the value is a pointer array of the callback function of the data receiver.
The embodiment realizes the acquisition work of the data transmitter and the data receiver, and realizes the registration of the callback function in the notification center, so that the notification center triggers the callback function after the subsequent data receiver receives the subscribed data, and the subscribed data is processed.
Further embodiments of the data processing method of the present disclosure are described below with reference to fig. 4 to introduce data transmission procedures of the intelligent distributed communication system.
FIG. 4 shows a flow diagram of a data processing method according to further embodiments of the present disclosure. As shown in fig. 4, the present embodiment includes steps S401 to S405.
In step S401, the data sender inputs the target data and the subject identification of the data sender to the data sender.
For example, the data sender may call the data sender transmitter < T > and pass in the data to be sent tdata.
In step S402, the data sender queries the local network by using the topic identifier of the data sender to obtain the network address and the process identifier of the data receiver subscribed with the target data, and obtains the network address and the process identifier of the data sender.
In step S403, the data transmitter transmits the target data and the subject identifier of the data transmitter to the data receiver according to the network address and the process identifier of the data receiver subscribed with the target data and the network address and the process identifier of the data transmitter.
the transmitter < T > can determine whether to specifically invoke intra-process communication, inter-process communication or inter-machine communication, according to the network address and the process identifier of the data receiver subscribed with the target data and the network address and the process identifier of the data sender. Step S403 can be specifically divided into three cases.
The first condition is as follows: in-process communication
Under the condition that the network address of the data receiver subscribed with the target data is the same as the network address of the data sender, and the process identification of the data receiver subscribed with the target data is the same as the process identification of the data sender, the in-process data sending interface of the data sender can call the data receiver < T > of the current process, and send the target data and the subject identification of the data sender to the data receiver < T > of the current process.
Case two: inter-process communication
Under the condition that the network address of the data receiver subscribed with the target data is the same as the network address of the data sender, and the process identification of the data receiver subscribed with the target data is different from the process identification of the data sender, the data sender can actively allocate a section of memory block with a proper size through an inter-process data sending interface of the data sender, write the target data and the subject identification of the data sender into the dynamically allocated memory block, and send related information such as the address of the memory block to a local network. And the data receiver receives the address of the memory block, reads the memory block to obtain the target data and the subject identification of the data sender, and sends the target data and the subject identification of the data sender to the data receiver.
In some embodiments, before the data receiver sends the target data and the subject identifier of the data sender to the data receiver, the data receiver may verify the target data and the subject identifier of the data sender, and send the target data and the subject identifier of the data sender to the data receiver after the verification is successful.
For example, the data receiver may verify that the subject identifier of the data receiver includes the subject identifier of the data sender, and then send the target data and the subject identifier of the data sender to the data receiver.
For another example, when the data transmitter transmits the address of the memory block to the local network, the data transmitter also transmits the check code of the memory block. The data receiver may receive the check code of the memory block, and verify the data in the memory block by using the check code of the memory block. And after the data receiver successfully verifies, the data receiver sends the target data and the subject identification of the data sender to the data receiver.
Case three: inter-machine communication
And under the condition that the network address of the data receiver subscribed with the target data is different from the network address of the data sender, the data sending interface between the machines of the data sender sends the data to the corresponding machine address through remote procedure call. Specifically, a data sending interface between machines of a data sender sends target data and a subject identification of the data sender to a remote procedure call server through a remote procedure call client; and the remote procedure call server sends the target data and the subject identification of the data sender to the data receiver.
The data sender can query the local network by using the topic identifier of the data sender to obtain the port address of the remote procedure call server of the data receiver subscribed with the target data. The data transmitter further determines an address of the remote procedure call server using the port address and the network address of the remote procedure call server of the data receiver subscribed to the target data.
In step S404, the data receiver sends the subject identification of the data sender to the notification center.
In step S405, the notification center triggers a callback function of a data receiver subscribing to the target data by using the topic identifier of the data sender, so as to process the target data in the data receiver.
For example, the notification center searches for the same topic identifier of the receiver by using the topic identifier of the data sender, thereby triggering the callback function corresponding to the same topic identifier of the receiver.
The embodiment provides a data transmission process of the intelligent distributed communication system, and the corresponding communication mode can be automatically selected according to the actual situation, so that the stability of the unmanned vehicle communication system is improved, and the resource consumption of the unmanned vehicle communication system is saved.
The dataflow process in the present disclosure may communicate with a remote server and a hardware layer using a REST architecture and a socket, respectively. The intelligent distributed communication system in the disclosure can also provide external API services using REST architecture, remote procedure call. Meanwhile, the method can also be provided with various functional modules so as to realize the purpose of autonomously discovering whether the running node is abnormal or not. The method specifically comprises the following steps:
(1) the daemon module is used for automatically restarting the node when the node dies;
(2) the safety module is used for continuously scanning each program module during running, automatically reporting to the remote server when an abnormal event occurs, and actively performing braking operation on the unmanned vehicle when an emergency occurs;
(3) and the external service module is provided with a basic system application program interface and is used for providing a distributed system topological graph service and a simulation time service for a remote user.
Some embodiments of the disclosed data processing apparatus are described below in conjunction with fig. 5.
Fig. 5 shows a schematic structural diagram of a data processing apparatus according to some embodiments of the present disclosure. As shown in fig. 5, the data processing apparatus 50 in the present embodiment includes:
a data sender 501 configured to: broadcasting a first discovery message to a preset port of a local network, wherein the first discovery message comprises an identifier of a data sender, a network address of the data sender, a process identifier of the data sender and a subject identifier of the data sender; a data receiver 502 configured to: broadcasting a second discovery message to a preset port of a local network, wherein the second discovery message comprises an identifier of a data receiver, a network address of the data receiver, a remote procedure call server port address of the data receiver, a process identifier of the data receiver and a theme identifier of the data receiver; the data sender and the data sender are located at the same node or different nodes of the distributed unmanned vehicle communication system; the local network 503 is configured to monitor a predetermined port and store the first discovery message and the second discovery message.
In some embodiments, the data processing apparatus 50 further comprises a data transmitter 504, a data receiver 505, a notification center 506; the data sender 501 is further configured to: acquiring a data transmitter 504, wherein the data transmitter 504 comprises an intra-process data transmission interface, an inter-process data transmission interface and an inter-machine data transmission interface; the data receiver 501 is further configured to: an acquisition data receiver 505; and registering the subject identification of the data receiver and the callback function of the data receiver in the notification center.
In some embodiments, the data sender 501 is further configured to: acquiring a data transmitter 504, and inputting target data and a subject identifier of the data transmitter 501 into the data transmitter 504; the data transmitter 504 is configured to: querying a local network 503 by using a topic identifier of a data sender 501 to obtain a network address and a process identifier of a data receiver 502 subscribed with target data, and obtaining the network address and the process identifier of the data sender 501; according to the network address and the process identification of the data receiver 502 subscribed with the target data and the network address and the process identification of the data sender 501, the target data and the subject identification of the data sender 501 are sent to the data receiver 505; the data receiver 505 is configured to: the subject identifier of the data sender 501 is sent to the notification center 506; the notification center 506 is configured to: the subject identifier of the data sender 501 is used to trigger a callback function of the data receiver 502 subscribed with the target data, so as to process the target data in the data receiver 505.
In some embodiments, the data transmitter 504 is configured to: when the network address of the data receiver 502 subscribed with the target data is the same as the network address of the data sender 501 and the process identifier of the data receiver 502 subscribed with the target data is the same as the process identifier of the data sender 501, the in-process data sending interface of the data sender 504 sends the target data and the subject identifier of the data sender 501 to the data receiver 505 of the current process.
In some embodiments, the data transmitter 504 is configured to: under the condition that the network address of the data receiver 502 subscribed with the target data is the same as the network address of the data sender 501 and the process identifier of the data receiver 502 subscribed with the target data is different from the process identifier of the data sender 501, the inter-process data sending interface of the data sender 504 writes the target data and the subject identifier of the data sender 501 into the dynamically allocated memory block and sends the address of the memory block to the local network 503; the data recipient 502 is further configured to: receiving the address of the memory block, and reading the memory block to obtain the target data and the subject identifier of the data sender 501; the target data and the subject identification of the data sender 501 are sent to the data receiver 505.
In some embodiments, the data recipient 502 is configured to: after verifying that the subject identification of the data receiver 502 includes the subject identification of the data sender 501, the target data and the subject identification of the data sender 501 are sent to the data receiver 505.
In some embodiments, the data transmitter 504 is configured to: when the address of the memory block is sent to the local network 503, the check code of the memory block is also sent; the data receiver 502 is configured to: receiving the check code of the memory block, and verifying the data in the memory block by using the check code of the memory block; after successful verification, the target data and the subject identification of the data sender 501 are sent to the data receiver 505.
In some embodiments, the data processing apparatus 50 further comprises a remote procedure call server; the data transmitter 504 is configured to: under the condition that the network address of the data receiver 502 subscribed with the target data is different from the network address of the data sender 501, the inter-machine data sending interface of the data sender 504 sends the target data and the subject identifier of the data sender 501 to a remote procedure call server through a remote procedure call client; the remote procedure call server sends the target data and the subject identification of the data sender 501 to the data receiver 505.
In some embodiments, the data transmitter 504 is further configured to: querying a local network 503 by using the topic identifier of the data sender 501 to obtain the remote procedure call server port address of the data receiver 502 subscribed with the target data; the address of the remote procedure call server is determined using the port address and network address of the remote procedure call server of the data recipient 502 that subscribes to the target data.
According to the embodiment, the corresponding communication mode can be automatically selected according to the actual situation, so that the stability of the unmanned vehicle communication system is improved, and the resource consumption of the unmanned vehicle communication system is saved.
Further embodiments of the data processing apparatus of the present disclosure are described below in conjunction with fig. 6.
Fig. 6 shows a schematic structural diagram of a data processing apparatus according to further embodiments of the present disclosure. As shown in fig. 6, the data processing apparatus 60 of this embodiment includes: a memory 610 and a processor 620 coupled to the memory 610, the processor 620 being configured to perform the data processing method in any of the foregoing embodiments based on instructions stored in the memory 610.
Memory 610 may include, for example, system memory, fixed non-volatile storage media, and the like. The system memory stores, for example, an operating system, an application program, a Boot Loader (Boot Loader), and other programs.
The data processing device 60 may also include an input-output interface 630, a network interface 640, a storage interface 650, and the like. These interfaces 630, 640, 650 and the connections between the memory 610 and the processor 620 may be through a bus 660, for example. The input/output interface 630 provides a connection interface for input/output devices such as a display, a mouse, a keyboard, and a touch screen. The network interface 640 provides a connection interface for various networking devices. The storage interface 650 provides a connection interface for external storage devices such as an SD card and a usb disk.
The present disclosure also includes a computer readable storage medium having stored thereon computer instructions which, when executed by a processor, implement a data processing method in any of the foregoing embodiments.
The present disclosure is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the disclosure. 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.
The above description is only exemplary of the present disclosure and is not intended to limit the present disclosure, so that any modification, equivalent replacement, or improvement made within the spirit and principle of the present disclosure should be included in the scope of the present disclosure.

Claims (20)

1. A method of data processing, comprising:
the method comprises the steps that a data sending direction broadcasts a first discovery message to a preset port of a local network, wherein the first discovery message comprises an identification of a data sending party, a network address of the data sending party, a process identification of the data sending party and a theme identification of the data sending party;
the data receiving side broadcasts a second discovery message to the preset port of the local network, wherein the second discovery message comprises an identifier of a data receiving side, a network address of the data receiving side, a remote procedure call server port address of the data receiving side, a process identifier of the data receiving side and a theme identifier of the data receiving side; the data sender and the data sender are located at the same node or different nodes of the distributed unmanned vehicle communication system;
and the local network monitors the preset port and stores the first discovery message and the second discovery message.
2. The data processing method of claim 1, further comprising:
a data sender acquires a data sender, wherein the data sender comprises an in-process data sending interface, an inter-process data sending interface and an inter-machine data sending interface;
a data receiver acquires a data receiver;
and the data receiver registers the subject identification of the data receiver and the callback function of the data receiver in the notification center.
3. The data processing method of claim 2, further comprising:
the data sender inputs the target data and the subject identification of the data sender into the data sender;
the data sender queries the local network by using the subject identifier of the data sender to acquire the network address and the process identifier of the data receiver subscribed with the target data and acquire the network address and the process identifier of the data sender;
the data sender sends the target data and the subject identification of the data sender to the data receiver according to the network address and the process identification of the data receiver subscribed with the target data and the network address and the process identification of the data sender;
the data receiver sends the theme identification of the data sender to a notification center;
and the notification center triggers a callback function of a data receiver subscribed with the target data by using the theme identification of the data sender so as to process the target data in the data receiver.
4. The data processing method of claim 3, wherein the data transmitter transmits the target data and the subject identifier of the data sender to the data receiver according to the network address and the process identifier of the data receiver subscribed with the target data and the network address and the process identifier of the data sender comprises:
under the condition that the network address of the data receiver subscribed with the target data is the same as the network address of the data sender, and the process identification of the data receiver subscribed with the target data is the same as the process identification of the data sender, the in-process data sending interface of the data sender sends the target data and the subject identification of the data sender to the data receiver of the current process.
5. The data processing method of claim 3, wherein the data transmitter transmits the target data and the subject identifier of the data sender to the data receiver according to the network address and the process identifier of the data receiver subscribed with the target data and the network address and the process identifier of the data sender comprises:
under the condition that the network address of a data receiver subscribed with target data is the same as the network address of a data sender and the process identification of the data receiver subscribed with the target data is different from the process identification of the data sender, an inter-process data sending interface of a data sender writes the target data and the subject identification of the data sender into a dynamically allocated memory block and sends the address of the memory block to a local network;
the data receiver receives the address of the memory block, and reads the memory block to obtain target data and the theme identification of the data sender;
and the data receiver sends the target data and the subject identification of the data sender to the data receiver.
6. The data processing method of claim 5, wherein the data receiver transmitting the target data and the subject identification of the data sender to the data receiver comprises:
and after the data receiver verifies that the subject identification of the data receiver comprises the subject identification of the data sender, the target data and the subject identification of the data sender are sent to the data receiver.
7. The data processing method according to claim 5, wherein when the data transmitter transmits the address of the memory chunk to the local network, the data transmitter further transmits a check code of the memory chunk;
the data receiver sends the target data and the subject identification of the data sender to the data receiver, and the data receiver comprises:
a data receiving party receives the check code of the memory block and verifies the data in the memory block by using the check code of the memory block;
and after the data receiver successfully verifies, the data receiver sends the target data and the subject identification of the data sender to the data receiver.
8. The data processing method of claim 3, wherein the data transmitter transmits the target data and the subject identifier of the data sender to the data receiver according to the network address and the process identifier of the data receiver subscribed with the target data and the network address and the process identifier of the data sender comprises:
under the condition that the network address of a data receiver subscribing the target data is different from the network address of a data sender, a data sending interface between machines of the data sender sends the target data and the subject identification of the data sender to a remote procedure call server through a remote procedure call client; and the remote procedure call server sends the target data and the subject identification of the data sender to the data receiver.
9. The data processing method of claim 8, wherein the data transmitter transmits the target data and the subject identifier of the data sender to the data receiver according to the network address and the process identifier of the data receiver subscribed to the target data and the network address and the process identifier of the data sender, further comprising:
the data sender queries the local network by using the subject identification of the data sender to acquire the port address of the remote procedure call server of the data receiver subscribed with the target data;
the data transmitter determines an address of a remote procedure call server using a port address and a network address of the remote procedure call server of the data receiver subscribed to the target data.
10. A data processing apparatus comprising:
a data sender configured to: broadcasting a first discovery message to a preset port of a local network, wherein the first discovery message comprises an identifier of a data sender, a network address of the data sender, a process identifier of the data sender and a subject identifier of the data sender;
a data receiver configured to: broadcasting a second discovery message to the preset port of the local network, wherein the second discovery message comprises an identifier of a data receiver, a network address of the data receiver, a remote procedure call server port address of the data receiver, a process identifier of the data receiver and a subject identifier of the data receiver; the data sender and the data sender are located at the same node or different nodes of the distributed unmanned vehicle communication system;
and the local network is configured to monitor the preset port and save the first discovery message and the second discovery message.
11. The data processing apparatus of claim 10, further comprising a data transmitter, a data receiver, a notification center;
the data sender is further configured to: acquiring a data transmitter, wherein the data transmitter comprises an in-process data transmitting interface, an inter-process data transmitting interface and an inter-machine data transmitting interface;
the data receiver is further configured to: acquiring a data receiver; and registering the subject identification of the data receiver and the callback function of the data receiver in the notification center.
12. The data processing apparatus according to claim 11,
the data sender is further configured to: acquiring a data transmitter, and inputting target data and a subject identification of the data transmitter into the data transmitter;
the data transmitter is configured to: inquiring a local network by using the subject identification of the data sender to acquire the network address and the process identification of the data receiver subscribed with the target data and acquire the network address and the process identification of the data sender; according to the network address and the process identification of the data receiver subscribed with the target data and the network address and the process identification of the data sender, sending the target data and the subject identification of the data sender to the data receiver;
the data receiver is configured to: the theme identification of the data sender is sent to a notification center;
the notification center is configured to: and triggering a callback function of a data receiver subscribed with the target data by using the topic identification of the data sender so as to process the target data in the data receiver.
13. The data processing apparatus of claim 12, wherein the data transmitter is configured to:
under the condition that the network address of the data receiver subscribed with the target data is the same as the network address of the data sender, and the process identification of the data receiver subscribed with the target data is the same as the process identification of the data sender, the in-process data sending interface of the data sender sends the target data and the subject identification of the data sender to the data receiver of the current process.
14. The data processing apparatus of claim 12, wherein the data transmitter is configured to: under the condition that the network address of a data receiver subscribed with target data is the same as the network address of a data sender and the process identification of the data receiver subscribed with the target data is different from the process identification of the data sender, an inter-process data sending interface of a data sender writes the target data and the subject identification of the data sender into a dynamically allocated memory block and sends the address of the memory block to a local network;
the data receiver is further configured to: receiving the address of the memory block, and reading the memory block to obtain target data and a theme identifier of a data sender; and sending the target data and the subject identification of the data sender to the data receiver.
15. The data processing apparatus of claim 14, wherein the data receiver is configured to: and after the theme identification of the data receiver is verified to contain the theme identification of the data sender, the target data and the theme identification of the data sender are sent to the data receiver.
16. The data processing apparatus of claim 14, wherein the data transmitter is configured to: when the address of the memory block is sent to the local network, the check code of the memory block is also sent;
the data receiver is configured to: receiving the check code of the memory block, and verifying the data in the memory block by using the check code of the memory block; and after the verification is successful, sending the target data and the subject identification of the data sender to the data receiver.
17. The data processing apparatus of claim 12, further comprising a remote procedure call server;
the data transmitter is configured to: under the condition that the network address of a data receiver subscribing the target data is different from the network address of a data sender, a data sending interface between machines of the data sender sends the target data and the subject identification of the data sender to a remote procedure call server through a remote procedure call client; and the remote procedure call server sends the target data and the subject identification of the data sender to the data receiver.
18. The data processing apparatus of claim 17, wherein the data transmitter is further configured to: inquiring a local network by using the subject identification of the data sender to acquire the remote procedure call server port address of the data receiver subscribed with the target data; and determining the address of the remote procedure call server by utilizing the port address and the network address of the remote procedure call server of the data receiver subscribed with the target data.
19. A data processing apparatus comprising:
a memory; and
a processor coupled to the memory, the processor configured to perform the data processing method of any of claims 1 to 9 based on instructions stored in the memory.
20. A computer-readable storage medium, wherein the computer-readable storage medium stores computer instructions which, when executed by a processor, implement a data processing method as claimed in any one of claims 1 to 9.
CN201911281040.7A 2019-12-13 2019-12-13 Data processing method, device and computer readable storage medium Active CN112995095B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911281040.7A CN112995095B (en) 2019-12-13 2019-12-13 Data processing method, device and computer readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911281040.7A CN112995095B (en) 2019-12-13 2019-12-13 Data processing method, device and computer readable storage medium

Publications (2)

Publication Number Publication Date
CN112995095A true CN112995095A (en) 2021-06-18
CN112995095B CN112995095B (en) 2023-05-30

Family

ID=76332474

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911281040.7A Active CN112995095B (en) 2019-12-13 2019-12-13 Data processing method, device and computer readable storage medium

Country Status (1)

Country Link
CN (1) CN112995095B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US11469890B2 (en) * 2020-02-06 2022-10-11 Google Llc Derived keys for connectionless network protocols

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20110103393A1 (en) * 2009-10-29 2011-05-05 Meier John L System, apparatus, and method for communication in a tactical network
CN103455380A (en) * 2012-06-05 2013-12-18 上海斐讯数据通信技术有限公司 Multi-process communication system and establishment and communication method thereof
CN108847988A (en) * 2018-06-29 2018-11-20 百度在线网络技术(北京)有限公司 dynamic topology maintaining method, device and equipment
CN109151033A (en) * 2018-08-30 2019-01-04 百度在线网络技术(北京)有限公司 Communication means, device, electronic equipment and storage medium based on distributed system
CN109194736A (en) * 2018-08-30 2019-01-11 百度在线网络技术(北京)有限公司 Message De-weight method, device, electronic equipment, medium and unmanned vehicle
CN109743142A (en) * 2018-09-30 2019-05-10 比亚迪股份有限公司 Information communication method and device

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20110103393A1 (en) * 2009-10-29 2011-05-05 Meier John L System, apparatus, and method for communication in a tactical network
CN103455380A (en) * 2012-06-05 2013-12-18 上海斐讯数据通信技术有限公司 Multi-process communication system and establishment and communication method thereof
CN108847988A (en) * 2018-06-29 2018-11-20 百度在线网络技术(北京)有限公司 dynamic topology maintaining method, device and equipment
CN109151033A (en) * 2018-08-30 2019-01-04 百度在线网络技术(北京)有限公司 Communication means, device, electronic equipment and storage medium based on distributed system
CN109194736A (en) * 2018-08-30 2019-01-11 百度在线网络技术(北京)有限公司 Message De-weight method, device, electronic equipment, medium and unmanned vehicle
CN109743142A (en) * 2018-09-30 2019-05-10 比亚迪股份有限公司 Information communication method and device

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US11469890B2 (en) * 2020-02-06 2022-10-11 Google Llc Derived keys for connectionless network protocols

Also Published As

Publication number Publication date
CN112995095B (en) 2023-05-30

Similar Documents

Publication Publication Date Title
CN110740460A (en) device network access method, device, network device and storage medium
WO2021232197A1 (en) Method and apparatus for monitoring device state, device, and storage medium
CN110611691A (en) Message pushing method, system and storage medium
CN108847976B (en) Distribution network control method, mobile terminal, device and computer readable storage medium
US20190334969A1 (en) Media Downlink Transmission Control Method and Related Device
CN105991412A (en) Method and device for pushing message
CN111263338A (en) Network distribution method of Bluetooth Mesh network and related network distribution equipment and system
CN110912805B (en) Message reading state synchronization method, terminal, server and system
CN113196721B (en) Method and device for discovering Internet of things equipment and terminal equipment
CN112995095B (en) Data processing method, device and computer readable storage medium
CN105681162A (en) Method, device and system for synchronizing information
CN103501298B (en) A kind of non-interrupting service escalation process ensures the method and apparatus that link does not stop
CN113259918A (en) Equipment binding method and system
CN110908881B (en) Buried point data transmitting method and device, electronic equipment and computer readable storage medium
CN113660121B (en) Information management method and device based on distributed system and computer storage medium
CN114884805B (en) Data transmission method, device, terminal and storage medium
CN111427710B (en) Communication method, device, equipment and storage medium of components in application program
CN108353071B (en) Cell multicast service processing method and equipment
CN113691520A (en) Method, device, storage medium and electronic device for acquiring streaming media information
CN107548025B (en) Position information sharing method and core network
CN111132311B (en) Base station monitoring method, device, electronic equipment and storage medium
CN109361682B (en) Communication method, device, equipment and storage medium
CN113791804B (en) Method, device, computer equipment and storage medium for parallel upgrading of multipath instruments
CN114189384B (en) Service processing method, device, equipment and storage medium
CN115150031B (en) Distributed system message response method and device based on distributed message

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