A method and device for distributing files across the entire network suitable for self-organizing networks

By redetermining the help and lead relationship collection and breakpoint continuous transmission technology in the ad hoc network, network congestion and bandwidth waste caused by file distribution across the network are solved, efficient file distribution and adaptability are achieved, and business execution is improved Experience.

CN115460195BActive Publication Date: 2024-12-13湖南智领通信科技有限公司
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202211152497.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-09-21
Publication Date
2024-12-13
Estimated Expiration
2042-09-21

AI Technical Summary

Technical Problem

In the ad hoc network, due to limited broadband resources when distributing files across the network, it is easy to cause network congestion, affecting service communication and user experience. In addition, traditional methods rely on manual judgment of non-service intensive distribution, which has low accuracy and bandwidth waste.

Method used

By obtaining the network link topology of the ad hoc network node and the node list of successfully distributed files, redetermine the help relationship collection regularly to achieve file breakpoint continuous transmission, avoid unnecessary bandwidth consumption of intermediate nodes, dynamically spread files, and adapt to network structure changes. .

Benefits of technology

It reduces the waste of bandwidth resources of ad hoc networks, avoids network congestion caused by file distribution across the network, improves distribution efficiency and business execution experience, and is suitable for dynamically changing ad hoc network structures.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115460195B_ABST
    Figure CN115460195B_ABST
Patent Text Reader

Abstract

The present application relates to a method and device for distributing files in the whole network suitable for a self-organizing network. The method comprises: obtaining the network link topology of the nodes in the self-organizing network at regular intervals according to the network link topology of the nodes in the self-organizing network, and re-determining a new set of helping relationships using the network link topology of the nodes in the self-organizing network and the list of nodes that have successfully distributed files; judging the new helping set, obtaining files from the self-organizing network nodes in the set that have not been successfully distributed according to the helping relationship, obtaining the file content and feeding back the execution status of the node to the file distribution server; according to the execution status, file identifier and file length, including the nodes that have fed back the successful distribution into the list of nodes that have successfully distributed files, until the current whole network file distribution. The use of this method can reduce the waste of bandwidth resources in the self-organizing network and avoid network congestion caused by the whole network distribution of files.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of wireless communication technology, and in particular to a method, device, computer equipment and storage medium for distributing files across a network suitable for a self-organizing network. Background Art

[0002] A wireless ad hoc network is a distributed network composed of multiple wireless communication devices (referred to as "nodes"), which has the characteristics of being centerless, dynamic topology changes, self-organizing, and multi-hop routing, and its bandwidth resources are limited. In the development and application scenarios of ad hoc networks, it is necessary to distribute files throughout the ad hoc network nodes without affecting the business as much as possible, such as replacing or upgrading the firmware package of the ad hoc network node, sharing offline map packages across the network, and other business file caching scenarios. The size of the files to be distributed is often relatively large. Broadband resources are limited in ad hoc networks. When distributing large files in ad hoc network nodes, it may cause network congestion, which in turn affects the communication of related businesses, causing delays, freezes, communication failures, poor or failed business execution experience, and other effects. The network structure of the ad hoc network is very flexible and has its own unique networking topology. It may be a variety of topologies such as star network, mesh network, chain network, etc., or it may be a mixture of various complex network structures. The number of nodes in the ad hoc network varies. If a large amount of communication data from many nodes passes through the same public communication link at the same time, then this public communication link may become a network communication bottleneck or cause network congestion, which in turn affects the communication of the ad hoc network itself or the execution of related services. In addition, the broadband resources in the ad hoc network are limited. When the service is executed, the limited bandwidth often appears to be relatively tight and there is no reason to waste it. Due to the data transmission function of each node in the file distribution communication routing link, when distributing files in the ad hoc network nodes, a large amount of bandwidth in the link may be wasted within the time period. The larger the file is and the more routing transmission links the node is distributed to, the greater the bandwidth is wasted. At this time, the bandwidth available for the service is affected, which in turn affects the service execution experience. When the location, signal and other conditions of the MANET nodes change, the MANET network link relationship may also be dynamically reorganized, which may further increase the communication load of some public nodes that are already under considerable load.

[0003] However, the traditional way to distribute files in a self-organizing network is to manually determine the time period when the business is not intensive, such as arranging staff to operate in the middle of the night / early morning, and using communication broadcast to notify each node of the self-organizing network to send a file acquisition request to the file server. There are many problems with the traditional approach. For example, if files need to be distributed in a special time period, it is necessary to manually determine the time period when the business is not intensive. The personnel who perform file distribution may not be able to accurately determine whether the business is actually in a non-intensive time period, and the accuracy is low. Even if files are distributed in a special time period, it will still cause bottleneck problems in the shared link segment network, causing network congestion. If related businesses are in progress, they may still be affected. The load on the routing public nodes in the network is large, and the entire self-organizing network wastes a lot of bandwidth resources. This cannot be avoided even if network speed limits are used. When a node needs to obtain a file to be distributed, it needs to pass through all the self-organizing network nodes in the selected routing link between the current node and the file distribution location. Each intermediate self-organizing network node in this link is not a file follower, but only plays a role in communication data transmission. For one data transmission, each intermediate node in the link will consume at least one input and one output and communication control bandwidth, that is, the total bandwidth consumed by each intermediate node is more than twice the size of the distributed file, and the distribution efficiency is low. In order to allow the entire self-organizing network to distribute the file, all self-organizing network nodes that are not directly linked to the file distribution location need these intermediate nodes to go through the above-mentioned communication transmission process, which will cause resource waste on the communication link, and these communications are almost unnecessary. When the file is larger and the number of node routing transmission links to which it is distributed is more, a large amount of bandwidth in the limited bandwidth of the self-organizing network will undoubtedly be wasted. At this time, the bandwidth that can be used by the service is small, and the service execution and user experience will be affected. When the self-organizing network nodes and signals change, resulting in the dynamic reorganization of the self-organizing network structure, it may also further increase the communication load of some public nodes that have already been under considerable load. Summary of the invention

[0004] Based on this, it is necessary to provide a method, device, computer equipment and storage medium for distributing files across the entire network of a self-organizing network, which can reduce the waste of network bandwidth resources in the self-organizing network and avoid network congestion caused by distributing files across the entire network, in order to address the above technical problems.

[0005] A method for distributing files across the entire network applicable to an ad hoc network, the method comprising:

[0006] Obtain information related to file distribution and a list of nodes that have successfully distributed files; information related to file distribution includes a timing interval of the network link topology of the ad hoc network nodes, a file identifier, a file length, and a file checksum;

[0007] Obtain the network link topology of the self-organizing network nodes at regular intervals according to the timed intervals of the network link topology of the self-organizing network nodes, and re-determine a new help relationship set by using the network link topology of the self-organizing network nodes and the list of nodes that have successfully distributed files;

[0008] The new helper set is judged, and the self-organizing network nodes that have not been successfully distributed in the set are retrieved according to the helper relationship, the file content is obtained, and the execution status of the node is fed back to the file distribution server;

[0009] According to the execution status, file identifier and file length, the nodes that have reported successful distribution are included in the list of nodes that have successfully distributed the file until the current full network file distribution; the list of nodes that have reported successful distribution includes all nodes in the self-organizing network link topology.

[0010] In one embodiment, a new set of helping relationships is re-determined using the network link topology of the ad hoc network nodes and the list of nodes that have successfully distributed files, including:

[0011] First, create or empty a new helping relationship set. If there is no node that has successfully distributed files in the list of nodes that have successfully distributed files, form a helping relationship with the self-organizing network node directly connected to the device where the file distribution service is located and put it into the new helping relationship set.

[0012] If there is a node that has successfully distributed the file in the list of nodes that have successfully distributed the file, traverse the successfully distributed self-organizing network nodes according to the network link topology of the self-organizing network nodes to find the helping relationship. If both nodes in the helping relationship found have not appeared in the helping relationship set, they are placed in a new helping relationship set.

[0013] In one embodiment, the self-organizing network nodes in the set that have not been successfully distributed obtain files according to the help relationship, obtain the file content and feedback the execution status of the node to the file distribution server, and further include:

[0014] When a self-organizing network node that has not yet been successfully distributed receives a file distribution notification, it updates the file acquisition time period to the current time to the current time + the available time. If the file request node address, file length, and file verification code corresponding to the file identifier have not changed, the acquisition continues; if any of the file request node address, file length, and file verification code corresponding to the file identifier has changed, the current acquisition action is stopped first, and the file acquisition is executed according to the helping relationship; before executing the file acquisition according to the helping relationship of the notification content, if one of the file length and file verification code corresponding to the file identifier has changed, the downloaded file indicated by the file identifier is deleted first.

[0015] In one of the embodiments, when the acquired file data reaches the file length, the file acquisition is stopped and the file verification code is verified. If the verification code is consistent, it is successful. Regardless of success or failure, feedback is given to the file distribution service. If successful, the feedback is success. If failed, the downloaded file needs to be deleted and failure is fed back. The feedback content also includes the node address, file identifier and the length of the acquired file.

[0016] In one of the embodiments, when executing file acquisition, the file data segment is acquired from the acquired file length position at a specified acquisition speed by breakpoint-resume transmission to the file holder required in the received notification;

[0017] When the communication fails while obtaining the file data, the communication request failure of the file distribution service is fed back, along with the node address, file identifier, and length of the obtained file;

[0018] After the file data segment is successfully obtained, the data segment is appended to a specific location of the ad hoc network node. After the file is successfully distributed, the ad hoc network node passes the file to other nodes.

[0019] If the file acquisition exceeds the file acquisition time period, the acquisition is stopped and the stopped file request, node address, file identifier and acquired file length are fed back.

[0020] A network-wide file distribution device applicable to an ad hoc network, the device comprising:

[0021] The file-related information acquisition module is used to obtain file distribution related information and a list of nodes that have successfully distributed files; the file distribution related information includes the timing interval of the network link topology of the ad hoc network node, the file identifier, the file length, and the file check code;

[0022] A module for determining a helping relationship set is used to obtain the network link topology of the self-organizing network nodes according to the timed interval of the network link topology of the self-organizing network nodes, and to re-determine a new helping relationship set using the network link topology of the self-organizing network nodes and the list of nodes that have successfully distributed files;

[0023] The execution file distribution module is used to judge the new help collection, obtain files from the self-organizing network nodes that have not been successfully distributed in the collection according to the help relationship, obtain the file content and feedback the execution status of the node to the file distribution server;

[0024] The file distribution module is completed and used to include the nodes that have reported successful distribution into the node list that has successfully distributed the file according to the execution status, file identifier and file length, until the current network-wide file distribution is completed; the node list that has reported successful distribution includes all nodes in the self-organizing network link topology.

[0025] A computer device comprises a memory and a processor, wherein the memory stores a computer program, and when the processor executes the computer program, the following steps are implemented:

[0026] Obtain information related to file distribution and a list of nodes that have successfully distributed files; information related to file distribution includes a timing interval of the network link topology of the ad hoc network nodes, a file identifier, a file length, and a file checksum;

[0027] Obtain the network link topology of the self-organizing network nodes at regular intervals according to the timed intervals of the network link topology of the self-organizing network nodes, and re-determine a new help relationship set by using the network link topology of the self-organizing network nodes and the list of nodes that have successfully distributed files;

[0028] The new helper set is judged, and the self-organizing network nodes that have not been successfully distributed in the set are retrieved according to the helper relationship, the file content is obtained, and the execution status of the node is fed back to the file distribution server;

[0029] According to the execution status, file identifier and file length, the nodes that have reported successful distribution are included in the list of nodes that have successfully distributed the file until the current full network file distribution; the list of nodes that have reported successful distribution includes all nodes in the self-organizing network link topology.

[0030] A computer-readable storage medium stores a computer program, which, when executed by a processor, implements the following steps:

[0031] Obtain information related to file distribution and a list of nodes that have successfully distributed files; information related to file distribution includes a timing interval of the network link topology of the ad hoc network nodes, a file identifier, a file length, and a file checksum;

[0032] Obtain the network link topology of the self-organizing network nodes at regular intervals according to the timed intervals of the network link topology of the self-organizing network nodes, and re-determine a new help relationship set by using the network link topology of the self-organizing network nodes and the list of nodes that have successfully distributed files;

[0033] The new helper set is judged, and the self-organizing network nodes that have not been successfully distributed in the set are retrieved according to the helper relationship, the file content is obtained, and the execution status of the node is fed back to the file distribution server;

[0034] According to the execution status, file identifier and file length, the nodes that have reported successful distribution are included in the list of nodes that have successfully distributed the file until the current full network file distribution; the list of nodes that have reported successful distribution includes all nodes in the self-organizing network link topology.

[0035] The above-mentioned method, device, computer equipment and storage medium for distributing files in the entire network of a self-organizing network, the present application obtains the network link topology of the self-organizing network nodes at regular intervals according to the timed intervals of the network link topology of the self-organizing network nodes, and the files can be distributed at any time without relying on manual distribution. After the node is shut down or leaves the network, as long as it re-enters the network, the distribution can be resumed, and the new helping relationship set is re-determined using the network link topology of the self-organizing network nodes and the list of nodes that have successfully distributed the files; the new helping relationship set is judged, and the self-organizing network nodes in the set that have not been successfully distributed are obtained according to the helping relationship and the execution status is fed back to the file distribution server to obtain the file content, and the set is re-determined by constructing a new helping relationship set. The self-organizing network nodes that have not been successfully distributed obtain files according to the helping relationship and feedback the execution status to the file distribution server, avoiding network bottlenecks and avoiding network congestion caused by the distribution of files across the entire network. In the entire self-organizing network file distribution process, the waste of self-organizing network bandwidth resources is reduced, and the distributed files will be transferred from the distributed file nodes to the undistributed file nodes. The distributed files will gradually and dynamically diffuse among the self-organizing network nodes, adapting to various self-organizing network morphological structures and changes in the self-organizing network structure caused by the dynamic increase and decrease of self-organizing network nodes. Regardless of the dynamic change of the self-organizing network structure or the dynamic increase and decrease of nodes, as long as the network topology is reachable, the self-organizing network file distribution can be completed, which is more applicable and more practical. BRIEF DESCRIPTION OF THE DRAWINGS

[0036] Figure 1 A schematic diagram of a flow chart of a method for distributing files across a network applicable to an ad hoc network in an embodiment;

[0037] Figure 2 It is a structural block diagram of a file distribution device for the whole network applicable to an ad hoc network in one embodiment;

[0038] Figure 3 FIG. 4 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION

[0039] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.

[0040] In one embodiment, Figure 1 As shown, a method for distributing files in the whole network applicable to an ad hoc network is provided, comprising the following steps:

[0041] Step 102, obtaining file distribution related information and a list of nodes that have successfully distributed files; the file distribution related information includes the timing interval of the network link topology of the ad hoc network nodes, the file identifier, the file length, and the file check code.

[0042] Set the help relationship set to zero, set the node list that has successfully distributed files to zero, and initialize the timed acquisition of file distribution related information, including the time interval of the network link topology of the ad hoc network node, as well as the file distribution service address, the distributed file identifier, the distributed file length, the distributed file check code, and other optional information such as the distributed file name, etc. The device where the file distribution service is located is regarded as the ad hoc network root node. Files can be transferred between the file distribution service and adjacent ad hoc network nodes, and files can also be transferred between adjacent nodes of the ad hoc network. Ad hoc network nodes will automatically maintain the network link topology, and the file distribution service can directly request the ad hoc network nodes that are currently directly linked to it.

[0043] Step 104, obtaining the network link topology of the self-organizing network nodes at regular intervals according to the timed intervals of the network link topology of the self-organizing network nodes, and re-determining a new help relationship set using the network link topology of the self-organizing network nodes and the list of nodes that have successfully distributed files.

[0044] The network link topology of the self-organizing network nodes is obtained at regular intervals according to the timing of the network link topology of the self-organizing network nodes. After the node is shut down or leaves the network, it can participate in the continued distribution as long as it re-enters the network. The helping relationship is the relationship between the self-organizing network nodes that have distributed files and the adjacent self-organizing network nodes that have not successfully distributed files. The self-organizing network nodes that have files help the nodes that do not have files.

[0045] Step 106, judging the new help set, obtaining files from the self-organizing network nodes in the set that have not been successfully distributed according to the help relationship, obtaining the file content and feeding back the execution status of the node to the file distribution server.

[0046] The self-organizing network nodes in the set that have not been successfully distributed are used to obtain files according to the helping relationship. After the file is successfully obtained, the execution status of the node is fed back to the file distribution server. If the file acquisition fails, the execution status of the node is fed back to the file distribution server. The file distribution server obtains the network link topology of the self-organizing network node at regular intervals according to the timer interval of the network link topology of the self-organizing network node, and uses the network link topology of the self-organizing network node and the list of nodes that have successfully distributed files to redetermine a new helping relationship set, and uses the new helping relationship to re-acquire the file, obtain the file content and feed back the execution status of the node to the file distribution server.

[0047] Step 108, according to the execution status, file identifier and file length, the nodes that have reported successful distribution are included in the list of nodes that have successfully distributed the file until the current network-wide file distribution; the list of nodes that have reported successful distribution includes all nodes in the ad hoc network link topology.

[0048] The list of nodes that have been fed back for successful distribution includes all nodes in the self-organizing network link topology, which means that the current state of full network file distribution is completed. A new helping relationship set is re-determined using the network link topology of the self-organizing network nodes and the list of nodes that have successfully distributed files; the new helping relationship set is judged, and the self-organizing network nodes in the set that have not been successfully distributed are obtained according to the helping relationship and the execution status is fed back to the file distribution server to obtain the file content; after constructing a new helping relationship set, the self-organizing network nodes in the set that have not been successfully distributed are obtained according to the helping relationship and the execution status is fed back to the file distribution server, thereby avoiding network bottlenecks and avoiding network congestion caused by the distribution of files across the entire network. In the entire self-organizing network file distribution process, the waste of self-organizing network bandwidth resources is reduced, and the distributed files will be transferred from the distributed file nodes to the undistributed file nodes. The distributed files are gradually and dynamically diffused among the self-organizing network nodes, adapting to various self-organizing network morphological structures and changes in the self-organizing network structure caused by the dynamic increase and decrease of self-organizing network nodes. Regardless of the dynamic change of the self-organizing network structure or the dynamic increase and decrease of nodes, as long as the network topology is reachable, the self-organizing network file distribution can be completed, and the files can be distributed at any time without relying on manual selection of the distribution time, which is more widely applicable and more practical.

[0049] In the above-mentioned method for distributing files in the entire network applicable to a self-organizing network, the present application obtains the network link topology of the self-organizing network nodes at regular intervals according to the timed intervals of the network link topology of the self-organizing network nodes. Files can be distributed at any time without relying on manual distribution. After the node is shut down or leaves the network, as long as it re-enters the distribution, the self-organizing network node network link topology and the node list that has successfully distributed the file can be resumed. A new helping relationship set is re-determined using the self-organizing network node network link topology and the node list that has successfully distributed the file; the new helping set is judged, and the self-organizing network nodes in the set that have not yet been successfully distributed are obtained according to the helping relationship to obtain the file content, and the execution status is fed back to the file distribution server. After constructing a new helping relationship set, the self-organizing network nodes in the set that have not yet been successfully distributed are determined according to the helping relationship. The method can adapt to the file transmission needs of complex network topology structures, avoid network bottlenecks, and avoid network congestion caused by the distribution of files across the entire network. In the entire self-organizing network file distribution process, the waste of self-organizing network bandwidth resources is reduced, and the distributed files are transferred from the distributed file nodes to the undistributed file nodes. The distributed files are gradually and dynamically diffused among the self-organizing network nodes, adapting to the changes in the self-organizing network structure caused by various self-organizing network morphological structures and the dynamic increase and decrease of self-organizing network nodes. Regardless of the dynamic change of the self-organizing network structure or the dynamic increase and decrease of nodes, as long as the network topology is reachable, the self-organizing network file distribution can be completed, which is more applicable and more practical.

[0050] In one embodiment, the file distribution service at the source of the whole network distribution file involved in the self-organizing network is regarded as the root node of the self-organizing network, the node that has completed the distribution of files in the self-organizing network is regarded as a helping node, and the node that has not completed the file distribution in the self-organizing network and is adjacent to the helping node according to the network link topology is regarded as a leading node. The helping relationship is: the helping node address, the leading node address, and the helping file information, wherein the helping file information includes: file identification, file length, and file verification code.

[0051] Normally, the link topology of the nodes in the ad hoc network is dynamically maintained by the ad hoc network itself and can be directly obtained at any node in the ad hoc network. The file distribution service regularly refreshes the ad hoc network link topology, determines the helping relationship based on the ad hoc network link topology and the nodes to which the files have been distributed in the ad hoc network, places the determined helping relationship in a helping relationship set, and then notifies each node in the helping relationship set to resume the file transfer within a certain period of time from the nodes in the helping relationship according to the agreed file acquisition speed limit, and then gives feedback to the file distribution service. The feedback content includes the current execution status, file identifier, and the length of the currently acquired file. The file distribution service determines the node for successful distribution of the file corresponding to the file identifier based on the feedback content. If the distribution is successful, the node that has been successfully distributed is included in the list of nodes that have successfully distributed the file. Due to the timed drive of the file distribution service, the node that has successfully distributed the file helps the adjacent nodes that have not been successfully distributed to obtain the file based on the network link topology. The number of nodes in the list of nodes that have successfully distributed the file will increase gradually, and until the list of nodes that have been successfully distributed includes all nodes in the ad hoc network link topology, the current network-wide file distribution is completed.

[0052] In one embodiment, a new set of helping relationships is re-determined using the network link topology of the ad hoc network nodes and the list of nodes that have successfully distributed files, including:

[0053] First, create or empty a new helping relationship set. If there is no node that has successfully distributed files in the list of nodes that have successfully distributed files, form a helping relationship with the self-organizing network node directly connected to the device where the file distribution service is located and put it into the new helping relationship set.

[0054] If there is a node that has successfully distributed the file in the list of nodes that have successfully distributed the file, traverse the successfully distributed self-organizing network nodes according to the network link topology of the self-organizing network nodes to find the helping relationship. If both nodes in the helping relationship found have not appeared in the helping relationship set, they are placed in a new helping relationship set.

[0055] In a specific embodiment, the priority level can also be judged based on data such as node topology depth, number of adjacent connections, geographic location, signal strength, power, length of node-obtained files recorded by the file distribution service, number of communication failures, etc., in order to select a more appropriate helping relationship from multiple helping relationships.

[0056] In one embodiment, the self-organizing network nodes in the set that have not been successfully distributed are used to obtain files according to the help relationship, obtain the file content and feedback the execution status of the node to the file distribution server, including:

[0057] When a self-organizing network node that has not yet been successfully distributed receives a file distribution notification, it updates the file acquisition time period to the current time to the current time + the available time. If the file request node address, file length, and file verification code corresponding to the file identifier have not changed, the acquisition continues; if any of the file request node address, file length, and file verification code corresponding to the file identifier has changed, the current acquisition action is stopped first, and the file acquisition is executed according to the helping relationship; before executing the file acquisition according to the helping relationship of the notification content, if one of the file length and file verification code corresponding to the file identifier has changed, the downloaded file indicated by the file identifier is deleted first.

[0058] In a specific embodiment, the content of the file distribution notification includes the address of the node holding the file, the limited acquisition speed, the duration of the file acquisition, the file identifier, the file length, and the file check code. The node receiving the above notification executes the file acquisition according to the notification requirements of the file distribution service, and feeds back the execution status, file identifier, and the length of the acquired file to the file distribution service under specified circumstances.

[0059] In one of the embodiments, when the acquired file data reaches the file length, the file acquisition is stopped and the file verification code is verified. If the verification code is consistent, it is successful. Regardless of success or failure, feedback is given to the file distribution service. If successful, the feedback is success. If failed, the downloaded file needs to be deleted and failure is fed back. The feedback content also includes the node address, file identifier and the length of the acquired file.

[0060] In one of the embodiments, when executing file acquisition, the file data segment is acquired from the acquired file length position at a specified acquisition speed by breakpoint-resume transmission to the file holder required in the received notification;

[0061] When the communication fails while obtaining the file data, the communication request failure of the file distribution service is fed back, along with the node address, file identifier, and length of the obtained file;

[0062] After the file data segment is successfully obtained, the data segment is appended to a specific location of the ad hoc network node. After the file is successfully distributed, the ad hoc network node passes the file to other nodes.

[0063] If the file acquisition exceeds the file acquisition time period, the acquisition is stopped and the stopped file request, node address, file identifier and acquired file length are fed back.

[0064] It should be understood that although Figure 1 The steps in the flowchart are shown in sequence as indicated by the arrows, but these steps are not necessarily executed in the order indicated by the arrows. Unless otherwise specified in this document, there is no strict order restriction for the execution of these steps, and these steps can be executed in other orders. Moreover, Figure 1 At least part of the steps may include multiple sub-steps or multiple stages. These sub-steps or stages are not necessarily executed at the same time, but can be executed at different times. The execution order of these sub-steps or stages is not necessarily sequential, but can be executed in turn or alternately with other steps or at least part of the sub-steps or stages of other steps.

[0065] In one embodiment, Figure 2 As shown, a file distribution device for the whole network applicable to an ad hoc network is provided, comprising: a file related information acquisition module 202, a help relationship set determination module 204, a file distribution execution module 206 and a file distribution completion module 208, wherein:

[0066] The file related information acquisition module 202 is used to acquire file distribution related information and a list of nodes that have successfully distributed files; the file distribution related information includes a timing interval of the network link topology of the ad hoc network node, a file identifier, a file length, and a file check code;

[0067] The module 204 for determining a helping relationship set is used to obtain the network link topology of the self-organizing network nodes according to the time interval of the network link topology of the self-organizing network nodes, and to re-determine a new helping relationship set by using the network link topology of the self-organizing network nodes and the list of nodes that have successfully distributed files;

[0068] The execution file distribution module 206 is used to judge the new help collection, obtain files from the self-organizing network nodes that have not been successfully distributed in the collection according to the help relationship, obtain the file content and feedback the execution status of the node to the file distribution server;

[0069] The file distribution completion module 208 is used to add the nodes that have reported successful distribution into the node list that has successfully distributed the file according to the execution status, file identifier and file length, until the current network-wide file distribution is completed; the node list that has reported successful distribution includes all nodes in the self-organizing network link topology.

[0070] In one embodiment, the module 204 for determining the set of helping relationships is further used to redetermine a new set of helping relationships by using the network link topology of the nodes in the ad hoc network and the list of nodes that have successfully distributed files, including:

[0071] First, create or empty a new helping relationship set. If there is no node that has successfully distributed files in the list of nodes that have successfully distributed files, form a helping relationship with the self-organizing network node directly connected to the device where the file distribution service is located and put it into the new helping relationship set.

[0072] If there is a node that has successfully distributed the file in the list of nodes that have successfully distributed the file, traverse the successfully distributed self-organizing network nodes according to the network link topology of the self-organizing network nodes to find the helping relationship. If both nodes in the helping relationship found have not appeared in the helping relationship set, they are placed in a new helping relationship set.

[0073] In one embodiment, the execution file distribution module 206 is further used to obtain files from the self-organizing network nodes in the set that have not been successfully distributed according to the help relationship, obtain the file content and feedback the execution status of the node to the file distribution server, and also includes:

[0074] When a self-organizing network node that has not yet been successfully distributed receives a file distribution notification, it updates the file acquisition time period to the current time to the current time + the available time. If the file request node address, file length, and file verification code corresponding to the file identifier have not changed, the acquisition continues; if any of the file request node address, file length, and file verification code corresponding to the file identifier has changed, the current acquisition action is stopped first, and the file acquisition is executed according to the helping relationship; before executing the file acquisition according to the helping relationship of the notification content, if one of the file length and file verification code corresponding to the file identifier has changed, the downloaded file indicated by the file identifier is deleted first.

[0075] In one of the embodiments, when the acquired file data reaches the file length, the file acquisition is stopped and the file verification code is verified. If the verification code is consistent, it is successful. Regardless of success or failure, feedback is given to the file distribution service. If successful, the feedback is success. If failed, the downloaded file needs to be deleted and failure is fed back. The feedback content also includes the node address, file identifier and the length of the acquired file.

[0076] In one of the embodiments, when executing file acquisition, the file data segment is acquired from the acquired file length position at a specified acquisition speed by breakpoint-resume transmission to the file holder required in the received notification;

[0077] When the communication fails while obtaining the file data, the communication request failure of the file distribution service is fed back, along with the node address, file identifier, and length of the obtained file;

[0078] After the file data segment is successfully obtained, the data segment is appended to a specific location of the ad hoc network node. After the file is successfully distributed, the ad hoc network node passes the file to other nodes.

[0079] If the file acquisition exceeds the file acquisition time period, the acquisition is stopped and the stopped file request, node address, file identifier and acquired file length are fed back.

[0080] For the specific definition of a whole-network file distribution device applicable to a self-organizing network, please refer to the definition of a whole-network file distribution method applicable to a self-organizing network in the above text, which will not be repeated here. Each module in the above-mentioned whole-network file distribution device applicable to a self-organizing network can be implemented in whole or in part by software, hardware and a combination thereof. The above-mentioned modules can be embedded in or independent of the processor in the computer device in the form of hardware, or can be stored in the memory of the computer device in the form of software, so that the processor can call and execute the operations corresponding to the above modules.

[0081] In one embodiment, a computer device is provided. The computer device may be a terminal, and its internal structure diagram may be as follows: Figure 3 As shown. The computer device includes a processor, a memory, a network interface, a display screen and an input device connected through a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The network interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, a method for distributing files in the entire network suitable for a self-organizing network is implemented. The display screen of the computer device can be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer device can be a touch layer covered on the display screen, or a key, trackball or touchpad set on the computer device housing, or an external keyboard, touchpad or mouse, etc.

[0082] Those skilled in the art will understand that Figure 3 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.

[0083] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application can include non-volatile and / or volatile memory. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory can include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).

[0084] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0085] The above-mentioned embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the invention patent. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the patent of the present application shall be subject to the attached claims.

Claims

1. A method for distributing files across the entire network applicable to an ad hoc network, characterized in that: The method comprises: Obtaining file distribution related information and a list of nodes that have successfully distributed files; the file distribution related information includes a timing interval of the network link topology of the ad hoc network nodes, a file identifier, a file length, and a file check code; Obtaining the network link topology of the self-organizing network nodes at regular intervals according to the timed intervals of the network link topology of the self-organizing network nodes, and re-determining a new set of helping relationships by using the network link topology of the self-organizing network nodes and a list of nodes that have successfully distributed files; wherein re-determining a new set of helping relationships by using the network link topology of the self-organizing network nodes and a list of nodes that have successfully distributed files comprises: First, create or empty a new helping relationship set. If there is no node that has successfully distributed files in the list of nodes that have successfully distributed files, form a helping relationship with the self-organizing network node directly connected to the device where the file distribution service is located and put it into the new helping relationship set. If there is a node that has successfully distributed the file in the list of nodes that have successfully distributed the file, traverse the successfully distributed self-organizing network nodes according to the network link topology of the self-organizing network nodes to find the helping relationship, and if both nodes on the found helping relationship have not appeared in the helping relationship set, then put them into a new helping relationship set; The new helper set is judged, and the self-organizing network nodes that have not been successfully distributed in the set are retrieved according to the helper relationship, the file content is obtained, and the execution status of the node is fed back to the file distribution server; According to the execution status, file identifier and file length, the nodes that have reported successful distribution are included in the node list that has successfully distributed the file until the current network-wide file distribution is completed; the node list that has reported successful distribution includes all nodes in the self-organizing network link topology.

2. The method according to claim 1, characterized in that Obtain files from the self-organizing network nodes that have not been successfully distributed in the set according to the help relationship, obtain the file content and feedback the execution status of the node to the file distribution server, and also include: When a self-organizing network node that has not yet been successfully distributed receives a file distribution notification, it updates the file acquisition time period to the current time to the current time + the available time. If the file request node address, file length, and file verification code corresponding to the file identifier have not changed, the acquisition continues; if any of the file request node address, file length, and file verification code corresponding to the file identifier has changed, the current acquisition action is stopped first, and the file acquisition is executed according to the helping relationship; before executing the file acquisition according to the helping relationship of the notification content, if one of the file length and file verification code corresponding to the file identifier has changed, the downloaded file indicated by the file identifier is deleted first.

3. The method according to claim 2, characterized in that The method further comprises: When the acquired file data reaches the file length, stop acquiring the file and verify the file checksum. If the checksums are consistent, it means success. Regardless of success or failure, feedback will be given to the file distribution service. If successful, feedback is success. If failed, the downloaded file must be deleted and feedback will be given as failure. The feedback content also includes the node address, file identifier and the length of the acquired file.

4. The method according to claim 3, characterized in that The method further comprises: When executing file acquisition, the file data segment is acquired from the file length position obtained and transmitted to the file holder required in the received notification at a specified acquisition speed by breakpoint continuation; When the communication fails while obtaining the file data, the communication request failure of the file distribution service is fed back, along with the node address, file identifier, and length of the obtained file; After the file data segment is successfully obtained, the data segment is appended to a specific location of the ad hoc network node. After the file is successfully distributed, the ad hoc network node passes the file to other nodes. If the file acquisition exceeds the file acquisition time period, the acquisition is stopped and the stopped file request, node address, file identifier and acquired file length are fed back.

5. A file distribution device for the whole network suitable for an ad hoc network, characterized in that: The device comprises: A file related information acquisition module, used to acquire file distribution related information and a list of nodes that have successfully distributed files; the file distribution related information includes a timing interval of a network link topology of a self-organizing network node, a file identifier, a file length, and a file check code; A module for determining a helping relationship set is used to obtain the network link topology of the self-organizing network node at a fixed interval according to the timed interval of the network link topology of the self-organizing network node, and redetermine a new helping relationship set by using the network link topology of the self-organizing network node and the list of nodes that have successfully distributed files; wherein, redetermining a new helping relationship set by using the network link topology of the self-organizing network node and the list of nodes that have successfully distributed files includes: First, create or empty a new helping relationship set. If there is no node that has successfully distributed files in the list of nodes that have successfully distributed files, form a helping relationship with the self-organizing network node directly connected to the device where the file distribution service is located and put it into the new helping relationship set. If there is a node that has successfully distributed the file in the list of nodes that have successfully distributed the file, traverse the successfully distributed self-organizing network nodes according to the network link topology of the self-organizing network nodes to find the helping relationship, and if both nodes on the found helping relationship have not appeared in the helping relationship set, then put them into a new helping relationship set; The execution file distribution module is used to judge the new help collection, obtain files from the self-organizing network nodes that have not been successfully distributed in the collection according to the help relationship, obtain the file content and feedback the execution status of the node to the file distribution server; The file distribution module is used to add the nodes that have reported successful distribution into the node list that has successfully distributed the file according to the execution status and the file identifier and file length, until the current network-wide file distribution is completed; the node list that has reported successful distribution includes all nodes in the self-organizing network link topology.

6. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 4 are implemented.

7. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 4 are implemented.