CN111770188A - BT (bit BT) download node management method and device - Google Patents

BT (bit BT) download node management method and device Download PDF

Info

Publication number
CN111770188A
CN111770188A CN202010632353.9A CN202010632353A CN111770188A CN 111770188 A CN111770188 A CN 111770188A CN 202010632353 A CN202010632353 A CN 202010632353A CN 111770188 A CN111770188 A CN 111770188A
Authority
CN
China
Prior art keywords
download
nodes
node
downloading
standby
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.)
Pending
Application number
CN202010632353.9A
Other languages
Chinese (zh)
Inventor
陈天宇
梁波
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhuhai Seasun Mobile Game Technology Co ltd
Original Assignee
Zhuhai Seasun Mobile Game Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Zhuhai Seasun Mobile Game Technology Co ltd filed Critical Zhuhai Seasun Mobile Game Technology Co ltd
Priority to CN202010632353.9A priority Critical patent/CN111770188A/en
Publication of CN111770188A publication Critical patent/CN111770188A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/06Protocols specially adapted for file transfer, e.g. file transfer protocol [FTP]

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The application provides a BT download node management method and device. The BT download node management method comprises the following steps: acquiring at least one downloading node for BT downloading; determining the storage space of each downloading node as a preset main set or a standby set, and storing the downloading nodes in the corresponding storage space, wherein the main set is used for storing the downloading nodes used for downloading the current BT, and the standby set is used for storing the standby downloading nodes; and performing BT download through the download nodes in the main set. According to the BT download node management method and device, the used download nodes are high-quality nodes with high priority and high activity when a user carries out a BT download task, so that the BT download speed is greatly increased, the BT download efficiency is improved, and network congestion is effectively avoided.

Description

BT (bit BT) download node management method and device
Technical Field
The present application relates to the field of internet technologies, and in particular, to a BT download node management method and apparatus.
Background
With the popularization of the internet, the demand of people for network resources is increasing, and downloading resources from the internet becomes the most common way. Bittorrent (BT) is currently the most popular downloading technology for the Internet.
Bit stream (BT), a network file transfer protocol, is a technology capable of realizing peer-to-peer file sharing. The BT Protocol is a Peer-to-Peer file transfer Protocol (P2P, Peer) on the architecture and Transmission Control Protocol/internet Protocol (TCP/IP), and is an application layer in the structure of the Transmission Control Protocol/internet Protocol (TCP/IP). The BT protocol virtually partitions the file providing the download into equal-sized blocks, the block size must be an integer power of 2k (since it is virtually partitioned, no individual block file is generated on the hard disk), and writes the index information and Hash verification code for each block into the torent file (i.e., the seed file, also referred to simply as the "seed"), as the "index" of the downloaded file. When downloading the file content, the downloader needs to obtain the corresponding tornt file first, and then downloads the file by using the BT client software.
In the existing BT downloading technology, one downloading terminal acquires a plurality of nodes in a network to perform downloading tasks, but the downloading speeds provided by the nodes are greatly different, and some nodes may become bad nodes with a low downloading speed after being acquired, but each downloading request of a user needs to use all the nodes including the bad nodes acquired by the downloading terminal by default, which causes the problems of slow downloading, network resource waste and network congestion.
Disclosure of Invention
In view of the above, embodiments of the present application provide a BT download node management method and apparatus, a computing device, and a computer-readable storage medium, so as to solve technical defects in the prior art.
The embodiment discloses a BT download node management method, which comprises the following steps:
acquiring at least one downloading node for BT downloading;
determining the storage space of each downloading node as a preset main set or a standby set, and storing the downloading nodes in the corresponding storage space, wherein the main set is used for storing the downloading nodes used for downloading the current BT, and the standby set is used for storing the standby downloading nodes;
and performing BT download through the download nodes in the main set.
Further, after determining that the storage space of each download node is a preset active set or a preset standby set, the method further includes:
and determining the storage space of each download node as a preset primary set or a preset standby set according to the number of each download node, the priority of each download node, the node capacity of the primary set and the node capacity of the standby set.
Further, after determining that the storage space of each download node is a preset active set or a preset standby set, the method further includes:
the priority of the downloading node is determined by the following method: and determining the priority of the download node according to the position acquired by the download node, wherein the download node acquired inside the local area network is high priority, and the download node acquired outside the local area network is low priority.
Further, after determining that the storage space of each download node is a preset active set or a preset standby set according to the number of each download node, the priority of each download node, the node capacity of the active set, and the node capacity of the standby set, the method further includes:
if the number of the downloading nodes is smaller than the node capacity of the main set, determining that the storage space of the downloading nodes is a preset main set;
if the number of the download nodes is larger than the download node capacity of the main set and smaller than the sum of the node capacities of the download nodes of the main set and the standby set, storing the download nodes with high priority into the main set according to the priority of the download nodes, and storing the rest download nodes into the standby set after the main set is full of storage;
if the number of the download nodes is larger than the sum of the node capacities of the download nodes in the main set and the spare set, the download nodes with high priority are stored in the main set according to the priority of the download nodes, and after the main set is fully stored, the rest download nodes are stored in the spare set until the spare set is fully stored, and the rest download nodes which are not stored are discarded.
Further, after storing the download node in the corresponding storage space, the method further includes:
after all the downloading nodes are stored in the storage space, heartbeat information is respectively sent to the stored downloading nodes in the main set and the stored downloading nodes in the standby set;
if the reply information of any download node of the main set is not received within the range of the set time threshold, deleting the download node, and selecting the download node from the standby set to store in the main set;
and if the reply information of any download node of the standby set is not received within the range of the set time threshold, deleting the download node.
Further, storing the download node in the corresponding storage space further includes:
the storage structures of the main set and the standby set are heap structures;
for the main set, acquiring the activity of the stored downloading nodes in the main set and the activity of the downloading nodes to be stored, and sequencing the stored downloading nodes in the main set from the top of the heap to the bottom of the heap in sequence from high to low according to the activity;
and for the standby set, acquiring the activity of the stored downloading nodes in the standby set and the activity of the downloading nodes to be stored, and sequencing the stored downloading nodes in the standby set from the top of the heap to the bottom of the heap in sequence from high to low according to the activity.
Further, storing the download node in the corresponding storage space further includes:
the main set is provided with a corresponding first timer;
the method further comprises the following steps: updating and scanning a main set based on a preset first time interval, and sending heartbeat information to download nodes in the main set;
if the reply information of a certain download node is not received within the range of the set time threshold, the download node is deleted, and the download node is selected from the standby set and stored in the main set.
Further, selecting a download node from the standby set to store in the primary set, further comprising:
determining a downloading node with high priority in the standby set;
and taking the download node with the highest activity in the download nodes with high priority as an update node to be stored in the main set, and sequencing the stored download nodes and the update node in the main set from the top of the heap to the bottom of the heap in sequence from high to low according to the activity.
Further, storing the download node in the corresponding storage space further includes:
the standby set is provided with a corresponding second timer;
the method further comprises the following steps: updating and scanning a standby set based on a preset second time interval, and sending heartbeat information to download nodes in the standby set;
and if the reply message of any download node is not received within the range of the set time threshold, deleting the download node.
The present application further provides a management apparatus for a BT download node, including:
an acquisition module configured to acquire at least one download node;
the storage module is configured to determine that a storage space of each download node is a preset primary set or a preset backup set, and store the download nodes in corresponding storage spaces, wherein the primary set is used for storing the download nodes used for downloading the current BT, and the backup set is used for storing the backup download nodes;
and the downloading module is configured to perform BT downloading through the downloading nodes in the main set.
The present application also provides a computing device comprising a memory, a processor, and computer instructions stored on the memory and executable on the processor, wherein the processor executes the instructions to implement the steps of the BT download node management method described above.
The present application also provides a computer readable storage medium storing computer instructions which, when executed by a processor, implement the steps of a BT download node management method described above.
According to the BT download node management method and device, the at least one download node used for BT download is acquired, the acquired download nodes are stored according to the priority, the acquired download nodes are divided into the main set and the standby set, and the download nodes in the main set are used for BT download tasks, so that the BT download tasks are performed by the download nodes in the main set without using all the download nodes when a user performs the BT download tasks, the BT download tasks are performed by the download nodes in the main set, and the use of the download nodes are available, so that the download speed of the user is increased, network resources are saved, the BT download efficiency is increased, and the problem of network congestion is avoided.
Drawings
FIG. 1 is a schematic diagram of a computing device according to an example of the present application;
fig. 2 is a flowchart illustrating steps of a BT download node management method according to an embodiment of the present application;
fig. 3 is a flowchart illustrating steps of a BT download node management method according to an embodiment of the present application;
fig. 4 is a schematic structural diagram of a BT download node management apparatus according to an embodiment of the present application.
Detailed Description
In the following description, numerous specific details are set forth in order to provide a thorough understanding of the present application. This application is capable of implementation in many different ways than those herein set forth and of similar import by those skilled in the art without departing from the spirit of this application and is therefore not limited to the specific implementations disclosed below.
The terminology used in the description of the one or more embodiments is for the purpose of describing the particular embodiments only and is not intended to be limiting of the description of the one or more embodiments. As used in one or more embodiments of the present specification and the appended claims, the singular forms "a," "an," and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It should also be understood that the term "and/or" as used in one or more embodiments of the present specification refers to and encompasses any and all possible combinations of one or more of the associated listed items.
It will be understood that, although the terms first, second, etc. may be used herein in one or more embodiments to describe various information, these information should not be limited by these terms. These terms are only used to distinguish one type of information from another. For example, a first can also be referred to as a second and, similarly, a second can also be referred to as a first without departing from the scope of one or more embodiments of the present description. The word "if" as used herein may be interpreted as "at … …" or "when … …" or "in response to a determination", depending on the context.
First, the noun terms to which one or more embodiments of the present invention relate are explained.
LSD: local Service Discovery algorithm (LSD).
DHT: a Distributed Hash Table (DHT).
LRU: least recently used algorithm (LRU).
In the present application, a BT download node management method and apparatus, a computing device and a computer readable storage medium are provided, which are described in detail in the following embodiments one by one.
Fig. 1 is a block diagram illustrating a configuration of a computing device 100 according to an embodiment of the present specification. The components of the computing device 100 include, but are not limited to, memory 110 and processor 120. The processor 120 is coupled to the memory 110 via a bus 130 and a database 150 is used to store data.
Computing device 100 also includes access device 140, access device 140 enabling computing device 100 to communicate via one or more networks 160. Examples of such networks include the Public Switched Telephone Network (PSTN), a Local Area Network (LAN), a Wide Area Network (WAN), a Personal Area Network (PAN), or a combination of communication networks such as the internet. Access device 140 may include one or more of any type of network interface (e.g., a Network Interface Card (NIC)) whether wired or wireless, such as an IEEE802.11 Wireless Local Area Network (WLAN) wireless interface, a worldwide interoperability for microwave access (Wi-MAX) interface, an ethernet interface, a Universal Serial Bus (USB) interface, a cellular network interface, a bluetooth interface, a Near Field Communication (NFC) interface, and so forth.
In one embodiment of the present description, the above-described components of computing device 100 and other components not shown in FIG. 1 may also be connected to each other, such as by a bus. It should be understood that the block diagram of the computing device architecture shown in FIG. 1 is for purposes of example only and is not limiting as to the scope of the description. Those skilled in the art may add or replace other components as desired.
Computing device 100 may be any type of stationary or mobile computing device, including a mobile computer or mobile computing device (e.g., tablet, personal digital assistant, laptop, notebook, netbook, etc.), a mobile phone (e.g., smartphone), a wearable computing device (e.g., smartwatch, smartglasses, etc.), or other type of mobile device, or a stationary computing device such as a desktop computer or PC. Computing device 100 may also be a mobile or stationary server.
Wherein the processor 120 may perform the steps of the method shown in fig. 2. Fig. 2 is a schematic flowchart illustrating a BT download node management method according to an embodiment of the present application, including steps S201 to S203.
Step S201: at least one download node for BT download is obtained.
Specifically, the download node described in this application is defined as: a download node refers to a computer or other device connected to a network having a separate address and having the capability to transmit or receive data. The specific acquisition range is a full network range, including a local area network interior and a local area network exterior.
Specifically, after the step of acquiring the download node for BT download is completed, no new download node is acquired in step S202 to step S203.
Step S202: and determining the storage space of each download node as a preset primary set or a preset standby set, and storing the download nodes in the corresponding storage spaces.
Further, the storage space is divided into two sets for storing the acquired download nodes, where one set is a primary set and the other set is a backup set.
Further, the data structures of the active set and the standby set in the storage space are heap structures.
Further, the heap structure in this embodiment is a complete binary tree structure.
Specifically, the obtained download nodes are firstly divided into a high priority and a low priority, wherein the download nodes inside the local area network are obtained by using an LSD algorithm, the download nodes inside the local area network are high priority nodes, the download nodes outside the local area network are obtained by using a DHT algorithm, and the download nodes outside the local area network are low priority nodes.
And then, sequentially storing the high-priority nodes into the primary set, starting to store the high-priority nodes into the standby set after the primary set is full, and starting to store the low-priority nodes after all the high-priority nodes are stored into the set until all the nodes are stored into the set.
After all the downloading nodes are stored in the storage space, sequencing the stored downloading nodes in the main set from the top of the heap to the bottom of the heap in sequence according to the activity by using an LRU algorithm, wherein after the sequencing is finished, the arrangement sequence of the downloading nodes in the main set is as follows: the download node with the highest activity is at the top of the heap, and the download node with the lowest activity is at the bottom of the heap.
Further, the LRU algorithm is used to sequence the stored download nodes in the backup set from the top of the heap to the bottom of the heap in sequence according to the activity, and after the sequencing is completed, the arrangement sequence of the download nodes in the backup set should be: the download node with the highest activity is at the top of the heap, and the download node with the lowest activity is at the bottom of the heap.
Further, if the backup set is empty, the step of ordering the download nodes in the backup set is not performed.
After all the downloading nodes are sequenced, a first timer preset in the main set sends heartbeat information to the downloading nodes in the main set respectively, if reply information of a certain downloading node in the main set is not received within a set time threshold range, the downloading node is judged to be unavailable, the downloading node is deleted from the main set, and the downloading node is selected from the standby set and stored in the main set.
Further, after all the downloading nodes are sequenced, a second timer in the standby set sends heartbeat information to the downloading nodes in the standby set respectively, if the reply information of a certain downloading node in the standby set is not received within a set time threshold range, the node is judged to be unavailable, and the downloading node is deleted from the standby set.
Step S203: and carrying out BT download through the download nodes in the main set.
In the BT download node management method provided by this embodiment, at least one download node for BT download is acquired, the acquired download nodes are stored according to priority, and the acquired download nodes are divided into the primary set and the backup set, and the download nodes in the primary set are used for performing a BT download task, so that when a user performs the BT download task, the user does not need to use all the download nodes, but selects the download nodes in the primary set for performing the BT download task, and then the used download nodes are available, thereby improving the download speed of the user, saving network resources, improving the BT download efficiency, and avoiding the problem of network congestion.
As shown in fig. 3, a BT download node management method includes steps S301 to S306.
Step S301: at least one download node for BT download is obtained.
Specifically, the download node described in this application is defined as: a download node refers to a computer or other device connected to a network having a separate address and having the capability to transmit or receive data. The specific acquisition range is a full network range, including a local area network interior and a local area network exterior.
Step S302: the priority of the downloading node is determined.
Specifically, the obtained download nodes are firstly divided into a high priority and a low priority, wherein the download nodes inside the local area network are obtained by using an LSD algorithm, the download nodes inside the local area network are high priority nodes, the download nodes outside the local area network are obtained by using a DHT algorithm, and the download nodes outside the local area network are low priority nodes.
Step S303: and storing the downloading node into a preset storage space.
Further, the data structure of the storage space is a heap structure.
Further, the heap structure in this embodiment is a complete binary tree structure.
Further, the preset storage space is divided into a main set and a standby set.
And then, sequentially storing the high-priority nodes into the primary set, starting to store the high-priority nodes into the standby set after the primary set is full, and starting to store the low-priority nodes after all the high-priority nodes are stored into the set until all the nodes are stored into the set.
For example, assuming that the number of acquired download nodes is smaller than the capacity of the primary set, all the nodes are stored in the primary set. For example, assume that the total number of the download nodes acquired in step S301 is 5, where the number of the high-priority download nodes is 3, the number of the low-priority download nodes is 2, the primary set capacity may store 10 download nodes, and the backup set capacity may store 10 download nodes, and at this time, all the download nodes are directly stored in the primary set. Similarly, when the number of the acquired nodes is less than the storage capacity of the primary set, all the download nodes are directly stored in the primary set without distinguishing the priorities of the download nodes.
Further, for example, assuming that the total number of the download nodes obtained in step S301 is 16, where the number of the high-priority download nodes is 10, the number of the low-priority download nodes is 6, the primary aggregation capacity may store 10 download nodes, and the backup aggregation capacity may store 10 download nodes, the 10 high-priority download nodes are first stored in the primary aggregation, and then the 6 low-priority download nodes are stored in the backup aggregation, at this time, all the download nodes are stored in the preset storage space.
Further, for example, assuming that the total number of the download nodes obtained in step S301 is 30, where the number of the high-priority download nodes is 15, the number of the low-priority download nodes is 15, the capacity of the primary set can store 10 download nodes, and the usage of the backup set can store 10 download nodes, the 10 high-priority download nodes are first stored in the primary set, the remaining 5 high-priority download nodes are stored in the backup set, then the 5 low-priority download nodes are stored in the backup set, and all the remaining 10 low-priority download nodes are discarded.
Further, after all the download nodes are stored in the storage space, the LRU algorithm is used to sequence the stored download nodes in the main set from the top of the heap to the bottom of the heap in sequence according to the activity, and after the sequencing is completed, the arrangement sequence of the download nodes in the main set should be: the download node with the highest activity is at the top of the heap, and the download node with the lowest activity is at the bottom of the heap.
Further, the LRU algorithm is used to sequence the stored download nodes in the backup set from the top of the heap to the bottom of the heap in sequence according to the activity, and after the sequencing is completed, the arrangement sequence of the download nodes in the backup set should be: the download node with the highest activity is at the top of the heap, and the download node with the lowest activity is at the bottom of the heap.
Further, if the backup set is empty, the step of ordering the download nodes in the backup set is not performed.
Step S304: and scanning and updating the stored downloading nodes.
Further, after all the downloading nodes are sequenced, a first timer preset in the main set sends heartbeat information to the downloading nodes in the main set respectively, if reply information of a certain downloading node of the main set is not received within a set time threshold range, the downloading node is judged to be unavailable, the downloading node is deleted from the main set, and the downloading node is selected from the standby set and stored in the main set.
Further, after all the downloading nodes are sequenced, a second timer in the standby set sends heartbeat information to the downloading nodes in the standby set respectively, if the reply information of a certain downloading node in the standby set is not received within a set time threshold range, the node is judged to be unavailable, and the downloading node is deleted from the standby set.
Step S305: judging whether the main set is empty, if yes, returning to the step S301; if not, go to step S306.
Step S306: and using the downloading nodes in the main set to carry out BT downloading.
According to the BT download node management method, the at least one download node used for BT download is acquired, the acquired download nodes are stored according to priority, the acquired download nodes are divided into the main set and the standby set, and the download nodes in the main set are used for BT download tasks, so that a user can select the download nodes in the main set to carry out the BT download tasks without using all the download nodes when carrying out the BT download tasks, the used download nodes are available, the download speed of the user is improved, network resources are saved, the BT download efficiency is improved, and the problem of network congestion is avoided.
Secondly, the downloading nodes in the standby set are scanned and updated, so that the inactive downloading nodes in the standby set are ensured, the situation that the standby nodes are unavailable when the main set acquires the nodes from the standby set is ensured, the downloading nodes in the main set are high-quality downloading nodes, and the downloading speed of a user is ensured.
The present embodiment provides a BT download node management apparatus, referring to fig. 4, including:
an obtaining module 401 configured to obtain at least one download node for BT download;
a storage module 402, configured to determine that a storage space of each download node is a preset primary set or a backup set, and store the download node in a corresponding storage space, where the primary set is used to store download nodes used for downloading a current BT, and the backup set is used to store backup download nodes;
a downloading module 403, configured to perform BT downloading through the downloading node in the active set.
Further, the storage module 402 is configured to determine that the storage space of each download node is a preset active set or a preset standby set according to the number of each download node, the priority of each download node, the node capacity of the active set, and the node capacity of the standby set.
Further, the storage module 402 is configured to determine the priority of the download node according to the acquired location of the download node, where the download node acquired inside the local area network has a high priority and the download node acquired outside the local area network has a low priority.
Further, the storage module 402 is configured to:
if the number of the downloading nodes is smaller than the node capacity of the main set, determining that the storage space of the downloading nodes is a preset main set;
if the number of the download nodes is larger than the download node capacity of the main set and smaller than the sum of the node capacities of the download nodes of the main set and the standby set, storing the download nodes with high priority into the main set according to the priority of the download nodes, and storing the rest download nodes into the standby set after the main set is full of storage;
if the number of the download nodes is larger than the sum of the node capacities of the download nodes in the main set and the spare set, the download nodes with high priority are stored in the main set according to the priority of the download nodes, and after the main set is fully stored, the rest download nodes are stored in the spare set until the spare set is fully stored, and the rest download nodes which are not stored are discarded.
Further, the apparatus further comprises a deletion module configured to;
after all the downloading nodes are stored in the storage space, heartbeat information is respectively sent to the stored downloading nodes in the main set and the stored downloading nodes in the standby set;
if the reply information of any download node of the main set is not received within the range of the set time threshold, deleting the download node, and selecting the download node from the standby set to store in the main set;
and if the reply information of any download node of the standby set is not received within the range of the set time threshold, deleting the download node.
Furthermore, the storage structures of the active set and the standby set are heap structures;
further, in this embodiment, the heap structure is a complete binary tree structure;
the storage module 402 is configured to:
for the main set, acquiring the activity of the stored downloading nodes in the main set and the activity of the downloading nodes to be stored, and sequencing the stored downloading nodes in the main set from the top of the heap to the bottom of the heap in sequence from high to low according to the activity;
and for the standby set, acquiring the activity of the stored downloading nodes in the standby set and the activity of the downloading nodes to be stored, and sequencing the stored downloading nodes in the standby set from the top of the heap to the bottom of the heap in sequence from high to low according to the activity.
Further, the apparatus also includes a first timer module configured to:
updating and scanning a main set based on a preset first time interval, and sending heartbeat information to download nodes in the main set;
if the reply information of a certain download node is not received within the range of the set time threshold, the download node is deleted, and the download node is selected from the standby set and stored in the main set.
Further, the apparatus further comprises an ordering module configured to:
determining a downloading node with high priority in the standby set;
and taking the download node with the highest activity in the download nodes with high priority as an update node to be stored in the main set, and sequencing the stored download nodes and the update node in the main set from the top of the heap to the bottom of the heap in sequence from high to low according to the activity.
Further, the apparatus also includes a second timer module configured to:
updating and scanning a standby set based on a preset second time interval, and sending heartbeat information to download nodes in the standby set;
and if the reply message of any download node is not received within the range of the set time threshold, deleting the download node.
According to the BT download node management device, the at least one download node used for BT download is acquired, the acquired download nodes are stored according to priority, the acquired download nodes are divided into the main set and the standby set, and the download nodes in the main set are used for BT download tasks, so that the BT download tasks are performed by selecting the download nodes in the main set to perform the BT download tasks without using all the download nodes when a user performs the BT download tasks, the used download nodes are available, the download speed of the user is improved, network resources are saved, the BT download efficiency is improved, and the problem of network congestion is avoided.
Secondly, the downloading nodes in the standby set are scanned and updated, so that the inactive downloading nodes in the standby set are ensured, the situation that the standby nodes are unavailable when the main set acquires the nodes from the standby set is ensured, the downloading nodes in the main set are high-quality downloading nodes, and the downloading speed of a user is ensured.
An embodiment of the present application further provides a computer readable storage medium storing computer instructions, which when executed by a processor, implement the steps of a BT download node management method as described above.
The above is an illustrative scheme of a computer-readable storage medium of the present embodiment. It should be noted that the technical solution of the storage medium is the same as the above-mentioned BT download node management method and apparatus, and details of the technical solution of the storage medium, which are not described in detail, can be referred to the above-mentioned description of the technical solution of the BT download node management method.
The computer instructions comprise computer program code which may be in the form of source code, object code, an executable file or some intermediate form, or the like. The computer-readable medium may include: any entity or device capable of carrying the computer program code, recording medium, usb disk, removable hard disk, magnetic disk, optical disk, computer Memory, Read-Only Memory (ROM), Random Access Memory (RAM), electrical carrier wave signals, telecommunications signals, software distribution medium, etc. It should be noted that the computer readable medium may contain content that is subject to appropriate increase or decrease as required by legislation and patent practice in jurisdictions, for example, in some jurisdictions, computer readable media does not include electrical carrier signals and telecommunications signals as is required by legislation and patent practice.
It should be noted that, for the sake of simplicity, the above-mentioned method embodiments are described as a series of acts or combinations, but those skilled in the art should understand that the present application is not limited by the described order of acts, as some steps may be performed in other orders or simultaneously according to the present application. Further, those skilled in the art should also appreciate that the embodiments described in the specification are preferred embodiments and that the acts and modules referred to are not necessarily required in this application.
In the above embodiments, the descriptions of the respective embodiments have respective emphasis, and for parts that are not described in detail in a certain embodiment, reference may be made to related descriptions of other embodiments.
The preferred embodiments of the present application disclosed above are intended only to aid in the explanation of the application. Alternative embodiments are not exhaustive and do not limit the invention to the precise embodiments described. Obviously, many modifications and variations are possible in light of the above teaching. The embodiments were chosen and described in order to best explain the principles of the application and the practical application, to thereby enable others skilled in the art to best understand and utilize the application. The application is limited only by the claims and their full scope and equivalents.

Claims (12)

1. A BT download node management method, the method comprising:
acquiring at least one downloading node for BT downloading;
determining the storage space of each downloading node as a preset main set or a standby set, and storing the downloading nodes in the corresponding storage space, wherein the main set is used for storing the downloading nodes used for downloading the current BT, and the standby set is used for storing the standby downloading nodes;
and performing BT download through the download nodes in the main set.
2. The method of claim 1, wherein determining the storage space of each of the download nodes to be a preset active set or a preset standby set comprises:
and determining the storage space of each download node as a preset primary set or a preset standby set according to the number of each download node, the priority of each download node, the node capacity of the primary set and the node capacity of the standby set.
3. The method of claim 2, wherein the priority of the downloading node is determined by: and determining the priority of the download node according to the position acquired by the download node, wherein the download node acquired inside the local area network is high priority, and the download node acquired outside the local area network is low priority.
4. The method of claim 2, wherein determining that the storage space of each of the download nodes is a preset active set or a preset standby set according to the number of each of the download nodes, the priority of each of the download nodes, and the node capacity of the active set and the node capacity of the standby set comprises:
if the number of the downloading nodes is smaller than the node capacity of the main set, determining that the storage space of the downloading nodes is a preset main set;
if the number of the download nodes is larger than the download node capacity of the main set and smaller than the sum of the node capacities of the download nodes of the main set and the standby set, storing the download nodes with high priority into the main set according to the priority of the download nodes, and storing the rest download nodes into the standby set after the main set is full of storage;
if the number of the download nodes is larger than the sum of the node capacities of the download nodes in the main set and the spare set, the download nodes with high priority are stored in the main set according to the priority of the download nodes, and after the main set is fully stored, the rest download nodes are stored in the spare set until the spare set is fully stored, and the rest download nodes which are not stored are discarded.
5. The method of claim 1, wherein the method further comprises:
after all the downloading nodes are stored in the storage space, heartbeat information is respectively sent to the downloading nodes of the main set and the downloading nodes of the standby set;
if the reply information of any download node of the main set is not received within the range of the set time threshold, deleting the download node, and selecting the download node from the standby set to store in the main set;
and if the reply information of any download node of the standby set is not received within the range of the set time threshold, deleting the download node.
6. The method of claim 1, wherein the storage structures of the active set and the spare set are heap structures;
storing the download node in a corresponding storage space, including:
for the main set, acquiring the activity of the stored downloading nodes in the main set and the activity of the downloading nodes to be stored, and sequencing the stored downloading nodes in the main set from the top of the heap to the bottom of the heap in sequence from high to low according to the activity;
and for the standby set, acquiring the activity of the stored downloading nodes in the standby set and the activity of the downloading nodes to be stored, and sequencing the stored downloading nodes in the standby set from the top of the heap to the bottom of the heap in sequence from high to low according to the activity.
7. The method of claim 1, wherein the primary set is provided with a corresponding first timer;
the method further comprises the following steps: updating and scanning a main set based on a preset first time interval, and sending heartbeat information to download nodes in the main set;
if the reply information of a certain download node is not received within the range of the set time threshold, the download node is deleted, and the download node is selected from the standby set and stored in the main set.
8. The method as claimed in claim 5 or 7, wherein selecting the download node from the standby set to store in the active set comprises:
determining a downloading node with high priority in the standby set;
and taking the download node with the highest activity in the download nodes with high priority in the determined standby set as an update node to be stored in the main set, and sequencing the stored download nodes and the update nodes in the main set from the top of the heap to the bottom of the heap in sequence from high to low according to the activity.
9. The method of claim 1, wherein the backup set is provided with a corresponding second timer;
the method further comprises the following steps: updating and scanning a standby set based on a preset second time interval, and sending heartbeat information to download nodes in the standby set;
and if the reply message of any download node is not received within the range of the set time threshold, deleting the download node.
10. An apparatus for managing a BT download node, the apparatus comprising:
an acquisition module configured to acquire at least one download node;
the storage module is configured to determine that a storage space of each download node is a preset primary set or a preset backup set, and store the download nodes in corresponding storage spaces, wherein the primary set is used for storing the download nodes used for downloading the current BT, and the backup set is used for storing the backup download nodes;
and the downloading module is configured to perform BT downloading through the downloading nodes in the main set.
11. A computing device comprising a memory, a processor, and computer instructions stored on the memory and executable on the processor, wherein the processor implements the steps of the method of any one of claims 1-9 when executing the instructions.
12. A computer-readable storage medium storing computer instructions, which when executed by a processor, perform the steps of the method of any one of claims 1 to 9.
CN202010632353.9A 2020-07-03 2020-07-03 BT (bit BT) download node management method and device Pending CN111770188A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010632353.9A CN111770188A (en) 2020-07-03 2020-07-03 BT (bit BT) download node management method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010632353.9A CN111770188A (en) 2020-07-03 2020-07-03 BT (bit BT) download node management method and device

Publications (1)

Publication Number Publication Date
CN111770188A true CN111770188A (en) 2020-10-13

Family

ID=72723664

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010632353.9A Pending CN111770188A (en) 2020-07-03 2020-07-03 BT (bit BT) download node management method and device

Country Status (1)

Country Link
CN (1) CN111770188A (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101771931A (en) * 2008-12-26 2010-07-07 中国移动通信集团公司 P2P (peer 2 peer) resource downloading method and identification device
CN102546728A (en) * 2010-12-27 2012-07-04 北大方正集团有限公司 Peer-to-peer network resource downloading method
CN103327121A (en) * 2013-07-10 2013-09-25 亿览在线网络技术(北京)有限公司 P2P (Peer-to-Peer Network) network resource transmission method and device for same
CN106817266A (en) * 2015-12-01 2017-06-09 北京慧点科技有限公司 A kind of peer network resources method for down loading
CN109981751A (en) * 2019-03-06 2019-07-05 珠海金山网络游戏科技有限公司 A kind of document transmission method and system, computer equipment and storage medium

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101771931A (en) * 2008-12-26 2010-07-07 中国移动通信集团公司 P2P (peer 2 peer) resource downloading method and identification device
CN102546728A (en) * 2010-12-27 2012-07-04 北大方正集团有限公司 Peer-to-peer network resource downloading method
CN103327121A (en) * 2013-07-10 2013-09-25 亿览在线网络技术(北京)有限公司 P2P (Peer-to-Peer Network) network resource transmission method and device for same
CN106817266A (en) * 2015-12-01 2017-06-09 北京慧点科技有限公司 A kind of peer network resources method for down loading
CN109981751A (en) * 2019-03-06 2019-07-05 珠海金山网络游戏科技有限公司 A kind of document transmission method and system, computer equipment and storage medium

Similar Documents

Publication Publication Date Title
US9678678B2 (en) Storage network data retrieval
CN109981751B (en) File transmission method and system, computer equipment and storage medium
EP3242463B1 (en) Content distribution method and system for mobile terminal application
KR101752928B1 (en) Swarm-based synchronization over a network of object stores
US20080089299A1 (en) Method and system for distributing content in Ad-hoc networks using super peers
US8819137B2 (en) System and method for sharing mobile internet service
US20190014161A1 (en) Downloading of server-based content through peer-to-peer networks
CN111338806B (en) Service control method and device
EP2141601A1 (en) Content distribution device, content distribution method, and content distribution program
US9628567B2 (en) Methods and systems for efficient discovery of devices in a peer-to-peer network
KR20140004799A (en) Peer-to-peer data migration
WO2008082717A2 (en) Power-based resource sharing in a mesh network
WO2022242361A1 (en) Data download method and apparatus, computer device and storage medium
US20160156714A1 (en) Content placement in an information centric network
CN111770186A (en) Multi-content distribution network load balancing method and device
CN109947718A (en) A kind of date storage method, storage platform and storage device
CN111770188A (en) BT (bit BT) download node management method and device
US11012506B2 (en) Node and cluster management on distributed self-governed ecosystem
CN112637351B (en) File downloading method and device
RU2522995C2 (en) Method and apparatus for creating peer-to-peer group in peer-to-peer application and method of using peer-to-peer group
CN114385596A (en) Data processing method and device
CN115004657B (en) Addressing method, addressing system and addressing device
CN110611702B (en) Block chain file rapid transmission method, equipment, system and storage medium
JP5423497B2 (en) Information communication system, node device, information communication method, and program
CN101997889B (en) Method, system and device for optimizing P2P transmission in WLAN

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
CB02 Change of applicant information

Address after: 519000 room 402, Room 401, No. 327, Qiandao Ring Road, Tangjiawan Town, high tech Zone, Zhuhai City, Guangdong Province

Applicant after: Zhuhai Xishanju Digital Technology Co.,Ltd.

Address before: 519000 room 402, Room 401, No. 327, Qiandao Ring Road, Tangjiawan Town, high tech Zone, Zhuhai City, Guangdong Province

Applicant before: ZHUHAI SEASUN MOBILE GAME TECHNOLOGY Co.,Ltd.

CB02 Change of applicant information
RJ01 Rejection of invention patent application after publication

Application publication date: 20201013

RJ01 Rejection of invention patent application after publication