CN110012068B - Download control method, device and storage medium - Google Patents

Download control method, device and storage medium Download PDF

Info

Publication number
CN110012068B
CN110012068B CN201910157080.4A CN201910157080A CN110012068B CN 110012068 B CN110012068 B CN 110012068B CN 201910157080 A CN201910157080 A CN 201910157080A CN 110012068 B CN110012068 B CN 110012068B
Authority
CN
China
Prior art keywords
attribute value
client
acceleration
accelerated
bandwidth
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201910157080.4A
Other languages
Chinese (zh)
Other versions
CN110012068A (en
Inventor
徐俊俊
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing QIYI Century Science and Technology Co Ltd
Original Assignee
Beijing QIYI Century Science and Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing QIYI Century Science and Technology Co Ltd filed Critical Beijing QIYI Century Science and Technology Co Ltd
Priority to CN201910157080.4A priority Critical patent/CN110012068B/en
Publication of CN110012068A publication Critical patent/CN110012068A/en
Application granted granted Critical
Publication of CN110012068B publication Critical patent/CN110012068B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • 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]
    • 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/10Protocols in which an application is distributed across nodes in the network
    • H04L67/104Peer-to-peer [P2P] networks

Abstract

The invention provides a download control method, a device and a storage medium, wherein the method comprises the following steps: responding to a download acceleration request of a client, acquiring an acceleration attribute value required for accelerating the download of a file to be accelerated, and executing an acceleration request operation in an intelligent contract according to the acceleration attribute value, wherein the acceleration request operation comprises deducting the acceleration attribute value from a resource attribute value of a user existing in an account of the client; and after the acceleration request operation is successfully executed, providing an acceleration downloading service of the file to be accelerated for the client by using the server. Therefore, the resource attribute value of the user of the client account is determined based on the intelligent contract, the corresponding resource attribute value of the user can be calculated according to the recorded uploading data of the client and stored in the client account to exchange the file downloading acceleration rights and interests, the use of uploading bandwidth is further effectively stimulated, the resource utilization rate and the transmission rate of the P2P transmission method are improved, and the reasonable planning of data transmission by the user is facilitated.

Description

Download control method, device and storage medium
Technical Field
The present invention belongs to the field of block chain technology, and in particular, to a download control method, apparatus and storage medium.
Background
With the rapid development of the internet, users increasingly demand ultra high definition 4K/8K and interactive VR (chinese: Virtual Reality)/AR (chinese: Augmented Reality) services, and network operators are encouraged to gradually increase uplink and downlink bandwidths of users' homes. The data transmission among different devices is realized by utilizing the family uplink bandwidth based on the P2P (Chinese: person-to-person; English: peer-to-peer) technology, the ultrahigh-definition video fast transmission can be met, and the bandwidth cost of the CDN (Chinese: Content Delivery Network; English: Content Delivery Network) of an enterprise can be reduced.
In the prior art, the existing P2P data transmission strategy has low use efficiency of uplink bandwidth, and lacks a safe and transparent uploading incentive mode, so that it is difficult to ensure the P2P transmission rate and stability thereof. Meanwhile, the P2P transmission method is limited by resources and devices, which further reduces the stability of data transmission rate.
Disclosure of Invention
In view of the above, the present invention provides a download control method, apparatus and storage medium, and provides an effective computing mechanism to solve or at least partially solve the problem of low utilization efficiency of upload bandwidth in the prior art.
According to a first aspect of the present invention, there is provided a download control method applied to a blockchain system having an intelligent contract, where the intelligent contract is used to control a download speed of a client according to upload data of the client, the method including:
responding to a download acceleration request of the client, and acquiring an acceleration attribute value required for accelerating downloading of a file to be accelerated, wherein the file to be accelerated is a file to be accelerated and downloaded in the download acceleration request, and the acceleration attribute value is obtained according to an acceleration attribute value algorithm in the intelligent contract;
executing an acceleration request operation in the intelligent contract according to the acceleration attribute value, wherein the acceleration request operation comprises deducting the acceleration attribute value from a resource attribute value of a user existing in a client account, and the resource attribute value of the user is obtained through a single contribution attribute value determined according to the uploading data of the client;
and after the acceleration request operation is successfully executed, providing an acceleration downloading service of the file to be accelerated for the client by using a server, wherein at least the file to be accelerated is stored on the server.
According to a second aspect of the present invention, there is provided a download control apparatus applied to a blockchain system having an intelligent contract for controlling a download speed of a client according to upload data of the client, the apparatus including:
an attribute value obtaining module, configured to respond to a download acceleration request of the client, obtain an acceleration attribute value required for accelerating downloading of a file to be accelerated, where the file to be accelerated is a file to be accelerated in the download acceleration request, and the acceleration attribute value is obtained according to an acceleration attribute value algorithm in the intelligent contract
An operation execution module, configured to execute an acceleration request operation in the smart contract according to the acceleration attribute value, where the acceleration request operation includes deducting the acceleration attribute value from a resource attribute value of a user existing in a client account, and the resource attribute value of the user is obtained through a single contribution attribute value determined according to upload data of the client;
and the accelerated downloading module is used for providing an accelerated downloading service of the file to be accelerated for the client by using a server after the acceleration request operation is successfully executed, wherein at least the file to be accelerated is stored on the server.
According to a third aspect of the present invention, there is provided a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, implements the steps of the download control method as described in the first aspect.
Aiming at the technologies, the invention has the following advantages:
according to the download acceleration request of the client, acquiring an acceleration attribute value required for realizing the acceleration request, therefore, corresponding attribute values can be determined for different download acceleration requests, corresponding acceleration attribute values are deducted from the account of the client by using an intelligent contract, further normalized realization is realized through the operation of exchanging the attribute values for accelerated downloading, after the acceleration attribute values are successfully deducted from the account of the client, the fact that enough tokens for starting the accelerated downloading of files to be accelerated are arranged in the account of the client is indicated, the download acceleration operation based on the intelligent contract can be realized, further the server is used for providing the accelerated downloading service of the files to be accelerated, the problem that the transmission rate cannot be ensured due to the limitation of resources and equipment in the P2P transmission mode is overcome, and further the server with high equipment performance and stable resources is used as a data source, to ensure the speed of the downloading operation and the stability of the transmission. The resource attribute value determined according to the uploading data of the client in the client account can be used for realizing the required downloading acceleration request, namely, the public and transparent control of the downloading speed by using the uploading data in the block chain system is realized by using an intelligent contract, and as the high uploading data generates the high resource attribute value, a plurality of downloading acceleration requests can be honored, so that the use of the uploading bandwidth is stimulated, the use efficiency of the uplink bandwidth is improved, and the reasonable planning of data transmission is facilitated.
The foregoing description is only an overview of the technical solutions of the present invention, and the embodiments of the present invention are described below in order to make the technical means of the present invention more clearly understood and to make the above and other objects, features, and advantages of the present invention more clearly understandable.
Drawings
Various other advantages and benefits will become apparent to those of ordinary skill in the art upon reading the following detailed description of the preferred embodiments. The drawings are only for purposes of illustrating the preferred embodiments and are not to be construed as limiting the invention. Also, like reference numerals are used to refer to like parts throughout the drawings. In the drawings:
fig. 1 is a flowchart illustrating steps of a download control method according to an embodiment of the present invention;
fig. 2 is a flowchart illustrating steps of a download control method according to an embodiment of the present invention;
FIG. 3 is a block chain structure according to an embodiment of the present invention;
fig. 4 is a flowchart illustrating specific steps of a download control method according to an embodiment of the present invention;
fig. 5 is a flowchart illustrating specific steps of a download control method according to an embodiment of the present invention;
fig. 6 is a block diagram of a download control apparatus according to an embodiment of the present invention.
Detailed Description
Exemplary embodiments of the present invention will be described in more detail below with reference to the accompanying drawings. While exemplary embodiments of the invention are shown in the drawings, it should be understood that the invention can be embodied in various forms and should not be limited to the embodiments set forth herein. Rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the invention to those skilled in the art.
Before describing the specific embodiment of the present invention, the technical background applied by the present invention is described, and an intelligent contract is a section of code written on a block chain, and is automatically executed when a certain event triggers a term in the intelligent contract to meet an execution condition. The specific content in the intelligent contract is jointly participated and established by a plurality of users in the block chain, can be used for any transaction behavior between the users, wherein the right and obligation of each party participating in the contract agreement are definitely specified, and are programmed in an electronic mode. After programming is completed, the intelligent contract is uploaded to the block chain, and the intelligent contract is received by all network verification nodes. Meanwhile, the intelligent contract can also regularly check whether relevant events and trigger conditions exist, and push the events meeting the trigger conditions to a queue to be verified. Taking an ether house as an example, the intelligent contracts on the ether house consume the ether coins to realize the fulfillment of the contracts. The technical scheme provided by the invention is based on a block chain network, and can be an Etheng, an EOS (English: Enterprise operation System; Chinese: Enterprise operating System) or an alliance chain or a private chain of a super account book. For the intelligent contract involved in the technical scheme proposed by the invention, the currency involved is called Token (Token), and the exchange of the contribution value of the uploaded data into the downloading acceleration interest can be realized. The specific token value generation strategy is as follows:
fig. 1 is a flowchart illustrating specific steps of a download control method according to an embodiment of the present invention, as shown in fig. 1, when applied to a blockchain system having an intelligent contract, the method may include:
step 101, acquiring the uploading data of the client recorded on the block chain system.
The uploaded data comprises busy hour time, busy hour bandwidth, idle time and idle time bandwidth of the client in a preset time.
In a specific application, the uploaded data of each client in the whole blockchain system can be recorded and stored by using the blockchain system, so that a corresponding attribute contribution value is added to a client account according to the uploaded data of the client by using a contribution value calculation method set in an intelligent contract. Illustratively, with 5 minutes as a duration unit, respectively recording busy hour duration (total uploading time in a busy hour period, that is, the total number of 5 minutes in the unit duration), busy hour bandwidth (total bandwidth in the above busy hour period), idle hour duration (uploading time in an idle hour period, the total number of 5 minutes) and idle hour bandwidth (total bandwidth in the idle hour period), setting 18 to 23 points as the busy hour period, and the rest as the idle hour period, for example, setting a preset duration as 1 day, that is, counting the uploading data in one day, and then calculating a single attribute contribution value, that is, a single-day contribution value, using the following steps. It should be noted that the busy hour period, the preset duration and the duration unit can all be adjusted according to actual conditions, and when the duration unit changes or the preset duration or the busy hour period changes, the busy hour duration and the idle hour duration also change correspondingly.
And 102, calculating a single contribution attribute value of the client according to the uploaded data and an attribute threshold value set in the intelligent contract.
Illustratively, a daily attribute threshold is set in the smart contract as the maximum attribute value that can be obtained within a day. And calculating a contribution value according to the upload data, wherein the contribution value can be a proportional value (between 0 and 1), which represents the contribution of the client to the upload bandwidth in one day, and determining a single attribute contribution value of the current date, namely the current day contribution value, by combining with the maximum attribute threshold value.
Step 103, adding the single contribution attribute value in the resource attribute value.
Illustratively, the single attribute contribution value determined in step 102 is stored in the client account, so that when the user of the client is to be accelerated, the user deducts the resource attribute value of the user already in the client account to exchange the corresponding accelerated downloading interest of the file to be accelerated.
It should be noted that, the step of calculating the single attribute contribution value is continuously performed within a preset time period, for example, the calculation of the single attribute contribution value is performed once every day (preset time period) and then stored in the client account, and the current total contribution value is always stored in the client account, so as to provide the user with the required exchange of the user rights and interests based on a reasonable mechanism or a calculation strategy, for example, an accelerated download rights and interests. And under the condition that the user does not exchange any user rights and interests, the resource attribute value of the user is always stored in the client account. In addition, the maximum storage time length can be limited, when the user does not perform the exchange operation after exceeding the maximum storage time length, the user is reminded, the user is prompted to clear the resource attribute value when the user does not use the resource attribute value for a long time, and the like, so that the resource attribute value in the client account is managed.
Therefore, after adding the single contribution attribute value in the client account according to the above steps, the resource attribute value of the existing user in the client account may be utilized to perform corresponding redemption of the download acceleration right, as described in the following embodiments.
Fig. 2 is a flowchart of steps of a download control method provided in an embodiment of the present invention, as shown in fig. 2, where the smart contract on the blockchain system is used to control a download speed of the client according to upload data of the client, and the method may further include, after step 103:
step 201, in response to a download acceleration request of a client, obtaining an acceleration attribute value required for accelerating download of a file to be accelerated.
The file to be accelerated is a file to be accelerated and downloaded in the download acceleration request, and the acceleration attribute value is obtained according to an acceleration attribute value algorithm in the intelligent contract.
Illustratively, an exemplary structure of a blockchain according to the present invention is shown in fig. 3, since an intelligent contract on a blockchain system can be queried by any client for contract codes and all transaction details of its own account, etc., and data can be recorded in the blockchain in a public and non-falsifiable manner. In this embodiment, 2 clients are taken as examples, and a basic P2P module and a blockchain lightweight node are run on the two clients, and a blockchain account is also stored for calling and querying an intelligent contract. The server may include a plurality of servers, where the data server is configured to record upload data of the client within a preset time interval, and send the aggregated data to a contractual super node (contractornode) to determine a resource attribute value of the user and determine an acceleration attribute value according to a download acceleration request; the super contract node informs the resource server of the calculation result of the resource attribute value, and stores the resource which the client needs to accelerate downloading, such as a file to be accelerated. And then after the super contract node informs the resource server that the client can start accelerated downloading, the resource server provides accelerated downloading service for the client according to the setting in the intelligent contract.
In a specific application, when a user of one of the clients wants to download a certain file data in an accelerated manner, the client needs to send a request for downloading the file data in an accelerated manner, for example, a corresponding option button for downloading acceleration is provided on a download page of the file data, after the user clicks the option button, the client generates and sends a request for downloading the file data (file to be accelerated), where the request includes information such as an ID corresponding to the file to be accelerated and/or a client ID for identifying the identity of the client, and the server determines an acceleration attribute value corresponding to the request for downloading according to an acceleration attribute value algorithm of an intelligent contract in response to the request for downloading acceleration, so as to perform the following steps.
In a specific application, the acceleration attribute value algorithm in the intelligent contract includes determining an acceleration attribute value required for accelerating downloading of the file to be accelerated according to an attribute proportion value corresponding to the data size of the file to be accelerated, where the acceleration attribute value corresponding to the file of 100M is 0.5, for example.
It should be noted that the client may also invoke the intelligent contract by itself to implement the determination operation of the acceleration attribute value required by the file to be accelerated, and the specific invention is not limited thereto.
And 202, executing an acceleration request operation in the intelligent contract according to the acceleration attribute value.
The acceleration request operation comprises deducting an acceleration attribute value from a resource attribute value of a user existing in a client account, wherein the resource attribute value of the user is obtained through a single contribution attribute value determined according to uploaded data of the client.
In a specific application, in order to implement an incentive for using an upload bandwidth, a data server is used to determine a resource attribute value of a user in a client account according to upload data of the client recorded on a blockchain system, as described in the embodiment of fig. 1, which is not described herein again. Further, in step 201, after the acceleration attribute value is determined according to the download acceleration request, a corresponding acceleration request operation is executed, that is, the acceleration attribute value is deducted from the client account, and the acceleration attribute value is transferred to the server account, so as to realize the exchange of one equivalent right (accelerated download corresponding to the acceleration attribute value).
It should be noted that, as shown in fig. 3, a solid line between the super contract node and the client indicates that the resource attribute value statistics are performed on each client, and a dotted line between the super contract node and the client indicates that the acceleration attribute value is deducted from the client account and transferred to the server account.
And step 203, after the acceleration request operation is successfully executed, providing an acceleration downloading service of the file to be accelerated for the client by using the server.
Wherein, at least files to be accelerated are saved on the server.
In a specific application, the acceleration attribute value is successfully deducted from the client account through the steps, which indicates that there is enough resource attribute value in the client account, and then the corresponding acceleration downloading operation can be started by using the server. Examples of settings in smart contracts are: the resource server is directly triggered to start to provide accelerated downloading service for the client while the accelerated attribute value is successfully deducted from the client account, for example, the resource server can be informed in a message or switch mode, so that the resource server serves as a sending end to provide transmission of a file to be accelerated for the client (serving as a receiving end), and further the downlink bandwidth of the client is increased, and more downlink bandwidth resources are allocated to the client to realize accelerated downloading of the file to be accelerated.
It should be noted that, since in the P2P transmission mode, it is possible that due to the unavailable resources and the hardware limitation of the client itself, and the problem that the data transmission rate is too slow (the number of resources is small, namely the number of clients uploading the resources is small) or the clients (the clients needing to download the resources) cannot acquire the data resources because of no transmittable resources (the clients without uploading the resources) is caused, the excitation of the technical scheme provided by the invention on the use of the uploading bandwidth can improve the resource quality of P2P, such as increasing the number and/or duration of resources present by converting the upload data to resource attribute values, when data is required to be acquired through P2P, the resource attribute value can be converted into a download acceleration right, the transmission rate and stability of P2P are guaranteed by using available resources, and the use of uploading bandwidth is stimulated; and after the user exchanges the accelerated downloading rights and interests by using the resource attribute values, the file to be accelerated can be directly downloaded from the server, the hardware limitation existing in a P2P transmission mode is overcome, and the data downloading speed is further improved. Wherein the dashed arrow between the resource server and the client, as shown in fig. 3, represents an accelerated download process.
In addition, the acceleration attribute value algorithm in the intelligent contract can determine the required acceleration attribute value according to a certain proportional relation (attribute proportional value) according to the data volume of the file to be accelerated, and can also divide attribute proportional values corresponding to loading bandwidths of different levels for selection by a user, for example, the bandwidth can be increased from 80Mbps to 100Mbps according to the certain proportional relation corresponding to different bandwidth sizes, for example, when the attribute proportional value is 0.1; when the attribute ratio value is 0.3, the bandwidth can be increased from 80Mbps to 120Mbps, and the like, and the user can correspondingly select a proper attribute ratio value according to the actual demand and the resource attribute value of the user existing in the client account thereof to obtain the corresponding bandwidth, which is not limited by the invention.
According to the technical scheme provided by the invention, by utilizing the characteristics of disclosure and non-falsification of the intelligent contract on the block chain, the mode of determining the resource attribute value through the uploading contribution (uploading data) is written into the block chain system in the form of codes (intelligent contract), so that the uploading data is converted into user rights and interests (such as downloading acceleration, membership cards and the like), the user is explicitly stimulated to upload, and the realization of accelerated transmission is ensured through the intelligent contract specification in the block chain system and the rights and obligations set in the realization contract.
In summary, the download control method provided by the present invention, in response to a download acceleration request from a client, obtains an acceleration attribute value required for accelerating downloading of a file to be accelerated, and executes an acceleration request operation in an intelligent contract according to the acceleration attribute value, where the acceleration request operation includes deducting the acceleration attribute value from a resource attribute value of a user existing in an account of the client; and after the acceleration request operation is successfully executed, providing an acceleration downloading service of the file to be accelerated for the client by using the server. Therefore, the resource attribute value of the user of the client account is determined based on the intelligent contract, the corresponding resource attribute value of the user can be calculated according to the recorded uploading data of the client and stored in the client account to exchange the file downloading acceleration rights and interests, the use of uploading bandwidth is further effectively stimulated, the resource utilization rate and the transmission rate of the P2P transmission method are improved, and the reasonable planning of data transmission by the user is facilitated.
Optionally, fig. 4 is a flowchart of specific steps of a download control method provided by an embodiment of the present invention, and as shown in fig. 4, the calculating a single attribute contribution value of the client according to the upload data and the attribute threshold set in the intelligent contract in step 102 may include:
and 1021, calculating the contribution value of the client in the preset recording duration according to the uploaded data.
Illustratively, the contribution values include a busy hour duration portion, a busy hour bandwidth portion, an idle duration portion, and an idle bandwidth portion.
In a specific application, the product of the busy hour duration and a preset busy hour weight is used as a busy hour duration part T1; taking the product of the idle time duration and the preset idle time weight as an idle time duration part T2; taking the product of the minimum value of the busy hour bandwidth and the maximum busy hour bandwidth and a preset busy hour bandwidth weight as a busy hour bandwidth part T3; taking the product of the minimum value of the idle bandwidth and the maximum idle bandwidth and a preset idle bandwidth weight as an idle bandwidth part T4; and normalizing the busy hour duration part, the busy hour bandwidth part, the idle hour duration part and the idle hour bandwidth part to determine a contribution value.
The preset idle time weight is smaller than the preset busy time weight, and the preset idle time bandwidth weight is smaller than the preset busy time bandwidth weight.
For example, in a case where a busy period is set from 18 to 23 points and idle periods are set in a unit of 5 minutes as a duration, the number of busy periods is less than or equal to 72(6 × 60/5), the idle period is less than or equal to 216(18 × 60/5), and in a case where the upload traffic rate is 80Mbps, the upload traffic rate is not more than 3GB for 5 minutes, the contribution value calculation formula is as follows:
Figure BDA0001983262190000091
wherein A represents a contribution value (0 is less than or equal to A and less than or equal to 1), b _ t represents a busy hour time length, W (b _ t) represents a preset busy hour weight, i _ t represents an idle hour time length, W (i _ t) represents a preset idle hour weight, b _ gbyte represents a busy hour bandwidth, W (b _ gbyte) represents a preset busy hour bandwidth weight, i _ gbyte represents an idle hour bandwidth, and W (i _ gbyte) represents a preset idle hour bandwidth weight.
For example, W (b _ t) ═ W (i _ gbyte) ═ 5, W (i _ t) ═ 1, and W (b _ gbyte) ═ 10; then:
Figure BDA0001983262190000101
t1;
Figure BDA0001983262190000102
is T2;
Figure BDA0001983262190000103
is T3;
Figure BDA0001983262190000104
is T4.
Note that, in the case where different busy-hour periods and idle-hour periods are set, the specific values in the formula are adaptively changed. For example, an exemplary upload traffic speed of 80Mbps is adopted in the above formula, while the upload traffic speed in practical cases is generally between 10Mbps and 20Mbps, and as the overall uplink bandwidth of the user becomes larger, the upload traffic speed is correspondingly adjusted, so that the corresponding 5-minute upload traffic in the corresponding adjustment formula does not exceed a value of 3 GB.
Step 1022, use the product of the contribution value and the attribute threshold as the single attribute contribution value.
Illustratively, the product of the contribution value calculated in step 1021 and the attribute threshold is added to the client account as a single attribute contribution value (single attribute contribution value on the current day).
Optionally, fig. 5 is a flowchart of specific steps of a download control method provided in an embodiment of the present invention, and as shown in fig. 5, the acquiring, in response to a download acceleration request of a client, an acceleration attribute value required for accelerating downloading of a file to be accelerated in step 201 may include:
in step 2011, the data size of the file to be accelerated and the attribute ratio value corresponding to the data size of the file to be accelerated in the acceleration attribute value algorithm are obtained.
Step 2012, the product of the attribute ratio value and the data size of the file to be accelerated is used as the acceleration attribute value.
Illustratively, the calculation value algorithm set in the smart contract is: taking the product of the attribute ratio value and the data size of the file to be accelerated as an acceleration attribute value, for example, the attribute ratio value set within 500M in the acceleration attribute value algorithm is 0.05, and when the user needs to accelerate to download a file with a size of 324M, the required acceleration attribute value is 324 × 0.05 — 16.2. Other calculation strategies for determining the acceleration attribute value according to the download acceleration request can be applied to the present invention, and are not limited herein.
Fig. 6 is a block diagram of a download control apparatus according to an embodiment of the present invention, applied to a blockchain system having an intelligent contract, where the intelligent contract is used to control a download speed of a client according to upload data of the client, and as shown in fig. 6, the apparatus 600 includes:
the attribute value obtaining module 610 is configured to, in response to a download acceleration request of a client, obtain an acceleration attribute value required for accelerating downloading of a file to be accelerated, where the file to be accelerated is a file to be accelerated and downloaded in the download acceleration request, and the acceleration attribute value is obtained according to an acceleration attribute value algorithm in an intelligent contract.
And the operation executing module 620 is configured to execute an acceleration request operation in the intelligent contract according to the acceleration attribute value, where the acceleration request operation includes deducting the acceleration attribute value from a resource attribute value of a user existing in the client account, and the resource attribute value of the user is obtained through a single contribution attribute value determined according to the upload data of the client.
The accelerated downloading module 630 is configured to, after the acceleration request operation is successfully executed, provide an accelerated downloading service of the file to be accelerated for the client by using the server, where at least the file to be accelerated is stored in the server.
Optionally, the apparatus 600 further includes:
and the data acquisition module is used for acquiring the uploading data of the client recorded on the block chain system before the step of responding to the download acceleration request of the client and acquiring the acceleration attribute value required by accelerating the download of the file to be accelerated.
And the attribute value determining module is used for calculating the single contribution attribute value of the client according to the uploaded data and the attribute threshold value set in the intelligent contract.
And the attribute value increasing module is used for increasing the single contribution attribute value in the resource attribute value.
Optionally, the attribute value determining module includes:
and the contribution value operator module is used for calculating the contribution value of the client in the preset recording duration according to the uploaded data.
And the contribution value determination submodule is used for taking the product of the contribution value and the attribute threshold value as a single attribute contribution value.
Optionally, the uploaded data includes a busy hour duration, a busy hour bandwidth, an idle hour duration and an idle hour bandwidth of the client within a preset duration; a contribution value operator module comprising:
a busy hour duration acquisition unit for taking the product of the busy hour duration and a preset busy hour weight as a busy hour duration part;
an idle time duration obtaining unit, configured to use a product of an idle time duration and a preset idle time weight as an idle time duration part;
a busy hour bandwidth acquiring unit, configured to take a product of a minimum value of the busy hour bandwidth and the maximum busy hour bandwidth and a preset busy hour bandwidth weight as a busy hour bandwidth part;
the idle bandwidth acquiring unit is used for taking the product of the minimum value of the idle bandwidth and the maximum idle bandwidth and a preset idle bandwidth weight as an idle bandwidth part;
the normalization processing unit is used for performing normalization processing on the busy hour duration part, the busy hour bandwidth part, the idle hour duration part and the idle hour bandwidth part to determine a contribution value;
the preset idle time weight is smaller than the preset busy time weight, and the preset idle time bandwidth weight is smaller than the preset busy time bandwidth weight.
Optionally, the attribute value obtaining module includes:
and the information acquisition submodule is used for acquiring the data volume of the file to be accelerated and the attribute proportion value corresponding to the data volume of the file to be accelerated in the acceleration attribute value algorithm.
And the attribute value operator module is used for taking the product of the attribute proportion value and the data volume of the file to be accelerated as an acceleration attribute value.
In addition, an embodiment of the present invention further provides a terminal, which includes a processor, a memory, and a computer program stored in the memory and capable of running on the processor, where the computer program, when executed by the processor, implements each process of the foregoing download control method embodiment, and can achieve the same technical effect, and details are not repeated here to avoid repetition.
The embodiment of the present invention further provides a computer-readable storage medium, where a computer program is stored on the computer-readable storage medium, and when the computer program is executed by a processor, the computer program implements each process of the foregoing embodiment of the download control method, and can achieve the same technical effect, and in order to avoid repetition, details are not repeated here. The computer-readable storage medium may be a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk.
For the above device embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and for the relevant points, refer to the partial description of the method embodiment.
The embodiments in the present specification are described in a progressive manner, each embodiment focuses on differences from other embodiments, and the same and similar parts among the embodiments are referred to each other.
As is readily imaginable to the person skilled in the art: any combination of the above embodiments is possible, and thus any combination between the above embodiments is an embodiment of the present invention, but the present disclosure is not necessarily detailed herein for reasons of space.
The download control methods provided herein are not inherently related to any particular computer, virtual system, or other apparatus. Various general purpose systems may also be used with the teachings herein. The structure required to construct a system incorporating aspects of the present invention will be apparent from the description above. Moreover, the present invention is not directed to any particular programming language. It is appreciated that a variety of programming languages may be used to implement the teachings of the present invention as described herein, and any descriptions of specific languages are provided above to disclose the best mode of the invention.
In the description provided herein, numerous specific details are set forth. It is understood, however, that embodiments of the invention may be practiced without these specific details. In some instances, well-known methods, structures and techniques have not been shown in detail in order not to obscure an understanding of this description.
Similarly, it should be appreciated that in the foregoing description of exemplary embodiments of the invention, various features of the invention are sometimes grouped together in a single embodiment, figure, or description thereof for the purpose of streamlining the invention and aiding in the understanding of one or more of the various inventive aspects. However, the method of the invention should not be construed to reflect the intent: that the invention as claimed requires more features than are expressly recited in each claim. Rather, as the following claims reflect, inventive aspects lie in less than all features of a single foregoing disclosed embodiment. Thus, the claims following the detailed description are hereby expressly incorporated into this detailed description, with each claim standing on its own as a separate embodiment of this invention.
Those skilled in the art will appreciate that the modules in the device in an embodiment may be adaptively changed and disposed in one or more devices different from the embodiment. The modules or units or components of the embodiments may be combined into one module or unit or component, and furthermore they may be divided into a plurality of sub-modules or sub-units or sub-components. All of the features disclosed in this specification (including any accompanying claims, abstract and drawings), and all of the processes or elements of any method or apparatus so disclosed, may be combined in any combination, except combinations where at least some of such features and/or processes or elements are mutually exclusive. Each feature disclosed in this specification (including any accompanying claims, abstract and drawings) may be replaced by alternative features serving the same, equivalent or similar purpose, unless expressly stated otherwise.
Furthermore, those skilled in the art will appreciate that while some embodiments described herein include some features included in other embodiments, rather than other features, combinations of features of different embodiments are meant to be within the scope of the invention and form different embodiments. For example, in the claims, any of the claimed embodiments may be used in any combination.
The various component embodiments of the invention may be implemented in hardware, or in software modules running on one or more processors, or in a combination thereof. Those skilled in the art will appreciate that a microprocessor or Digital Signal Processor (DSP) may be used in practice to implement some or all of the functions of some or all of the components of the download control method according to embodiments of the invention. The present invention may also be embodied as apparatus or device programs (e.g., computer programs and computer program products) for performing a portion or all of the methods described herein. Such programs implementing the present invention may be stored on computer-readable media or may be in the form of one or more signals. Such a signal may be downloaded from an internet website or provided on a carrier signal or in any other form.
It should be noted that the above-mentioned embodiments illustrate rather than limit the invention, and that those skilled in the art will be able to design alternative embodiments without departing from the scope of the appended claims. In the claims, any reference signs placed between parentheses shall not be construed as limiting the claim. The word "comprising" does not exclude the presence of elements or steps not listed in a claim. The word "a" or "an" preceding an element does not exclude the presence of a plurality of such elements. The invention may be implemented by means of hardware comprising several distinct elements, and by means of a suitably programmed computer. In the unit claims enumerating several means, several of these means may be embodied by one and the same item of hardware. The usage of the words first, second and third, etcetera do not indicate any ordering. These words may be interpreted as names.

Claims (11)

1. A download control method, applied to a blockchain system having an intelligent contract, where the intelligent contract is used to control a download speed of a client according to upload data of the client, the blockchain includes a server, the server includes a data server, and the client stores a blockchain account, the method includes:
responding to a download acceleration request of the client, and acquiring an acceleration attribute value required for accelerating downloading of a file to be accelerated, wherein the file to be accelerated is a file to be accelerated and downloaded in the download acceleration request, and the acceleration attribute value is obtained according to an acceleration attribute value algorithm in the intelligent contract;
executing an acceleration request operation in the intelligent contract according to the acceleration attribute value, wherein the acceleration request operation comprises deducting the acceleration attribute value from a resource attribute value of a user existing in a client account, and the resource attribute value of the user is obtained by the intelligent contract according to a single contribution attribute value determined by the uploaded data of the client recorded by the data server;
and after the acceleration request operation is successfully executed, the intelligent contract informs a resource server to provide an acceleration downloading service of the file to be accelerated for the client, wherein the resource server is a server stored with the file to be accelerated.
2. The method according to claim 1, wherein before the step of obtaining an acceleration attribute value required for accelerating downloading of a file to be accelerated in response to a download acceleration request from the client, the method further comprises:
acquiring the uploading data of the client recorded on the block chain system;
calculating a single contribution attribute value of the client according to the uploading data and an attribute threshold value set in the intelligent contract;
adding the single-contribution attribute value to the resource attribute value.
3. The method of claim 2, wherein calculating the client's single-contribution attribute value according to the upload data and an attribute threshold set in the smart contract comprises:
calculating the contribution value of the client within a preset recording duration according to the uploaded data;
taking the product of the contribution value and the attribute threshold as the single contribution attribute value.
4. The method of claim 3, wherein the upload data comprises a busy hour duration, a busy hour bandwidth, an idle hour duration and an idle hour bandwidth of the client within the preset recording duration; calculating the contribution value of the client within the preset recording duration according to the uploaded data, wherein the calculation comprises the following steps:
taking the product of the busy hour duration and a preset busy hour weight as the busy hour duration part;
taking the product of the idle time duration and a preset idle time weight as the idle time duration part;
taking the product of the minimum value of the busy hour bandwidth and the maximum busy hour bandwidth and a preset busy hour bandwidth weight as the busy hour bandwidth part;
taking the product of the minimum value of the idle bandwidth and the maximum idle bandwidth and a preset idle bandwidth weight as the idle bandwidth part;
normalizing the busy hour time length part, the busy hour bandwidth part, the idle hour time length part and the idle hour bandwidth part to determine the contribution value;
the preset idle time weight is smaller than the preset busy time weight, and the preset idle time bandwidth weight is smaller than the preset busy time bandwidth weight.
5. The method according to claim 1, wherein the obtaining, in response to the download acceleration request from the client, an acceleration attribute value required for accelerating the download of the file to be accelerated comprises:
acquiring the data volume of the file to be accelerated and an attribute proportion value corresponding to the data volume of the file to be accelerated in the acceleration attribute value algorithm;
and taking the product of the attribute proportion value and the data volume of the file to be accelerated as the acceleration attribute value.
6. A download control apparatus, applied to a blockchain system having an intelligent contract, where the intelligent contract is used to control a download speed of a client according to upload data of the client, the blockchain includes a server, the server includes a data server, and the client stores a blockchain account, the apparatus includes:
an attribute value obtaining module, configured to respond to a download acceleration request of the client, obtain an acceleration attribute value required for accelerating downloading of a file to be accelerated, where the file to be accelerated is a file to be accelerated in the download acceleration request, and the acceleration attribute value is obtained according to an acceleration attribute value algorithm in the intelligent contract
An operation execution module, configured to execute an acceleration request operation in the intelligent contract according to the acceleration attribute value, where the acceleration request operation includes deducting the acceleration attribute value from a resource attribute value of a user existing in a client account, and the resource attribute value of the user is obtained by the intelligent contract according to a single contribution attribute value determined by the upload data of the client recorded by the data server;
and the accelerated downloading module is used for informing a resource server of providing an accelerated downloading service of the file to be accelerated for the client by the intelligent contract after the acceleration request operation is successfully executed, wherein the resource server is a server in which the file to be accelerated is stored.
7. The apparatus of claim 6, further comprising:
the data acquisition module is used for acquiring the uploading data of the client recorded on the blockchain system before the step of responding to the download acceleration request of the client and acquiring the acceleration attribute value required by accelerating the download of the file to be accelerated;
the attribute value determining module is used for calculating the single contribution attribute value of the client according to the uploading data and the attribute threshold value set in the intelligent contract;
an attribute value increasing module for increasing the single-contribution attribute value in the resource attribute value.
8. The apparatus of claim 7, wherein the attribute value determination module comprises:
the contribution value operator module is used for calculating the contribution value of the client within a preset recording duration according to the uploaded data;
a contribution value determination submodule for taking a product of the contribution value and the attribute threshold as the single-contribution attribute value.
9. The apparatus of claim 8, wherein the upload data comprises a busy hour duration, a busy hour bandwidth, an idle hour duration, and an idle hour bandwidth of the client within the preset recording duration; the contribution value operator module comprising:
a busy hour duration acquisition unit, configured to use a product of the busy hour duration and a preset busy hour weight as the busy hour duration part;
an idle time duration obtaining unit, configured to use a product of the idle time duration and a preset idle time weight as the idle time duration part;
a busy hour bandwidth acquiring unit, configured to use a product of a minimum value of the busy hour bandwidth and a maximum busy hour bandwidth and a preset busy hour bandwidth weight as the busy hour bandwidth part;
an idle bandwidth acquiring unit, configured to use a product of a minimum value of the idle bandwidth and the maximum idle bandwidth and a preset idle bandwidth weight as the idle bandwidth part;
a normalization processing unit, configured to perform normalization processing on the busy hour duration part, the busy hour bandwidth part, the idle hour duration part, and the idle hour bandwidth part, and determine the contribution value;
the preset idle time weight is smaller than the preset busy time weight, and the preset idle time bandwidth weight is smaller than the preset busy time bandwidth weight.
10. The apparatus of claim 6, wherein the attribute value obtaining module comprises:
the information acquisition submodule is used for acquiring the data volume of the file to be accelerated and an attribute proportion value corresponding to the data volume of the file to be accelerated in the acceleration attribute value algorithm;
and the attribute value operator module is used for taking the product of the attribute proportion value and the data volume of the file to be accelerated as the accelerated attribute value.
11. A computer-readable storage medium, on which a computer program is stored which, when being executed by a processor, carries out the steps of the download control method according to any one of claims 1 to 5.
CN201910157080.4A 2019-03-01 2019-03-01 Download control method, device and storage medium Active CN110012068B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910157080.4A CN110012068B (en) 2019-03-01 2019-03-01 Download control method, device and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910157080.4A CN110012068B (en) 2019-03-01 2019-03-01 Download control method, device and storage medium

Publications (2)

Publication Number Publication Date
CN110012068A CN110012068A (en) 2019-07-12
CN110012068B true CN110012068B (en) 2022-02-11

Family

ID=67166236

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910157080.4A Active CN110012068B (en) 2019-03-01 2019-03-01 Download control method, device and storage medium

Country Status (1)

Country Link
CN (1) CN110012068B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110690999B (en) * 2019-10-11 2021-06-11 腾讯科技(深圳)有限公司 Bandwidth allocation method, device and equipment based on block chain and storage medium
CN111010450B (en) * 2019-12-25 2022-01-28 安徽兆尹信息科技股份有限公司 Client-side chain data downloading method for FISCO BCOS platform
CN112203119B (en) * 2020-09-27 2024-03-08 腾讯科技(深圳)有限公司 Multimedia service acceleration method, device, equipment and storage medium
CN112488838A (en) * 2020-12-16 2021-03-12 浙江大学德清先进技术与产业研究院 Remote sensing data transaction incentive method based on intelligent contract

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102790925A (en) * 2011-05-20 2012-11-21 深圳市快播科技有限公司 Method and VOD (Video On Demand) terminal for playing online streaming media
CN102833293A (en) * 2011-06-17 2012-12-19 腾讯科技(深圳)有限公司 Method for downloading resources in peer to server and peer (P2SP) network, and client
CN103501342A (en) * 2013-10-09 2014-01-08 北京奇虎科技有限公司 Method and device of uploading and downloading data in point-to-point network
CN108259542A (en) * 2016-12-29 2018-07-06 腾讯科技(深圳)有限公司 The transmission method and device of resource

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050091167A1 (en) * 2003-10-25 2005-04-28 Macrovision Corporation Interdiction of unauthorized copying in a decentralized network
US9756115B2 (en) * 2012-11-08 2017-09-05 Gpvtl Canada Inc. System and method of secure file sharing using P2P
US20180284758A1 (en) * 2016-05-09 2018-10-04 StrongForce IoT Portfolio 2016, LLC Methods and systems for industrial internet of things data collection for equipment analysis in an upstream oil and gas environment
CN108737498A (en) * 2018-04-18 2018-11-02 中国地质大学(武汉) A kind of P2P safety download detection method and system based on block chain
CN108769145A (en) * 2018-05-11 2018-11-06 北京奇虎科技有限公司 A kind of resources contribution amount method of proof, apparatus and system
CN108848081A (en) * 2018-06-01 2018-11-20 深圳崀途科技有限公司 The data sharing method of verification and integral incentive mechanism is stored based on alliance's chain

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102790925A (en) * 2011-05-20 2012-11-21 深圳市快播科技有限公司 Method and VOD (Video On Demand) terminal for playing online streaming media
CN102833293A (en) * 2011-06-17 2012-12-19 腾讯科技(深圳)有限公司 Method for downloading resources in peer to server and peer (P2SP) network, and client
CN103501342A (en) * 2013-10-09 2014-01-08 北京奇虎科技有限公司 Method and device of uploading and downloading data in point-to-point network
CN108259542A (en) * 2016-12-29 2018-07-06 腾讯科技(深圳)有限公司 The transmission method and device of resource

Also Published As

Publication number Publication date
CN110012068A (en) 2019-07-12

Similar Documents

Publication Publication Date Title
CN110012068B (en) Download control method, device and storage medium
WO2018133306A1 (en) Dispatching method and device in content delivery network
US10783267B2 (en) Centralized throttling service
CN110830735B (en) Video generation method and device, computer equipment and storage medium
CN110554616B (en) Intelligent home data chaining method and system of Internet of things on block chain
CN111444018B (en) Request processing method and device
JP2008027442A (en) Sub-task processor distribution scheduling
WO2019041738A1 (en) Client resource obtaining method and apparatus, terminal device, and storage medium
CN111614736A (en) Network content resource scheduling method, domain name scheduling server and electronic equipment
CN110430274A (en) A kind of document down loading method and system based on cloud storage
CN110324680B (en) Video pushing method and device, server, client and storage medium
US9577950B2 (en) Method and system for reclaiming unused resources in a networked application environment
CN112436997B (en) Chat room message distribution method, message distribution system and electronic equipment
WO2017101354A1 (en) Message pushing system and method
WO2014146434A1 (en) Methods and systems for managing user privileges
CN110839069A (en) Node data deployment method, node data deployment system and medium
CN110620777A (en) Smoke monitoring data uplink method and system of Internet of things on block chain
CN110035128B (en) Live broadcast scheduling method and device, live broadcast system and storage medium
WO2020076393A1 (en) Stream allocation using stream credits
WO2017185632A1 (en) Data transmission method and electronic device
CN108769244B (en) Storage task information acquisition method and related device
CN113988559B (en) Disturbance-free method and device for questionnaire delivery
CN111625375B (en) Account reservation method and device, storage medium and electronic equipment
CN110428254B (en) Decentralized storage downloading method and arbitration method, equipment and storage medium
CN113157756A (en) Interactive data statistical method and device, electronic equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant