CN112532704B - Data transmission method, device, electronic equipment and storage medium - Google Patents
Data transmission method, device, electronic equipment and storage medium Download PDFInfo
- Publication number
- CN112532704B CN112532704B CN202011312624.9A CN202011312624A CN112532704B CN 112532704 B CN112532704 B CN 112532704B CN 202011312624 A CN202011312624 A CN 202011312624A CN 112532704 B CN112532704 B CN 112532704B
- Authority
- CN
- China
- Prior art keywords
- task
- network
- network task
- time
- equipment
- 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
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/14—Session management
- H04L67/143—Termination or inactivation of sessions, e.g. event-controlled end of session
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/14—Session management
- H04L67/143—Termination or inactivation of sessions, e.g. event-controlled end of session
- H04L67/145—Termination or inactivation of sessions, e.g. event-controlled end of session avoiding end of session, e.g. keep-alive, heartbeats, resumption message or wake-up for inactive or interrupted session
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/14—Session management
- H04L67/148—Migration or transfer of sessions
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02D—CLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
- Y02D30/00—Reducing energy consumption in communication networks
- Y02D30/70—Reducing energy consumption in communication networks in wireless communication networks
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Health & Medical Sciences (AREA)
- Cardiology (AREA)
- General Health & Medical Sciences (AREA)
- Data Exchanges In Wide-Area Networks (AREA)
- Computer And Data Communications (AREA)
Abstract
The application discloses a data transmission method, a device, electronic equipment and a storage medium, and provides a control method, a device, electronic equipment and a storage medium of gateway equipment, which are applied to the technical field of computers and applied to gateway equipment in an Internet of things system, wherein the Internet of things system further comprises: a first device, a second device, the method comprising: receiving a network task sent by first equipment; storing the network task and generating management information of the network task; receiving a heartbeat message sent by a second device; and when the heartbeat message is confirmed to be matched with the management information of the network task, the network task is sent to the second equipment. According to the scheme, the storage and management tasks of the network tasks are transferred from the first equipment for generating the tasks to the gateway equipment, so that the network tasks with the management information matched with the heartbeat messages of the second equipment are issued to the second equipment when the heartbeat messages of the second equipment are received, the influence of bandwidth resources between the first equipment and the gateway equipment on network task query is avoided, and the efficiency of the network task query is improved.
Description
Technical Field
The application belongs to the technical field of computers, and particularly relates to a data transmission method, a data transmission device, electronic equipment and a storage medium.
Background
Gateway devices are an essential intermediary device in a network system as an intermediary device for providing network data forwarding between electronic devices.
In the process of network transmission, the network task is stored in the opposite terminal device initiating the network task, the opposite terminal device is connected with the gateway device of the local terminal device to realize the transmission of the network task, and after the gateway device receives the heartbeat message sent by the local terminal device or reaches a specific time point, the network device requests to the opposite terminal device to inquire whether the local terminal device stores the network task in the opposite terminal device or not, so that the opposite terminal device can acquire the network task and send the network task to the local terminal device.
Although the management pressure of the network equipment can be effectively reduced, the data transmission between the gateway equipment and the opposite terminal equipment is limited by the network bandwidth, so that the problem that the network task cannot be issued to the opposite terminal equipment at the time when the network bandwidth resource is insufficient and the query efficiency of the network task is low can be caused.
Disclosure of Invention
In view of this, the embodiments of the present application provide a data transmission method, apparatus, electronic device, and storage medium, which are used to solve the problem in the prior art that the network task cannot be issued to the local device at the time when the network bandwidth resource is insufficient because the data transmission between the gateway device and the opposite terminal device receives the limitation of the network bandwidth as far as possible.
The first aspect of the present application provides a data transmission method, which is applied to a gateway device in an internet of things system, where the internet of things system further includes: a first device, a second device, the method comprising:
receiving a network task sent by first equipment;
storing the network task and generating management information of the network task;
receiving a heartbeat message sent by a second device;
and when the heartbeat message is confirmed to be matched with the management information of the network task, the network task is sent to the second equipment.
Optionally, the management information of the network task includes at least: designating equipment identification, task starting time and task ending time, wherein the heartbeat message at least comprises: a target device identification; the confirming that the heartbeat message is matched with the management information of the network task comprises the following steps:
and when the target equipment identifier is the same as the designated equipment identifier, the current time is later than the task starting time, and the current time is earlier than the task ending time, confirming that the heartbeat message is matched with the management information of the network task.
Optionally, the management information of the network task further includes: task state, after the storing the network task and generating the management information of the network task, the method further includes:
and deleting the network task and the management information when the current time is later than the task ending time, or the time difference between the current time and the latest heartbeat message receiving time is greater than a time length threshold, or the task state is the ending state, wherein the latest heartbeat message receiving time is the last heartbeat message receiving time of the second equipment.
Optionally, after the sending the network task to the second device, the method further includes:
when the sending record corresponding to the network task does not exist, generating a sending record of the sending task corresponding to the network task;
and when the sending record corresponding to the network task exists, updating the sending record according to the current sending task corresponding to the network task.
Optionally, the method further comprises:
and transmitting the transmission record to the first device so that the first device stores the transmission record.
According to a second aspect of the present application, there is provided a data transmission device, applied to a gateway apparatus in an internet of things system, where the internet of things system further includes: a first device, a second device, the apparatus comprising:
the first receiving module is configured to receive a network task sent by the first equipment;
the storage module is configured to store the network task and generate management information of the network task;
the second receiving module is configured to receive a heartbeat message sent by the second equipment;
and the sending module is configured to send the network task to the second device when the heartbeat message is confirmed to be matched with the management information of the network task.
Optionally, the management information of the network task includes at least: designating equipment identification, task starting time and task ending time, wherein the heartbeat message at least comprises: a target device identification; the transmitting module is further configured to:
and when the target equipment identifier is the same as the designated equipment identifier, the current time is later than the task starting time, and the current time is earlier than the task ending time, confirming that the heartbeat message is matched with the management information of the network task.
Optionally, the management information of the network task further includes: task state; the memory module is further configured to:
and deleting the network task and the management information when the current time is later than the task ending time, or the time difference between the current time and the latest heartbeat message receiving time is greater than a time length threshold, or the task state is the ending state, wherein the latest heartbeat message receiving time is the last heartbeat message receiving time of the second equipment.
Optionally, the sending module is further configured to:
when the sending record corresponding to the network task does not exist, generating a sending record of the sending task corresponding to the network task;
and when the sending record corresponding to the network task exists, updating the sending record according to the current sending task corresponding to the network task.
Optionally, the sending module is further configured to:
and transmitting the transmission record to the first device so that the first device stores the transmission record.
According to a third aspect of the present application, there is provided a gateway device comprising a processor, a memory and a program or instruction stored on the memory and executable on the processor, the program or instruction implementing the data transmission method of the first aspect described above when executed by the processor.
According to a fourth aspect of the present application, there is provided a computer readable storage medium having stored thereon a computer program which, when executed by a processor, implements the data transmission method of the first aspect described above.
Aiming at the prior art, the application has the following advantages:
according to the data transmission method, the device, the electronic equipment and the storage medium, the storage and management tasks of the network tasks are transferred from the first equipment for generating the tasks to the gateway equipment, so that when the heartbeat message of the second equipment is received, the network tasks with the management information matched with the heartbeat message are issued to the second equipment, the influence of bandwidth resources between the first equipment and the gateway equipment on network task query is avoided, and the efficiency of the network task query is improved.
The foregoing description is only an overview of the technical solutions of the present application, and may be implemented according to the content of the specification in order to make the technical means of the present application more clearly understood, and in order to make the above-mentioned and other objects, features and advantages of the present application more clearly understood, the following detailed description of the present application will be given.
Drawings
Various other advantages and benefits will become apparent to those of ordinary skill in the art upon reading the following detailed description of the preferred embodiments. The drawings are only for purposes of illustrating the preferred embodiments and are not to be construed as limiting the application. Also, like reference numerals are used to designate like parts throughout the figures. In the drawings:
fig. 1 is a step flowchart of a data transmission method provided in an embodiment of the present application;
fig. 2 is a system schematic diagram of a data transmission method according to an embodiment of the present application;
fig. 3 is a flowchart of steps of another data transmission method according to an embodiment of the present application;
fig. 4 is a block diagram of a data transmission device according to an embodiment of the present application.
Detailed Description
Exemplary embodiments of the present application will be described in more detail below with reference to the accompanying drawings. While exemplary embodiments of the present application are shown in the drawings, it should be understood that the present application may be embodied in various forms and should not be limited to the embodiments set forth herein. Rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the disclosure to those skilled in the art.
Example 1
Fig. 1 is a flowchart of steps of a data transmission method, which is applied to a gateway device in an internet of things system, where the internet of things system further includes: a first device, a second device, the method comprising:
step 101, receiving a network task sent by a first device.
In the embodiment of the application, the internet of things system is a device interaction system established based on the internet of things, and the internet of things is an information carrier based on the internet, a traditional telecommunication network and the like, so that all common physical objects which can be independently addressed form an interconnection network. The gateway device may be a gateway based on wireless or limited communication technology for relaying data uploaded and issued by the devices. The first device is an electronic device for generating and issuing tasks, and may be an electronic device such as a server or a computer, and the second device is an electronic device such as a server or a computer for receiving and executing network tasks. A network task refers to a task that a first device uses to instruct a second device to perform a specific operation.
The gateway device in the embodiment of the present application may implement the steps of the data transmission method provided in the present application by internally setting a functional module that may perform data transmission through HTTP or other data transmission protocols, and certainly, for a relatively huge internet of things system, a cloud server or a server with a certain storage space may also be used to operate the functional module. Typically, the first device will send the network task to the gateway device after generating the network task, and then the gateway device issues the network task to the second device designated by the network task, so that the gateway device may receive the network task sent by the first device.
Step 102, storing the network task and generating management information of the network task.
In this embodiment of the present application, the management information is related parameters used for managing the issuing and storing of the network task, for example, the effective time period, the source address, the target address, and the like of the network task, which may be specifically determined according to actual requirements, and is not limited herein.
When receiving the network task sent by the first device, the gateway device may store the task data in the network task as a binary file, and generate and store management information of the network task in a folder storing the binary file. In this way, even if the gateway device is connected with a plurality of second devices, the network tasks sent by different second devices can be stored and managed in a differentiated manner.
Step 103, receiving a heartbeat message sent by the second device.
In the embodiment of the application, the heartbeat message is used for monitoring the running state of the machine network memory. Typically the second device will send heartbeat messages to the gateway device at specific time periods to inform the gateway device that the second device is running.
And 104, when the heartbeat message is confirmed to be matched with the management information of the network task, the network task is sent to the second device.
In this embodiment of the present application, after receiving a heartbeat packet sent by a second device, a gateway device performs a query in management information of a stored network task, and matches the gateway task corresponding to the heartbeat packet, that is, queries a network task that is sent by a first device to the second device, and if the network task is currently valid, the gateway device will automatically issue the network task to the second device, and does not need to send a request to the first device to query the network task that needs to be issued to the second device.
For example, referring to fig. 2, the embodiment of the present application is applicable to an application scenario in which a wireless terminal device is connected to a server through a gateway device, where the server 3 sends a generated network task to the gateway device 2 for storage, and when the gateway device 2 receives a heartbeat message sent by the wireless terminal device 1, the gateway device sends the network task to the corresponding wireless terminal device 1.
According to the data transmission method, the storage and management tasks of the network tasks are transferred from the first equipment for generating the tasks to the gateway equipment, so that the network tasks with the management information matched with the heartbeat messages are issued to the second equipment when the heartbeat messages of the second equipment are received, the influence of bandwidth resources between the first equipment and the gateway equipment on network task query is avoided, and the efficiency of the network task query is improved.
Example two
Fig. 3 is a flowchart of steps of another data transmission method provided in the embodiment of the present application, which is applied to a gateway device in an internet of things system, where the internet of things system further includes: a first device, a second device, the method comprising:
step 201, receiving a network task sent by a first device.
This step is described in detail with reference to step 101, and will not be described here.
Step 202, storing the network task and generating management information of the network task.
This step may be described in detail with reference to step 102, and will not be described here again.
Optionally, the management information of the network task further includes: task status.
And step 203, deleting the network task and the management information when the current time is later than the task ending time, or the time difference between the current time and the latest heartbeat message receiving time is greater than a time threshold, or the task state is the ending state, wherein the latest heartbeat message receiving time is the last heartbeat message receiving time of the second device.
In this embodiment of the present application, the current time is a time point when the heartbeat packet is received, the task end time is the latest valid time of the network task, and the task start time is the earliest valid time of the network task. The task state is state information reflecting the execution phase of the network task, for example: setup, prepare, execute, end, suspend, etc. The duration threshold is the longest receiving interval between two heartbeat messages allowed by the second device in the process of being normally connected with the gateway device, and exceeding the duration threshold can be regarded as that the second device has disconnected the network connection of the gateway device.
In the process of storing the network task, the gateway equipment can query the stored management information of the network task at regular time, can query whether the current time is compared with the task ending time of the network task at first, if the current time exceeds the task ending time, can determine that the network task has failed, and delete the network task and the management information; if the current time does not exceed the task ending time, the task state of the network task can be further inquired; if the task state is the ending state, determining that the network task has failed, and deleting the network task and the management information; if the task state is not the ending state, inquiring the time difference between the latest heartbeat message receiving time and the current time of the network task; if the time difference is greater than the time length threshold, determining that the second device has disconnected the network connection with the gateway device, and deleting the network task and the management information; if the time difference is smaller than or equal to the time length threshold value, the network task is determined to be effective, and the network task and the management information are kept continuously.
The above-mentioned judgment logic is only illustrative, and the judging sequence of the task ending time, the task state and the latest heartbeat message receiving time can be arbitrarily replaced, so long as whether the network task is effective or not can be judged according to the task ending time, the task state and the latest heartbeat message receiving time, and the judgment logic is not limited herein.
Step 204, receiving a heartbeat message sent by the second device.
This step is described in detail with reference to step 103, and will not be described here.
Optionally, the management information of the network task includes at least: designating equipment identification, task starting time and task ending time, wherein the heartbeat message at least comprises: and (5) identifying the target equipment.
And step 205, when the target device identifier is the same as the designated device identifier, the current time is later than the task start time, and the current time is earlier than the task end time, confirming that the heartbeat message is matched with the management information of the network task, and sending the network task to the second device.
In this embodiment of the present application, the designated device identifier is a unique identification identifier for indicating the second device, which may be a terminal number, a device number, a network number, or the like, and may specifically be determined according to actual requirements, which is not limited herein. The target device identifier is similar to the designated device identifier, except that the target device identifier is carried by a heartbeat message sent by the second device. Thus, based on this embodiment, the packets of the network task may be configured in the manner of table 1 below:
preamble code | Data object ID | Data Source ID | Data | Check bit |
N byte | A byte | A byte | N byte | 2byte |
The preamble is a delimiter for marking the end of timing information, the data target ID is a designated device identifier, the data source ID is a device identifier of the first device, the data is task data, and the check bit is a code for verifying whether a data packet of a network task is legal or not.
Of course, the manner in which the packets of the network task described above are structured indicates an exemplary illustration, so long as the fields in the packets can identify the identity of the second device.
After receiving the heartbeat message sent by the second device, the gateway device may extract the target device identifier of the second device from the heartbeat message, and may determine whether there is a network task that needs to be issued to the second device through the following logic:
comparing the current time with the task ending time; if the current time exceeds the task ending time, confirming that the network task does not exist; if the current time does not exceed the task ending time, comparing the target equipment identifier with the appointed equipment identifier; if the target equipment identifier is different from the designated equipment identifier, confirming that the network task does not exist; if the target equipment identifier is the same as the designated equipment identifier, comparing the current time with the task starting time; if the current time does not exceed the task starting time, confirming that the network task does not exist; and if the current time exceeds the task starting time, confirming that the network task exists, and issuing the network task to the second equipment.
The above-mentioned judgment logic is only illustrative, and the judging sequence of the task ending time, the task starting time and the designated device identifier can be arbitrarily replaced, so long as the judgment of whether the task to be issued to the second device network exists according to the task ending time, the task starting time and the designated device identifier can be performed, and the judgment is not limited herein.
Of course, the management information may also include a task sequence number, a data sequence number, and the like, which may be specifically determined according to actual requirements, and is not limited herein.
And 206, when the sending record corresponding to the network task does not exist, generating the sending record of the sending task corresponding to the network task.
In the embodiment of the application, after each time the network task is sent to the second device, a corresponding sending record may be generated for the second device.
Step 207, when the transmission record corresponding to the network task exists, updating the transmission record according to the current transmission task corresponding to the network task.
In the embodiment of the present application, if there is a transmission record that is transmitting a network task to the second device or a transmission record that last transmits a network task to the second device, the existing transmission record may be overlaid, so as to update the transmission record.
Step 208, transmitting the transmission record to the first device, so that the first device stores the transmission record.
In the embodiment of the application, the sending record can be sent to the first device at fixed time, so that the first device can record the next situation of the network task, and the sending mode of the network task is improved according to the sending record.
According to the data transmission method, the storage and management tasks of the network tasks are transferred from the first equipment for generating the tasks to the gateway equipment, so that the network tasks with the management information matched with the heartbeat messages are issued to the second equipment when the heartbeat messages of the second equipment are received, the influence of bandwidth resources between the first equipment and the gateway equipment on network task query is avoided, and the efficiency of the network task query is improved.
Example III
Fig. 4 is a block diagram of a data transmission device 30, which is applied to a gateway device in an internet of things system, where the internet of things system further includes: a first device, a second device, the apparatus comprising:
a first receiving module 301 configured to receive a network task sent by a first device;
a storage module 302 configured to store the network task and generate management information of the network task;
a second receiving module 303, configured to receive a heartbeat message sent by the second device;
and a sending module 304, configured to send the network task to the second device when the heartbeat message is confirmed to match with the management information of the network task.
Optionally, the management information of the network task includes at least: designating equipment identification, task starting time and task ending time, wherein the heartbeat message at least comprises: a target device identification; the sending module 304 is further configured to:
and when the target equipment identifier is the same as the designated equipment identifier, the current time is later than the task starting time, and the current time is earlier than the task ending time, confirming that the heartbeat message is matched with the management information of the network task.
Optionally, the management information of the network task further includes: task state; the storage module 302 is further configured to:
and deleting the network task and the management information when the current time is later than the task ending time, or the time difference between the current time and the latest heartbeat message receiving time is greater than a time length threshold, or the task state is the ending state, wherein the latest heartbeat message receiving time is the last heartbeat message receiving time of the second equipment.
Optionally, the sending module 304 is further configured to:
when the sending record corresponding to the network task does not exist, generating a sending record of the sending task corresponding to the network task;
and when the sending record corresponding to the network task exists, updating the sending record according to the current sending task corresponding to the network task.
Optionally, the sending module 304 is further configured to:
and transmitting the transmission record to the first device so that the first device stores the transmission record.
According to the data transmission device, the storage and management tasks of the network tasks are transferred from the first equipment for generating the tasks to the gateway equipment, so that the network tasks with the management information matched with the heartbeat messages are issued to the second equipment when the heartbeat messages of the second equipment are received, the influence of bandwidth resources between the first equipment and the gateway equipment on network task inquiry is avoided, and the efficiency of network task inquiry is improved.
Example IV
The embodiment of the application provides gateway equipment, a memory and a program or an instruction stored in the memory and capable of running on the processor, wherein the program or the instruction realizes any one of the data transmission methods when being executed by the processor.
According to the gateway device provided by the embodiment of the application, the storage and management tasks of the network tasks are transferred from the first device for generating the tasks to the gateway device, so that the network tasks with the management information matched with the heartbeat messages of the second device are issued to the second device when the heartbeat messages of the second device are received, the influence of bandwidth resources between the first device and the gateway device on network task query is avoided, and the efficiency of the network task query is improved.
Example five
The embodiment of the application provides a computer storage medium, on which a computer program is stored, which when executed by a processor can implement the data transmission method described above.
The embodiment of the application provides a computer storage medium, which transfers the storage and management tasks of network tasks from first equipment for generating tasks to gateway equipment, so that when a heartbeat message of second equipment is received, the network tasks with management information matched with the heartbeat message are issued to the second equipment, the influence of bandwidth resources between the first equipment and the gateway equipment on network task inquiry is avoided, and the efficiency of network task inquiry is improved.
Those skilled in the art will appreciate that the present application includes reference to apparatus for performing one or more of the operations described herein. These devices may be specially designed and constructed for the required purposes, or may comprise known devices in general purpose computers. These devices have computer programs stored therein that are selectively activated or reconfigured. Such a computer program may be stored in a storage medium of a device (e.g., a computer) or in any type of medium suitable for storing electronic instructions and coupled to a bus, respectively, including, but not limited to, any type of disk (including floppy disks, hard disks, optical disks, CD-ROMs, and magneto-optical disks), ROMs (Read-Only memories), RAMs (Random Access Memory, random access memories), EPROMs (Erasable Programmable Read-Only memories), EEPROMs (Electrically Erasable Programmable Read-Only memories), flash memories, magnetic cards, or optical cards. That is, a storage medium includes any medium that stores or transmits information in a form readable by a device (e.g., a computer).
It will be understood by those within the art that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by computer program instructions. Those skilled in the art will appreciate that these computer program instructions can be implemented in a general purpose computer, special purpose computer, or other programmable data transmission method processor, such that the block diagrams and/or operational illustrations of the blocks or blocks in the block diagrams disclosed herein are implemented by the computer or other programmable data transmission method processor.
The foregoing is merely specific embodiments of the present application, but the scope of the present application is not limited thereto, and any person skilled in the art can easily think about changes or substitutions within the technical scope of the present application, and the changes and substitutions are intended to be covered by the scope of the present application. Therefore, the protection scope of the present application shall be subject to the protection scope of the claims.
Claims (8)
1. The data transmission method is characterized by being applied to gateway equipment in an Internet of things system, and the Internet of things system further comprises: a first device, a second device, the method comprising:
receiving a network task sent by a first device, wherein the network task refers to a task for the first device to instruct a second device to execute a specific operation;
storing the network task and generating management information of the network task, including: the gateway device may store task data in the network task as a binary file, and generate and store management information of the network task in a folder storing the binary file, where the management information of the network task at least includes: designating a device identifier, a task start time and a task end time;
receiving a heartbeat message sent by a second device, wherein the heartbeat message at least comprises: a target device identification;
and when the target equipment identifier is the same as the designated equipment identifier, the current time is later than the task starting time and the current time is earlier than the task ending time, and the heartbeat message is confirmed to be matched with the management information of the network task, the network task is sent to the second equipment.
2. The method of claim 1, wherein the management information of the network task further comprises: task state, after the storing the network task and generating the management information of the network task, the method further includes:
and deleting the network task and the management information when the current time is later than the task ending time, or the time difference between the current time and the latest heartbeat message receiving time is greater than a time length threshold, or the task state is the ending state, wherein the latest heartbeat message receiving time is the last heartbeat message receiving time of the second equipment.
3. The method of claim 1, wherein after the sending the network task to the second device, the method further comprises:
when the sending record corresponding to the network task does not exist, generating a sending record of the sending task corresponding to the network task;
and when the sending record corresponding to the network task exists, updating the sending record according to the current sending task corresponding to the network task.
4. A method according to claim 3, characterized in that the method further comprises:
and transmitting the transmission record to the first device so that the first device stores the transmission record.
5. The data transmission device is characterized in that the device is applied to gateway equipment in an internet of things system, and the internet of things system further comprises: a first device, a second device, the apparatus comprising:
the first receiving module is configured to receive a network task sent by the first equipment;
the storage module is configured to store the network task and generate management information of the network task, wherein the management information of the network task at least comprises: designating a device identifier, a task start time and a task end time;
the second receiving module is configured to receive a heartbeat message sent by the second device, where the heartbeat message at least includes: a target device identification;
and the sending module is configured to send the network task to the second device when the target device identifier is the same as the designated device identifier, the current time is later than the task starting time, the current time is earlier than the task ending time, and the heartbeat message is confirmed to be matched with the management information of the network task.
6. The apparatus of claim 5, wherein the management information of the network task further comprises: task state; the memory module is further configured to:
and deleting the network task and the management information when the current time is later than the task ending time, or the time difference between the current time and the latest heartbeat message receiving time is greater than a time length threshold, or the task state is the ending state, wherein the latest heartbeat message receiving time is the last heartbeat message receiving time of the second equipment.
7. A gateway device comprising a processor, a memory and a program or instruction stored on the memory and executable on the processor, which when executed by the processor implements a data transmission method as claimed in any one of claims 1 to 4.
8. A computer-readable storage medium, on which a computer program is stored, which computer program, when being executed by a processor, implements the data transmission method according to any one of claims 1 to 4.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202011312624.9A CN112532704B (en) | 2020-11-20 | 2020-11-20 | Data transmission method, device, electronic equipment and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202011312624.9A CN112532704B (en) | 2020-11-20 | 2020-11-20 | Data transmission method, device, electronic equipment and storage medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN112532704A CN112532704A (en) | 2021-03-19 |
CN112532704B true CN112532704B (en) | 2023-07-28 |
Family
ID=74982030
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202011312624.9A Active CN112532704B (en) | 2020-11-20 | 2020-11-20 | Data transmission method, device, electronic equipment and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN112532704B (en) |
Families Citing this family (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN115134380B (en) * | 2021-03-24 | 2024-07-12 | 京东方科技集团股份有限公司 | Data transmission method, device, electronic equipment and storage medium |
CN113852474B (en) * | 2021-09-23 | 2024-04-05 | 京东方科技集团股份有限公司 | Task processing method, gateway, computer readable storage medium and electronic device |
CN114666401B (en) * | 2022-04-08 | 2023-11-24 | 深圳市欧瑞博科技股份有限公司 | Device information processing method, device, computer device and storage medium |
CN115514793B (en) * | 2022-11-23 | 2023-03-28 | 北京时代凌宇信息技术有限公司 | Internet of things data aggregation sharing method and device, electronic equipment and storage medium |
Family Cites Families (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20170257226A1 (en) * | 2016-03-04 | 2017-09-07 | Wireless Input Technology, Inc. | Method for Detecting the Status of a Home Automation Device |
CN107483601A (en) * | 2017-08-28 | 2017-12-15 | 郑州云海信息技术有限公司 | A kind of implementation method and execution system of distributed timing task |
CN111130901B (en) * | 2019-12-30 | 2021-12-21 | 京信网络系统股份有限公司 | Device management method, device, communication device and storage medium |
CN111427706B (en) * | 2020-03-20 | 2023-06-20 | 中国联合网络通信集团有限公司 | Data processing method, multi-server system, database, electronic device and storage medium |
CN111885103B (en) * | 2020-06-12 | 2024-05-14 | 视联动力信息技术股份有限公司 | Resource processing method, server, electronic device and storage medium |
-
2020
- 2020-11-20 CN CN202011312624.9A patent/CN112532704B/en active Active
Also Published As
Publication number | Publication date |
---|---|
CN112532704A (en) | 2021-03-19 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN112532704B (en) | Data transmission method, device, electronic equipment and storage medium | |
CN107332876B (en) | Method and device for synchronizing block chain state | |
CN113778463B (en) | Business service deployment method and device | |
CN108494755B (en) | Method and device for transmitting Application Programming Interface (API) request | |
CN110995513A (en) | Data sending and receiving method in Internet of things system, Internet of things equipment and platform | |
CN112584350B (en) | Method, device and equipment for processing information and readable storage medium | |
CN104580085A (en) | Business data updating method, system, client side and server | |
CN111708743A (en) | File storage management method, file management client and file storage management system | |
CN104486125A (en) | Backup method and device of configuration files | |
CN106034113A (en) | Data processing method and data processing device | |
US20170034124A1 (en) | Terminal and multicast address distribution server | |
CN103414641B (en) | Neighbor table item release, device and the network equipment | |
CN111654399A (en) | Networking method, device and equipment based on SD-WAN and storage medium | |
CN109561004B (en) | Message forwarding method and device and switch | |
CN103746768A (en) | Data packet identification method and equipment thereof | |
CN110855627A (en) | Application deployment method, device, equipment and medium | |
CN104009961A (en) | PPPoE session ID distribution method and equipment thereof | |
CN105450513A (en) | Method for filing mail attachments, and cloud storage server | |
CN110888892B (en) | Block synchronization method, device and storage medium | |
CN102656846B (en) | Communication system, communication equipment and communication control method | |
CN116756108A (en) | File synchronization method, system, device and readable storage medium | |
CN113992739B (en) | Local area network OTA firmware upgrading device, method and system | |
CN106559439A (en) | A kind of method for processing business and equipment | |
CN103236901B (en) | A kind of method of transfer instruction and device | |
CN109451047B (en) | Data transmission method, device, equipment and storage medium of monitoring alarm system |
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 |