CN113064857A - File transmission control method, equipment and medium - Google Patents

File transmission control method, equipment and medium Download PDF

Info

Publication number
CN113064857A
CN113064857A CN202110285355.XA CN202110285355A CN113064857A CN 113064857 A CN113064857 A CN 113064857A CN 202110285355 A CN202110285355 A CN 202110285355A CN 113064857 A CN113064857 A CN 113064857A
Authority
CN
China
Prior art keywords
data
file
transmission
packet
data packet
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
CN202110285355.XA
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.)
Goertek Techology Co Ltd
Original Assignee
Goertek Techology 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 Goertek Techology Co Ltd filed Critical Goertek Techology Co Ltd
Priority to CN202110285355.XA priority Critical patent/CN113064857A/en
Publication of CN113064857A publication Critical patent/CN113064857A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/13File access structures, e.g. distributed indices
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/14Details of searching files based on file metadata
    • G06F16/148File search processing
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/17Details of further file system functions
    • G06F16/172Caching, prefetching or hoarding of files
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Databases & Information Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Library & Information Science (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

The application discloses a file transmission control method, electronic equipment and a computer readable storage medium, wherein the method comprises the following steps: sending a file acquisition request to a response end; negotiating data transmission parameters with a response end, wherein the data transmission parameters comprise packet transmission parameters aiming at the target file; the response end divides the target file into appointed data packets according to the sub-packet transmission parameters for transmission, and each data packet carries a corresponding data packet index parameter to identify the sequence number of the current data packet; the request end divides the target cache region allocated for the target file into a designated ordered space block; when receiving a data packet sent by a response end, caching the current data packet into a space block with a corresponding sequence number according to the data packet index parameter of the current data packet; and releasing the cache resources after the target file is transferred and the target file is landed. The method and the device can solve the problem of disordered data reception in application scenes such as multithreading file transmission and the like, improve the data transmission efficiency and reduce the system power consumption.

Description

File transmission control method, equipment and medium
Technical Field
The present application relates to the field of communications technologies, and in particular, to a file transfer control method, an electronic device, and a computer-readable storage medium.
Background
In an embedded system, compared with a single thread, the multi-thread data transmission has the advantages that the execution efficiency is improved in a crossing manner, and the multi-thread data transmission is very widely applied due to high efficiency; however, the multithreading is also insufficient for the single thread, mainly due to the time sequence of the fragment data, when the processing speed of a certain thread task is reduced, the time sequence of the multithreading transmission data is disordered, and further the received data analysis fails.
The existing method for solving the problems mainly comprises the steps of analyzing data after receiving a message and reordering the data according to a data index; when the data size is large, the method has the problems of reduced processing performance, low speed, high power consumption and the like caused by the sequencing processing of a large amount of data.
In view of the above, it is an important need for those skilled in the art to provide a solution to the above technical problems.
Disclosure of Invention
The present application is directed to a file transfer control method, an electronic device, and a computer-readable storage medium, so as to effectively improve file transfer efficiency and reduce system power consumption.
In order to solve the above technical problem, in one aspect, the present application discloses a file transmission control method, applied to a request end, including:
sending a file acquisition request to a response end;
negotiating data transmission parameters with the response end, wherein the data transmission parameters comprise packet transmission parameters aiming at a target file; the response end divides the target file into appointed data packets according to the sub-packet transmission parameters for transmission, and each data packet carries a corresponding data packet index parameter to identify the sequence number of the current data packet; the request end divides a target cache region allocated for the target file into a specified ordered space block;
when receiving the data packet sent by the response end, caching the current data packet into the space block with the corresponding sequence number according to the data packet index parameter;
and releasing the cache resources after the target file is transferred and the target file is landed.
Optionally, the data transmission parameters include a segment transmission parameter and a sub-packet transmission parameter for the target file; the response end divides the target file into appointed data segments according to the segmented transmission parameters for transmission in a plurality of times, and divides the current data segment into appointed data packets for transmission according to the sub-packet transmission parameters in each data segment transmission, and each data packet carries a corresponding data packet index parameter to identify the sequence number of the current data packet in the current data segment;
the total number of the space blocks is equal to the number of data packets included in a single data segment.
Optionally, the negotiating data transmission parameters with the response end includes:
after the response end finds the specified target file according to the file acquisition request, verifying the file attribute information of the target file sent by the response end;
if the verification is passed, a step of negotiating data transmission parameters with the response end is executed;
and if the verification fails, returning to execute the step of sending the file acquisition request to the response end.
Optionally, the file attribute information includes a file name and a file size.
Optionally, the segment transmission parameter includes a number of segments, a single segment data SIZE, and M/N NUM SIZE; wherein M is the SIZE of the file, N is the number of segments, NUM is the single segment data SIZE, and SIZE is the SIZE of the target cache region;
the sub-packet transmission parameters comprise the sub-packet number of a single data segment and the maximum data volume of a single packet, and NUM/OFFSET is MAX; wherein OFFSET is the number of sub-packets, and MAX is the maximum data volume of a single packet;
the value range of the data packet index parameter is as follows: INDEX ═ 1,2, …, OFFSET; wherein INDEX is a packet INDEX parameter.
Optionally, after the negotiation of the data transmission parameters is completed, the method further includes:
whether M/N is equal to NUM and NUM/OFFSET is equal to MAX or not is verified;
if so, continuing to transmit the file;
if not, returning to the step of executing the data transmission parameter negotiation with the response end.
Optionally, after each data segment transmission is completed, the method further includes:
judging whether the total number of data packets actually received in the data segment transmission process is OFFSET or not;
if so, judging that the current data segment is normally transmitted, and transmitting the next data segment;
if not, judging that the transmission of the current data segment is abnormal, and informing the response end of retransmitting.
The application also discloses another file transmission control method, which is applied to a response end and comprises the following steps:
searching a target file according to a file acquisition request sent by a request terminal;
negotiating data transmission parameters with the request end, wherein the data transmission parameters comprise packet transmission parameters aiming at a target file; dividing the target file into appointed data packets for transmission according to the sub-packet transmission parameters, wherein each data packet carries a corresponding data packet index parameter to identify the sequence number of the current data packet; the request end divides a target cache region allocated for the target file into a specified ordered space block;
sending a data packet to the request end according to the data transmission parameters; and the request end caches the received current data packet to the space block with the corresponding sequence number according to the data packet index parameter, and releases the cache resource after the target file is completely transferred and landed.
In another aspect, the present application also discloses an electronic device, including:
a memory for storing a computer program;
a processor for executing the computer program to implement the steps of any of the file transfer control methods described above.
In yet another aspect, the present application further discloses a computer-readable storage medium, in which a computer program is stored, which, when being executed by a processor, is adapted to implement the steps of any one of the file transfer control methods described above.
The file transmission control method provided by the application is applied to a request end and comprises the following steps: sending a file acquisition request to a response end; negotiating data transmission parameters with the response end, wherein the data transmission parameters comprise packet transmission parameters aiming at a target file; the response end divides the target file into appointed data packets according to the sub-packet transmission parameters for transmission, and each data packet carries a corresponding data packet index parameter to identify the sequence number of the current data packet; the request end divides a target cache region allocated for the target file into a specified ordered space block; when receiving the data packet sent by the response end, caching the current data packet into the space block with the corresponding sequence number according to the data packet index parameter; and releasing the cache resources after the target file is transferred and the target file is landed.
The file transmission control method, the electronic device and the computer-readable storage medium provided by the application have the beneficial effects that: according to the method and the device, one target file is divided into a plurality of data packets carrying index information to be transmitted according to a parameter negotiation result before formal transmission of data, the received data packets can be respectively cached in space blocks corresponding to sequence numbers in a number-to-number and seat-to-seat mode in sequence without data packet sequencing, the problem of data receiving confusion in application scenes such as multithreading file transmission and the like can be effectively solved, the data transmission efficiency is greatly improved, and the system power consumption and the calculated amount are reduced.
Drawings
In order to more clearly illustrate the technical solutions in the prior art and the embodiments of the present application, the drawings that are needed to be used in the description of the prior art and the embodiments of the present application will be briefly described below. Of course, the following description of the drawings related to the embodiments of the present application is only a part of the embodiments of the present application, and it will be obvious to those skilled in the art that other drawings can be obtained from the provided drawings without any creative effort, and the obtained other drawings also belong to the protection scope of the present application.
Fig. 1 is a flowchart of a file transfer control method disclosed in an embodiment of the present application;
fig. 2 is a flowchart of another file transfer control method disclosed in the embodiment of the present application;
fig. 3 is a block diagram of an electronic device according to an embodiment of the present disclosure.
Detailed Description
The core of the application is to provide a file transmission control method, an electronic device and a computer readable storage medium, so as to effectively improve the file transmission efficiency and reduce the system power consumption.
In order to more clearly and completely describe the technical solutions in the embodiments of the present application, the technical solutions in the embodiments of the present application will be described below with reference to the drawings in the embodiments of the present application. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
In an embedded system, compared with a single thread, the multi-thread data transmission has the advantages that the execution efficiency is improved in a crossing manner, and the multi-thread data transmission is very widely applied due to high efficiency; however, the multithreading is also insufficient for the single thread, mainly due to the time sequence of the fragment data, when the processing speed of a certain thread task is reduced, the time sequence of the multithreading transmission data is disordered, and further the received data analysis fails.
The existing method for solving the problems mainly comprises the steps of analyzing data after receiving a message and reordering the data according to a data index; when the data size is large, the method has the problems of reduced processing performance, low speed, high power consumption and the like caused by the sequencing processing of a large amount of data. In view of this, the present application provides a file transfer control scheme, which can effectively solve the above-mentioned problems.
Referring to fig. 1, an embodiment of the present application discloses a file transfer control method, which is applied to a request end and mainly includes:
s101: and sending a file acquisition request to a response end.
S102: negotiating data transmission parameters with a response end, wherein the data transmission parameters comprise packet transmission parameters aiming at the target file; the response end divides the target file into appointed data packets according to the sub-packet transmission parameters for transmission, and each data packet carries a corresponding data packet index parameter to identify the sequence number of the current data packet; and the requesting end divides the target buffer area allocated for the target file into a specified ordered space block.
S103: when receiving the data packet sent by the response end, caching the current data packet into the space block with the corresponding sequence number according to the data packet index parameter.
S104: and releasing the cache resources after the target file is transferred and the target file is landed.
Specifically, it should be emphasized that, in the file transmission method provided by the present application, before starting data transmission of a file, a request end and a response end perform parameter negotiation first, so as to packetize data and add an index, and then during data transmission, the two ends respectively send and receive each data packet according to a negotiated parameter result.
After the data packet indexes are added, each data packet can be immediately 'number-matched' after being received and is respectively stored in the corresponding cache subarea, and the data packets are not required to be stored according to the calculated sequence after being sorted by consuming more calculation resources. Therefore, the data transmission efficiency is greatly improved, and the system power consumption is reduced.
Specifically, the parameters that the request end and the response end need to negotiate include a packet transmission parameter and a data packet index parameter. The packetization transmission parameter is used to specify how a target file is to be transmitted in packets. Each data packet also carries a corresponding data packet index parameter when actually sent, so as to indicate the sequence number of the data packet. Therefore, after a receiving end receives a data packet, the receiving end can acquire the sequence information of the data packet according to the data packet index parameter, and does not need to wait until other data packets are received and then cached, or even wait until the sequencing calculation of all the data packets is completed.
It is easy to understand that, in the actual transmission process, the transmission completion time of different packets of the same file is likely to be different because the specific situation of different packets is different. If it is necessary to wait for all data packets to finish transmission and perform data sorting and then buffer the data, the data transmission efficiency is greatly reduced, and computing resources are wasted. Moreover, in practice, a complex scenario is encountered in which multiple files are transmitted by using a single or multiple threads. Therefore, based on the indexing mechanism in the application, the receiving end can greatly facilitate the data receiving and caching in a rapid, efficient and orderly manner.
Certainly, in order to further guarantee the data transmission efficiency, uniform division can be preferentially adopted when data is divided into packets, namely, the target file is divided into a plurality of data packets with equal size. Of course, the last packet size at the end of the file may be smaller than the other packets. In this way, by ensuring the data packets to be as large as possible, the transmission time of the data packets can be the same as possible.
For an object file to be transmitted, the receiving end also applies a target cache region with a corresponding size for the object file in advance to store the object file to be transmitted. And further, the receiving end divides the target buffer area into a plurality of ordered space blocks, and each space block is used for storing one data packet. Therefore, in the data transmission parameter negotiation stage, the packet transmission parameters negotiated by the request end and the response end determine the size of each packet of data, and also determine the size of each space block.
After the receiving end caches each received data packet in the corresponding space block, the data dropping operation can be performed, the data in the target cache region is stored in the hard disk, and the resource occupation of the target cache region is released, so that the returned storage resources can be continuously used for caching the data transmitted next time.
Therefore, according to the file transmission control method provided by the application, one target file is divided into a plurality of data packets carrying index information to be transmitted according to the parameter negotiation result before the formal transmission of data, the received data packets can be respectively cached in the space blocks corresponding to the sequence numbers in a number-to-number and seat-to-seat mode in sequence without data packet sequencing, the problem of data receiving confusion in application scenes such as multithreading file transmission and the like can be effectively solved, the data transmission efficiency is greatly improved, and the system power consumption and the calculated amount are reduced.
As a specific embodiment, in the file transfer control method provided in the embodiment of the present application, on the basis of the foregoing content, the data transfer parameter includes a segment transfer parameter and a packetization transfer parameter for the target file; the response end divides the target file into appointed data segments according to the segmented transmission parameters for transmission in a plurality of times, and in each data segment transmission, divides the current data segment into appointed data packets according to the sub-packet transmission parameters for transmission, and each data packet carries a corresponding data packet index parameter so as to mark the serial number of the current data packet in the current data segment;
the total number of spatial blocks is equal to the number of packets comprised by a single data segment.
Specifically, according to the size of the target file, the target file can be selectively segmented and then transmitted in a sub-packet mode. Based on the segmented transmission parameters, a target file can be divided into a plurality of data segments with equal size (the last data segment can be exceptional), and the data segments are transmitted for a plurality of times respectively. And in each data segment transmission process, dividing one data segment into a plurality of data packets for transmission based on the sub-packet transmission parameters.
In this case, to save resource occupation, the receiving end may only perform buffer allocation according to the number of the space blocks needed to be used in the first data segment transmission, and several subsequent data segment transmissions may continue to use the space blocks allocated for the first data segment transmission. That is, the total number of the space blocks is equal to the number of the data packets included in a single data segment, and the data packet index carried by each data packet of each data segment refers to the total sequence number of the current data packet in the current data segment.
As a specific embodiment, the file transmission control method provided in the embodiment of the present application negotiates data transmission parameters with a response end on the basis of the foregoing contents, and includes:
after the response end finds the specified target file according to the file acquisition request, verifying the file attribute information of the target file sent by the response end;
if the verification is passed, a step of negotiating data transmission parameters with the response end is executed;
and if the verification fails, returning to execute the step of sending the file acquisition request to the response end.
As a specific embodiment, in the file transfer control method provided in the embodiment of the present application, based on the above contents, the file attribute information includes a file name and a file size. By checking the attribute information such as the file name, the file size and the like, whether the file to be transmitted by the response end is really the file required by the receiving end can be further confirmed.
As a specific embodiment, in the file transfer control method provided in the embodiment of the present application, on the basis of the foregoing, the segment transfer parameters include the number of segments and the single segment data SIZE, and M/N is NUM is SIZE; wherein M is the SIZE of the file, N is the number of segments, NUM is the single segment data SIZE, and SIZE is the SIZE of the target cache region;
the sub-packet transmission parameters comprise the sub-packet number of a single data segment and the maximum data volume of a single packet, and NUM/OFFSET is MAX; wherein OFFSET is the number of sub-packets, and MAX is the maximum data volume of a single packet;
the value range of the data packet index parameter is as follows: INDEX ═ 1,2, …, OFFSET; wherein INDEX is a packet INDEX parameter.
Specifically, the response end allocates a target cache area SIZE with a corresponding SIZE to the target file according to the SIZE M of the target file. Since each space block used in the first data segment transmission may be repeatedly used, the SIZE of the target cache region may be specifically equal to the SIZE of a single data segment, i.e., SIZE NUM M/N.
And then, according to the maximum data amount of the single packet, the number of the packets of each segment of data can be determined, namely, the OFFSET is NUM/MAX. Thus, the receiving segment may apply for OFFSET spatial blocks of size MAX in the buffer, which constitute the target buffer corresponding to the target file.
As a specific embodiment, the file transmission control method provided in the embodiment of the present application further includes, after the data transmission parameter negotiation is completed, on the basis of the foregoing contents:
whether M/N is equal to NUM and NUM/OFFSET is equal to MAX or not is verified;
if so, continuing to transmit the file;
if not, returning to the step of executing the negotiation of the data transmission parameters with the response end.
Specifically, in order to further determine the reasonableness of the negotiated transmission parameters, the receiving end may perform a check after the negotiation is completed, and the content of the check may specifically include whether the above two equations are satisfied or not.
As a specific embodiment, the file transfer control method provided in the embodiment of the present application, on the basis of the foregoing content, after the data segment transfer is completed each time, further includes:
judging whether the total number of data packets actually received in the data segment transmission process is OFFSET or not;
if so, judging that the current data segment is normally transmitted, and transmitting the next data segment;
if not, judging that the transmission of the current data segment is abnormal, and informing the response end of retransmitting.
Specifically, during each data segment transmission, the receiving end counts the data packets actually received at present in real time to check whether the data packets reach the total number of the data packets of the preset single-segment data, so as to ensure the integrity of the data transmission.
Referring to fig. 2, an embodiment of the present application further discloses another file transfer control method, which is applied to a response end and mainly includes:
s201: and searching a target file according to a file acquisition request sent by a request terminal.
S202: negotiating data transmission parameters with a request end, wherein the data transmission parameters comprise packet transmission parameters aiming at a target file; so as to divide the target file into appointed data packets for transmission according to the sub-packet transmission parameters, and each data packet carries a corresponding data packet index parameter to identify the sequence number of the current data packet; and the requesting end divides the target buffer area allocated for the target file into a specified ordered space block.
S203: sending a data packet to a request end according to the data transmission parameters; and the request end caches the received current data packet to the space block with the corresponding sequence number according to the data packet index parameter, and releases the cache resource after the target file is completely transferred and landed.
Therefore, according to the file transmission control method provided by the application, one target file is divided into a plurality of data packets carrying index information to be transmitted according to the parameter negotiation result before the formal transmission of data, the received data packets can be respectively cached in the space blocks corresponding to the sequence numbers in a number-to-number and seat-to-seat mode in sequence without data packet sequencing, the problem of data receiving confusion in application scenes such as multithreading file transmission and the like can be effectively solved, the data transmission efficiency is greatly improved, and the system power consumption and the calculated amount are reduced.
Referring to fig. 3, an embodiment of the present application discloses an electronic device, including:
a memory 301 for storing a computer program;
a processor 302 for executing said computer program to implement the steps of any of the file transfer control methods described above.
Further, the present application also discloses a computer-readable storage medium, in which a computer program is stored, and the computer program is used for implementing the steps of any one of the file transmission control methods described above when being executed by a processor.
For the details of the electronic device and the computer-readable storage medium, reference may be made to the foregoing detailed description of the file transfer control method, and details will not be repeated here.
The embodiments 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. For the equipment disclosed by the embodiment, the description is relatively simple because the equipment corresponds to the method disclosed by the embodiment, and the relevant parts can be referred to the method part for description.
It is further noted that, throughout this document, relational terms such as "first" and "second" are used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Furthermore, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.
The technical solutions provided by the present application are described in detail above. The principles and embodiments of the present application are explained herein using specific examples, which are provided only to help understand the method and the core idea of the present application. It should be noted that, for those skilled in the art, without departing from the principle of the present application, several improvements and modifications can be made to the present application, and these improvements and modifications also fall into the protection scope of the present application.

Claims (10)

1. A file transmission control method is applied to a request end and comprises the following steps:
sending a file acquisition request to a response end;
negotiating data transmission parameters with the response end, wherein the data transmission parameters comprise packet transmission parameters aiming at a target file; the response end divides the target file into appointed data packets according to the sub-packet transmission parameters for transmission, and each data packet carries a corresponding data packet index parameter to identify the sequence number of the current data packet; the request end divides a target cache region allocated for the target file into a specified ordered space block;
when receiving the data packet sent by the response end, caching the current data packet into the space block with the corresponding sequence number according to the data packet index parameter;
and releasing the cache resources after the target file is transferred and the target file is landed.
2. The file transfer control method according to claim 1, wherein the data transfer parameters include a fragmentation transfer parameter, a packetization transfer parameter for the target file; the response end divides the target file into appointed data segments according to the segmented transmission parameters for transmission in a plurality of times, and divides the current data segment into appointed data packets for transmission according to the sub-packet transmission parameters in each data segment transmission, and each data packet carries a corresponding data packet index parameter to identify the sequence number of the current data packet in the current data segment;
the total number of the space blocks is equal to the number of data packets included in a single data segment.
3. The method according to claim 2, wherein negotiating data transmission parameters with the responder comprises:
after the response end finds the specified target file according to the file acquisition request, verifying the file attribute information of the target file sent by the response end;
if the verification is passed, a step of negotiating data transmission parameters with the response end is executed;
and if the verification fails, returning to execute the step of sending the file acquisition request to the response end.
4. The file transfer control method according to claim 3, wherein the file attribute information includes a file name, a file size.
5. The file transfer control method according to claim 4,
the segmented transmission parameters comprise the number of segments and single segment data volume, and M/N is NUM is SIZE; wherein M is the SIZE of the file, N is the number of segments, NUM is the single segment data SIZE, and SIZE is the SIZE of the target cache region;
the sub-packet transmission parameters comprise the sub-packet number of a single data segment and the maximum data volume of a single packet, and NUM/OFFSET is MAX; wherein OFFSET is the number of sub-packets, and MAX is the maximum data volume of a single packet;
the value range of the data packet index parameter is as follows: INDEX ═ 1,2, …, OFFSET; wherein INDEX is a packet INDEX parameter.
6. The file transmission control method according to claim 5, further comprising, after the data transmission parameter negotiation is completed:
whether M/N is equal to NUM and NUM/OFFSET is equal to MAX or not is verified;
if so, continuing to transmit the file;
if not, returning to the step of executing the data transmission parameter negotiation with the response end.
7. The file transfer control method according to claim 5, further comprising, after each data segment transfer is completed:
judging whether the total number of data packets actually received in the data segment transmission process is OFFSET or not;
if so, judging that the current data segment is normally transmitted, and transmitting the next data segment;
if not, judging that the transmission of the current data segment is abnormal, and informing the response end of retransmitting.
8. A file transmission control method is applied to a response end and comprises the following steps:
searching a target file according to a file acquisition request sent by a request terminal;
negotiating data transmission parameters with the request end, wherein the data transmission parameters comprise packet transmission parameters aiming at a target file; dividing the target file into appointed data packets for transmission according to the sub-packet transmission parameters, wherein each data packet carries a corresponding data packet index parameter to identify the sequence number of the current data packet; the request end divides a target cache region allocated for the target file into a specified ordered space block;
sending a data packet to the request end according to the data transmission parameters; and the request end caches the received current data packet to the space block with the corresponding sequence number according to the data packet index parameter, and releases the cache resource after the target file is completely transferred and landed.
9. An electronic device, comprising:
a memory for storing a computer program;
a processor for executing the computer program to implement the steps of the file transfer control method according to any one of claims 1 to 7 or to implement the steps of the file transfer control method according to claim 8.
10. A computer-readable storage medium, in which a computer program is stored which, when being executed by a processor, is adapted to carry out the steps of the file transfer control method according to any one of claims 1 to 7, or the steps of the file transfer control method according to claim 8.
CN202110285355.XA 2021-03-17 2021-03-17 File transmission control method, equipment and medium Pending CN113064857A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110285355.XA CN113064857A (en) 2021-03-17 2021-03-17 File transmission control method, equipment and medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110285355.XA CN113064857A (en) 2021-03-17 2021-03-17 File transmission control method, equipment and medium

Publications (1)

Publication Number Publication Date
CN113064857A true CN113064857A (en) 2021-07-02

Family

ID=76561180

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110285355.XA Pending CN113064857A (en) 2021-03-17 2021-03-17 File transmission control method, equipment and medium

Country Status (1)

Country Link
CN (1) CN113064857A (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113835902A (en) * 2021-09-22 2021-12-24 北京字节跳动网络技术有限公司 Data processing method and device, computer equipment and storage medium
CN114490459A (en) * 2022-01-27 2022-05-13 重庆物奇微电子有限公司 Data transmission method, device, equipment, receiver and storage medium
CN114697279A (en) * 2022-03-23 2022-07-01 北京航天拓扑高科技有限责任公司 Method for transmitting data files by multi-channel sub-packets
CN115766706A (en) * 2022-11-09 2023-03-07 太平洋电信股份有限公司 Network data transmission method and system

Citations (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101834801A (en) * 2010-05-20 2010-09-15 哈尔滨工业大学 Data caching and sequencing on-line processing method based on cache pool
CN104202667A (en) * 2014-09-19 2014-12-10 青岛海信宽带多媒体技术有限公司 IPTV (internet protocol television) set-top box upgrading method and system
CN105187564A (en) * 2015-10-14 2015-12-23 中科宇图天下科技有限公司 Method for breakpoint resuming of mobile phone side file
CN105491132A (en) * 2015-12-11 2016-04-13 北京元心科技有限公司 File server, terminal and file subpackage transmission method
CN108881485A (en) * 2018-07-30 2018-11-23 中国石油化工股份有限公司 The method for ensureing the high concurrent system response time under big data packet
CN109286477A (en) * 2018-10-30 2019-01-29 佛山市瑞德物联科技有限公司 A kind of data transmission method for supporting out-of-order transfer
US20190320008A1 (en) * 2018-04-16 2019-10-17 Qbic Technology Co., Ltd. Data transfer system and method thereof
CN110493302A (en) * 2019-07-01 2019-11-22 联想(北京)有限公司 A kind of document transmission method, equipment and computer readable storage medium
CN110708363A (en) * 2019-09-20 2020-01-17 济南浪潮数据技术有限公司 File transmission method, system, electronic equipment and storage medium
CN111125427A (en) * 2019-12-26 2020-05-08 浪潮电子信息产业股份有限公司 Video file reading method and device, electronic equipment and medium
CN112398916A (en) * 2020-10-29 2021-02-23 北京华云安信息技术有限公司 File transmission method and device based on HTTP (hyper text transport protocol)

Patent Citations (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101834801A (en) * 2010-05-20 2010-09-15 哈尔滨工业大学 Data caching and sequencing on-line processing method based on cache pool
CN104202667A (en) * 2014-09-19 2014-12-10 青岛海信宽带多媒体技术有限公司 IPTV (internet protocol television) set-top box upgrading method and system
CN105187564A (en) * 2015-10-14 2015-12-23 中科宇图天下科技有限公司 Method for breakpoint resuming of mobile phone side file
CN105491132A (en) * 2015-12-11 2016-04-13 北京元心科技有限公司 File server, terminal and file subpackage transmission method
US20190320008A1 (en) * 2018-04-16 2019-10-17 Qbic Technology Co., Ltd. Data transfer system and method thereof
CN108881485A (en) * 2018-07-30 2018-11-23 中国石油化工股份有限公司 The method for ensureing the high concurrent system response time under big data packet
CN109286477A (en) * 2018-10-30 2019-01-29 佛山市瑞德物联科技有限公司 A kind of data transmission method for supporting out-of-order transfer
CN110493302A (en) * 2019-07-01 2019-11-22 联想(北京)有限公司 A kind of document transmission method, equipment and computer readable storage medium
CN110708363A (en) * 2019-09-20 2020-01-17 济南浪潮数据技术有限公司 File transmission method, system, electronic equipment and storage medium
CN111125427A (en) * 2019-12-26 2020-05-08 浪潮电子信息产业股份有限公司 Video file reading method and device, electronic equipment and medium
CN112398916A (en) * 2020-10-29 2021-02-23 北京华云安信息技术有限公司 File transmission method and device based on HTTP (hyper text transport protocol)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113835902A (en) * 2021-09-22 2021-12-24 北京字节跳动网络技术有限公司 Data processing method and device, computer equipment and storage medium
CN113835902B (en) * 2021-09-22 2023-12-05 抖音视界有限公司 Data processing method, device, computer equipment and storage medium
CN114490459A (en) * 2022-01-27 2022-05-13 重庆物奇微电子有限公司 Data transmission method, device, equipment, receiver and storage medium
CN114697279A (en) * 2022-03-23 2022-07-01 北京航天拓扑高科技有限责任公司 Method for transmitting data files by multi-channel sub-packets
CN115766706A (en) * 2022-11-09 2023-03-07 太平洋电信股份有限公司 Network data transmission method and system

Similar Documents

Publication Publication Date Title
CN113064857A (en) File transmission control method, equipment and medium
CN111147564B (en) Data file transmission method, system and communication terminal
US9218203B2 (en) Packet scheduling in a multiprocessor system using inter-core switchover policy
US8868855B2 (en) Request management system and method for dynamically managing prioritized requests
CN111427517A (en) Data processing method and NVMe memory
CN108153589B (en) Method and system for data processing in a multi-threaded processing arrangement
CN110708377A (en) Data transmission method, device and storage medium
CN104270362A (en) Request handling method and device
US8503472B2 (en) Partial bandwidth request techniques in wireless networks
CN109688606B (en) Data processing method and device, computer equipment and storage medium
CN112243266B (en) Data packet method and device
CN110445580B (en) Data transmission method and device, storage medium, and electronic device
CN115361349B (en) Resource using method and device
CN107391388B (en) Method and equipment for storing data based on instant messaging
CN116820769A (en) Task allocation method, device and system
US20160085683A1 (en) Data receiving device and data receiving method
CN108228323B (en) Hadoop task scheduling method and device based on data locality
CN105471930A (en) Method, system and equipment for reading distributed data
EP3992770A1 (en) Message processing method and apparatus, and computer storage medium
CN113630808A (en) Data transmission method, first device and second device
CN116737088B (en) Object migration method and device, electronic equipment and storage medium
CN114490039A (en) Network card flow secondary allocation method, system, equipment and medium for CPU load balance
CN108549684B (en) Caching method adopting multi-path search reduction rule dependence in SDN
CN106535340B (en) A kind of method, apparatus and system of the priority promoting stream medium data
CN112948298A (en) Message processing method and device

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