CN105701109B - The method and device that file multichannel is sent - Google Patents

The method and device that file multichannel is sent Download PDF

Info

Publication number
CN105701109B
CN105701109B CN201410705373.9A CN201410705373A CN105701109B CN 105701109 B CN105701109 B CN 105701109B CN 201410705373 A CN201410705373 A CN 201410705373A CN 105701109 B CN105701109 B CN 105701109B
Authority
CN
China
Prior art keywords
file
destination node
destination
transmission
subdirectory
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
CN201410705373.9A
Other languages
Chinese (zh)
Other versions
CN105701109A (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.)
Shenzhen Tencent Computer Systems Co Ltd
Original Assignee
Shenzhen Tencent Computer Systems 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 Shenzhen Tencent Computer Systems Co Ltd filed Critical Shenzhen Tencent Computer Systems Co Ltd
Priority to CN201410705373.9A priority Critical patent/CN105701109B/en
Publication of CN105701109A publication Critical patent/CN105701109A/en
Application granted granted Critical
Publication of CN105701109B publication Critical patent/CN105701109B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Information Transfer Between Computers (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Computer And Data Communications (AREA)

Abstract

The invention discloses the method and devices that a kind of file multichannel is sent, and belong to network technique field.Method comprises determining that file destination information and multiple destination nodes to be sent;At least one identification information is created for each destination node, which sends different phase for identifying file;When getting file destination from file directory, the identification information based on file destination, each destination node and each destination node carries out file in parallel transmission;Wherein, in the transmission phase to each destination node, according to the different phase that file is sent, the identification information of each destination node is modified.The present invention when so that file destination sending failure to some destination node, has no effect on the file destination and is sent to other purposes node, improve transmitting efficiency by carrying out file in parallel transmission;And when file destination is sent to the failure of some destination node, need to only transmission be re-started to the destination node for sending failure, save time and resource.

Description

The method and device that file multichannel is sent
Technical field
The present invention relates to network technique field, in particular to a kind of method and device of file multichannel transmission.
Background technique
In network technique field, it is often necessary to same file are sent to multiple destinations, i.e. progress file multichannel forwarding. The prior art is that a file is sequentially transmitted to multiple destinations, for example, there are three mesh when carrying out the transmission of file multichannel Ground A, B and C when, after file first must being successfully sent to A and B, can just be sent to C.
In the implementation of the present invention, inventor find the relevant technologies the prior art has at least the following problems:
For the prior art when realizing the method that file multichannel is sent, same file, which needs to wait, is successfully sent to front Destination just can be carried out subsequent file and send, and transmitting efficiency is lower;And fail when some file is sent to some destination, As process is restarted or when machine is restarted, also needs for this document to be sent to all destinations in order again, in realization excessively It is cumbersome, cause the waste of time and resource.
Summary of the invention
In order to solve the problems, such as the relevant technologies, the method and dress that are sent the embodiment of the invention provides a kind of file multichannel It sets.The technical solution is as follows:
In a first aspect, providing a kind of method that file multichannel is sent, which comprises
Determine file destination information and multiple destination nodes to be sent;
At least one identification information is created for each destination node, at least one described identification information is for identifying file hair Send different phase;
When getting the file destination from file directory, it is based on the file destination, each destination node And the identification information of each destination node, carry out file in parallel transmission;
Wherein, in the transmission phase to each destination node, according to the different phase that file is sent, to each mesh The identification information of node be modified.
Second aspect, provides a kind of device that file multichannel is sent, and described device includes:
Determining module, for determining file destination information and multiple destination nodes to be sent;
Creation module, for creating at least one identification information, at least one described identification information for each destination node Different phase is sent for identifying file;
First sending module, for when getting the file destination from file directory, based on the file destination, The identification information of each destination node and each destination node carries out file in parallel transmission;
Identification information change module, in the transmission phase to each destination node, according to file send different phase, The identification information of each destination node is modified.
Technical solution provided in an embodiment of the present invention has the benefit that
By carrying out file in parallel transmission, when so that file destination being sent to multiple destination nodes, the hair of different destination nodes It send that the stage is mutually indepedent, is independent of each other, therefore, when file destination sends failure to some destination node, has no effect on the target File is sent to other purposes node, improves transmitting efficiency;And when file destination is sent to the failure of some destination node, only need File is re-started to the destination node for sending failure to send, and saves time and resource.
Detailed description of the invention
To describe the technical solutions in the embodiments of the present invention more clearly, make required in being described below to embodiment Attached drawing is briefly described, it should be apparent that, drawings in the following description are only some embodiments of the invention, for For those of ordinary skill in the art, without creative efforts, it can also be obtained according to these attached drawings other Attached drawing.
Fig. 1 is a kind of implementation environment schematic diagram for file multichannel sending method that one embodiment of the invention provides;
Fig. 2 be another embodiment of the present invention provides a kind of file multichannel sending method flow chart;
Fig. 3 be another embodiment of the present invention provides a kind of file multichannel sending method schematic diagram;
Fig. 4 be another embodiment of the present invention provides a kind of file multichannel sending method flow chart;
Fig. 5 be another embodiment of the present invention provides a kind of file multichannel sending device structural schematic diagram;
Fig. 6 be another embodiment of the present invention provides it is a kind of for file multichannel send server.
Specific embodiment
To make the object, technical solutions and advantages of the present invention clearer, below in conjunction with attached drawing to embodiment party of the present invention Formula is described in further detail.
Fig. 1 is a kind of implementation environment schematic diagram for file multichannel sending method that one embodiment of the invention provides, referring to figure 1, which can be a file system, as (Hadoop Distributed File System, Hadoop are distributed by HDFS File system) etc..The system may include multiple nodes, and node can be server or client, and each node is executable not Congenerous, such as file reception, file store, file is sent and data processing, can send and receive text mutually between node Part.For file system shown in Fig. 1 of the embodiment of the present invention, the mistake that one of node sends file to other nodes is introduced Journey;It wherein, include file directory on node, node receives file outside other nodes or file system, and is stored in file In catalogue;It include the received All Files of node and the file information in this document catalogue.
Certainly, above system is only that a typical case scene of the embodiment of the present invention can also be answered in actual implementation In the system for needing to carry out file transmission or data transmission for other.
Fig. 2 is a kind of flow chart of file multichannel sending method provided in an embodiment of the present invention.Text provided in this embodiment The executing subject of part multichannel sending method is node, and referring to fig. 2, this method process includes:
201, file destination information and multiple destination nodes to be sent are determined.
It in embodiments of the present invention, include the received All Files of node and the file information, tool in the file directory of node Body, the file information includes file name, file size etc..
In addition, destination node be file to be sent to server or client, each file can have multiple destination nodes. Specifically, it can be in file system, when needing to carry out file synchronization between node and destination node, according to synchronisation requirement Determine destination node to be synchronized;It is when either proposing that file sends request by other nodes, the node filed a request is true It is set to destination node;Either when node is needed to other node pushing files, for the purpose of the node for needing to push is determined Node;Either after receiving file, if in the file information including file to be sent to node, can be according to the file information Determine destination node;Certainly, other methods for determining destination node be there may also be in practical applications, the embodiment of the present invention is to this It is not especially limited.
In embodiments of the present invention, file destination, i.e. node need to send the file toward other nodes, specifically, node File destination can be determined according to the receiving time of file, such as determine that the earliest file of receiving time is file destination;It can also To determine file destination according to transmission demand, or file destination is determined at random, so that it is determined that file destination information, the present invention is implemented Example is not especially limited this.
202, at least one identification information is created for each destination node, at least one identification information is for identifying file Send different phase.
In embodiments of the present invention, it includes preparation stage, practical transmission phase and transmission knot that file, which sends different phase, Fruit feedback stage.Wherein, the preparation stage is the preparation stage of file, i.e., node obtains target text from file directory (active) Part is stored in intermediate transmission catalogue (receive), to realize the transmission to multiple destination nodes for the file destination; Practical transmission phase sends from centre and reads file destination in catalogue (receive), sends it to corresponding purpose section Point;Result feedback stage is sent, i.e., after node sends the file to destination node, receives the transmission success fed back by destination node Message sends failed message, and carries out subsequent file deletion or repeating transmission according to result is sent.
In embodiments of the present invention, in order to make file destination in transmission process, for being transmitted across for different destination nodes Journey is mutually indepedent, therefore, creates at least one identification information for each destination node.It specifically, is purpose node creation mark Information first creates destination node catalogue, to create multiple subdirectories, multiple subdirectory under each destination node catalogue For identifying the different phase of file transmission.Specifically, multiple subdirectories include sending to judge subdirectory (tag), for identifying Preparation stage;It sends and prepares subdirectory (ready) and send triggering subdirectory (sending), for identifying practical transmission phase; Transmission state subdirectory (failed) sends result feedback stage for identifying.
203, when getting file destination from file directory, based on file destination, each destination node and each The identification information of destination node carries out file in parallel transmission.
In embodiments of the present invention, it is mutual that file in parallel transmission, which refers to the process of that file is sent to each destination node, It is independent, be independent of each other, in the specific implementation, process that each destination node can be sent to for file be respectively created send into Journey handles own files transmission process by the respective transmission process of each destination node.
204, in the transmission phase to each destination node, according to the different phase that file is sent, to each purpose section The identification information of point is modified.
Specifically, in the transmission phase to each destination node, it is required to the different phase sent respectively according to file, The identification information of each destination node is modified.Specifically, which can be creates under different subdirectories Empty file, mobile empty file or deletion empty file etc., the present invention is not especially limit this.
Method provided in an embodiment of the present invention, by carrying out file in parallel transmission, so that file destination is sent to multiple purposes When node, the transmission phase of different destination nodes is mutually indepedent, is independent of each other, and therefore, file destination is sent out to some destination node When sending unsuccessfully, has no effect on the file destination and be sent to other purposes node, improve transmitting efficiency;And when file destination is sent to When some destination node fails, need to only file be re-started to the destination node for sending failure and sent, save time and resource.
Optionally, at least one identification information is created for each destination node, comprising:
Destination node catalogue is created for each destination node;
In each destination node catalogue creation send judge subdirectory, send prepare subdirectory, send trigger subdirectory, Transmission state subdirectory;
Judge to create empty file in subdirectory sending, the file name of the empty file is identical as file destination.
Optionally, the transmission phase of each destination node includes that preparation stage, practical transmission phase and transmission result are anti- The feedback stage;
Correspondingly, in the transmission phase to each destination node, according to the different phase that file is sent, to each purpose The identification information of node is modified, comprising:
In the preparation stage of destination node, when getting file destination from file directory, prepare specific item sending Record creation empty file;
In the practical transmission phase of destination node, when sending in preparation subdirectory includes empty file, empty file is moved Subdirectory is triggered to sending;
In the transmission result feedback stage of destination node, if file destination sends failure, empty file is moved into transmission State subdirectory;
In the transmission result feedback stage of destination node, if file destination is sent successfully, transmission is judged into subdirectory In empty file and send triggering subdirectory in empty file delete.
Optionally, method further include:
Each destination node has a transmission process, when destination node is arrived in the transmission process scanning of any destination node When sending in preparation subdirectory with empty file, file destination is sent to destination node.
Optionally, method further include:
In any one destination node catalogue, when the empty file storage in the transmission state subdirectory of destination node catalogue When length is more than preset duration, the empty file in the transmission state subdirectory of destination node catalogue is moved to the hair of destination node catalogue It send and prepares in subdirectory.
All the above alternatives can form alternative embodiment of the invention, herein no longer according to any combination It repeats one by one.
Fig. 3 is a kind of file multichannel sending method schematic diagram provided in an embodiment of the present invention, in conjunction with Fig. 3, referring to fig. 4, Fig. 4 It is a kind of flow chart of file multichannel sending method provided in an embodiment of the present invention.File multichannel sender provided in this embodiment The executing subject of method is node, and this method process includes:
401, file destination information and multiple destination nodes to be sent are determined.
Similarly, this will not be repeated here for the step 401 and step 201.
Specifically, referring to Fig. 3, the process of the determination file destination information to be sent and multiple destination nodes is as schemed In " file reception " process, the process can be by node by data receiver process (logproxy_recv) from other section Point receives file, and the file received is stored in file directory (active);When node has file to send task, according to hair Task is sent to determine file destination information and multiple destination nodes to be sent.
402, destination node catalogue is created for each destination node.
In embodiments of the present invention, since file destination has multiple destination nodes, it need to be created for each destination node Destination node catalogue is built, to be directed to different destination nodes, subdirectory is created in destination node catalogue, for identifying file The different phase of transmission, to realize that the unique file between different destination nodes is sent.Wherein, the embodiment of the present invention is to purpose section The title of point catalogue is not construed as limiting, such as " destination node catalogue 1 " " destination node the catalogue 2 " --- " destination node created in Fig. 3 Catalogue N ".The embodiment of the present invention is only illustrated so that file destination is sent to the process of " destination node catalogue 1 " as an example, target text The process that part is sent to other purposes nodal directory is similarly, not repeat herein.
403, creation transmission judges that subdirectory, transmission preparation subdirectory, transmission triggering are sub in each destination node catalogue Catalogue sends state subdirectory.
Judge subdirectory (tag) as shown in figure 3, creating transmission in each destination node catalogue, send preparation specific item (ready) is recorded, triggering subdirectory (sending) is sent, sends state subdirectory (failed).Specifically, it sends and judges specific item It records (tag), for identifying whether corresponding destination node needs to send file;It sends and prepares subdirectory (ready), for identifying Corresponding destination node needs whether the file sent has been moved into intermediate transmission catalogue;Triggering subdirectory (sending) is sent, For triggering the file transmission process of corresponding destination node;Transmission state subdirectory (failed), for identifying corresponding purpose section The file of point sends result.
After creating above-mentioned multiple subdirectories in each destination node catalogue, in the file transmission process of each destination node In, the different phase that current file is sent can be judged according to above-mentioned multiple subdirectories, to complete the transmission of file.
It should be noted that the process of above-mentioned steps 402 and step 403 can carry out simultaneously, the embodiment of the present invention is to this It is not especially limited.
404, judge to create empty file in subdirectory in transmission, the file name of the empty file is identical as file destination.
Specifically, such as the process of (1) in Fig. 3, the process for judging the inner creation empty file of subdirectory (tag) should be being sent, it can To obtain the file name in file destination information by file forwarding distribution process (logproxy_dispatch), in each mesh The transmission of nodal directory judge identical with the file destination title empty file of the inner creation of subdirectory (tag).
When the transmission of some destination node catalogue judges that subdirectory (tag) is inner, including file name is identical as file destination Empty file when, can determine whether that file destination needs to be sent to corresponding destination node.File forwards distribution process (logproxy_ Dispatch) the transmission under each destination node catalogue of file destination judges that subdirectory (tag) is inner and all creates above-mentioned empty file Afterwards, also file destination will be moved into intermediate transmission catalogue (receive) from file directory (active), to start to execute each The transmission process of a destination node.
405, in the preparation stage of destination node, when getting file destination from file directory, prepare sending Subdirectory creates empty file.
Specifically, such as the process of (2) in Fig. 3, the process of file destination should be obtained from file directory (active), i.e., it is literary Part forwards distribution process (logproxy_dispatch) to obtain file destination from file directory (active), by file destination Move to the intermediate process for sending catalogue (receive).
Such as the process of (3) in Fig. 3, when node by file forwarding distribution process (logproxy_dispatch) from file After getting file destination in catalogue (active), in each destination node catalogue, prepare subdirectory (ready) wound sending Empty file identical with file destination title is built, is ready for identifying file destination.
406, in the practical transmission phase of destination node, when sending in preparation subdirectory includes empty file, by ineffective law, rule, etc. Part moves to transmission triggering subdirectory.
In embodiments of the present invention, each destination node has a transmission process (logproxy_send), when any mesh Node transmission process (logproxy_send) scanning to destination node transmission prepare subdirectory (ready) in have sky It when file, can determine whether that the corresponding file destination of destination node is ready for, be ready for sending file.At this point, the process of transmission (logproxy_send) empty file can be moved to transmission triggering subdirectory (sending), to trigger reading and send target text The process of part.Since each destination node all has respective transmission process in sending side, it is mutually only that each road sends processing It is vertical, it is independent of each other, and do not limit each road and send implementation, easily extends.Realizing per transmission all the way can be different, for example is hair It send to distributed file system or single machine, can be freely determined with c++ or java etc..
407, file destination is sent to destination node.
It include ineffective law, rule, etc. identical with file destination title when the transmission of any destination node triggers in subdirectory (sending) When part, node will read intermediate transmission catalogue by the corresponding transmission process (logproxy_send) of destination node (receive) file destination is sent to destination node by the file destination in.
408, in the transmission result feedback stage of destination node, if file destination sends failure, empty file is moved to Transmission state subdirectory.
In embodiments of the present invention, after node sends file destination to some destination node, it can receive the destination node Transmission result feedback, to learn whether the file destination is successfully transmitted to the destination node.
In file destination transmission process, the problems such as restarting in case of process exception or machine, target may cause File sends failure.If file destination sends failure, node can touch empty file identical with file destination title from transmission Hair subdirectory (sending) moves to transmission state subdirectory (failed), so that identifying file destination is sent to corresponding destination node Procedure failure, to execute subsequent retransmission process.In any one destination node catalogue, when the hair of destination node catalogue When sending empty file in state subdirectory (failed) to store duration to be more than preset duration, node by file retransmission, deletion at Reason process (logproxy_move_delete) is by the empty file in the transmission state subdirectory (failed) of destination node catalogue It moves to transmission to prepare in subdirectory (ready), so as to execute the process of step 406, enables node again by target text Part is sent to the destination node.
409, in the transmission result feedback stage of destination node, if file destination is sent successfully, judgement will be sent The empty file in empty file and transmission triggering subdirectory in catalogue is deleted.
It specifically, will be in the destination node of the destination node if file destination is successfully transmitted to a certain destination node In catalogue, it will send and judge that the empty file in empty file and transmission triggering subdirectory (sending) in subdirectory (tag) is deleted It removes, to avoid file retransmission, delete processing process (logproxy_move_delete) after scanning to empty file, repeats to send out Send file destination.
In the corresponding all purposes node of file destination, sends the empty file judged in subdirectory (tag) and be deleted Afterwards, node will execute the transmission process of next file destination.Specifically, which may include: to open in file transmission process After beginning, file retransmission, delete processing process (logproxy_move_delete) every preset duration to destination node catalogue into Row scanning;In the corresponding multiple destination node catalogues of file destination, transmission judge subdirectory (tag) it is inner do not include file When identical with the file destination empty file of title, it can determine whether that file destination is successfully sent to all purposes node;Centre is sent out The file destination in catalogue (receive) is sent to delete, so as to obtain next file destination and corresponding multiple purpose sections Point, to execute the transmission process of next file destination.
It should be noted that (1) executes before (2) in above-mentioned Fig. 3, be in order to guarantee file retransmission, delete processing into Journey (logproxy_move_delete), can be from transmission before file destination is sent to intermediate transmission catalogue (receive) Judge that scanning is to empty file in subdirectory (tag), so that the file destination in intermediate transmission catalogue (receive) will not be deleted It removes;And (2) execute before (3), are to guarantee that file sends process (logproxy_send) scanning and arrives to send and prepare specific item When recording the empty file in (ready), file destination can be found by sending in catalogue (receive) from centre, thereby executing target The transmission of file.
Method provided in an embodiment of the present invention, by creating destination node catalogue for multiple destination nodes of file destination, And under each destination node catalogue, the subdirectory that different phase is sent for identifying file is created, to make each purpose section The transmission process of point can carry out file transmission according to respective subdirectory respectively, file in parallel transmission be realized, so that mesh When mark file is sent to multiple destination nodes, the transmission phase of different destination nodes is mutually indepedent, is independent of each other, therefore, target text It when part sends failure to some destination node, has no effect on the file destination and is sent to other purposes node, improve transmission effect Rate;And when file destination is sent to the failure of some destination node, file hair need to be only re-started to the destination node for sending failure It send, saves time and resource.Further, in transmission process, empty file of the same name is introduced in each subdirectory, is made whole A multichannel, which sends treatment process, to be become intuitively, easy to maintain.File is distributed to each road and sends from receiving, can be intuitively from catalogue See file process circulation situation.
Fig. 5 is a kind of structural schematic diagram of file multichannel sending device provided in an embodiment of the present invention, and the device is for holding The file multichannel sending method that the above-mentioned Fig. 2 of row or embodiment shown in Fig. 4 provide.Referring to Fig. 5, which includes:
Determining module 501, for determining file destination information and multiple destination nodes to be sent;
Creation module 502, for creating at least one identification information, at least one described mark letter for each destination node Breath sends different phase for identifying file;
Sending module 503, for when getting the file destination from file directory, based on the file destination, The identification information of each destination node and each destination node carries out file in parallel transmission;
Identification information changes module 504, for being sent not in the transmission phase to each destination node according to file The same stage is modified the identification information of each destination node.
Optionally, the creation module 502, specifically includes:
First creating unit, for creating destination node catalogue for each destination node;
Second creating unit judges that subdirectory, transmission prepare specific item for creating to send in each destination node catalogue Record sends triggering subdirectory, sends state subdirectory;
Third creating unit, for judging to create empty file in subdirectory in the transmission, the filename of the empty file Claim identical as the file destination.
Optionally, the transmission phase of each destination node includes preparation stage, practical transmission phase and transmission knot Fruit feedback stage;
Correspondingly, the identification information changes module 504, in the preparation stage of destination node, when from file mesh When getting the file destination in record, prepare the subdirectory creation empty file sending;In the reality of the destination node In transmission phase, when the transmission prepares in subdirectory to include the empty file, the empty file is moved into transmission triggering Catalogue;In the transmission result feedback stage of the destination node, if file destination sends failure, the empty file is moved to Transmission state subdirectory;It, will be described if file destination is sent successfully in the transmission result feedback stage of the destination node Send the empty file and the empty file deletion sent in triggering subdirectory judged in subdirectory.
Optionally, the sending module 503 is also used to scan when the transmission process of any destination node to the mesh The transmission of node when preparing that there is empty file in subdirectory, Xiang Suoshu destination node sends the file destination.
Optionally, the identification information changes module 504, is also used in any one destination node catalogue, when the mesh Nodal directory transmission state subdirectory in empty file storage duration be more than preset duration when, by the destination node catalogue Transmission state subdirectory in empty file move to the destination node catalogue transmission prepare subdirectory in.
Device provided in an embodiment of the present invention, by carrying out file in parallel transmission, so that file destination is sent to multiple purposes When node, the transmission phase of different destination nodes is mutually indepedent, is independent of each other, and therefore, file destination is sent out to some destination node When sending unsuccessfully, has no effect on the file destination and be sent to other purposes node, improve transmitting efficiency;And when file destination is sent to When some destination node fails, need to only file be re-started to the destination node for sending failure and sent, save time and resource.
Fig. 6 be another embodiment of the present invention provides it is a kind of for file multichannel send server.Referring to Fig. 6, service Device 600 includes processing component 622, further comprises one or more processors, and the storage as representated by memory 632 Device resource, can be by the instruction of the execution of processing component 622, such as application program for storing.The application stored in memory 632 Program may include it is one or more each correspond to one group of instruction module.In addition, processing component 622 is configured To execute instruction, to execute the file multichannel sending method that any embodiment provides in above-mentioned Fig. 1 to Fig. 4 illustrated embodiment.
Server 600 can also include that a power supply module 626 be configured as the power management of execute server 600, and one A wired or wireless network interface 650 is configured as server 600 being connected to network and input and output (I/O) interface 658.Server 600 can be operated based on the operating system for being stored in memory 632, such as Windows ServerTM, Mac OS XTM, UnixTM, LinuxTM, FreeBSDTM or similar.
Wherein, one perhaps more than one program be stored in memory and be configured to by one or more than one Processor executes, and the one or more programs include the instruction for performing the following operation:
Determine file destination information and multiple destination nodes to be sent;
At least one identification information is created for each destination node, at least one identification information is for identifying file transmission Different phase;
When getting file destination from file directory, it is based on file destination, each destination node and each purpose The identification information of node carries out file in parallel transmission;
Wherein, in the transmission phase to each destination node, according to the different phase that file is sent, to each purpose section The identification information of point is modified.
Assuming that above-mentioned is the first possible embodiment, then provided based on the first possible embodiment Second of possible embodiment in, in the memory of server, also include instructions for performing the following operations:
Destination node catalogue is created for each destination node;
In each destination node catalogue creation send judge subdirectory, send prepare subdirectory, send trigger subdirectory, Transmission state subdirectory;
Judge to create empty file in subdirectory sending, the file name of the empty file is identical as file destination.
In the third the possible embodiment provided based on second of possible embodiment, server Also include instructions for performing the following operations in memory:
The transmission phase of each destination node includes preparation stage, practical transmission phase and transmission result feedback stage;
Correspondingly, in the transmission phase to each destination node, according to the different phase that file is sent, to each purpose The identification information of node is modified, comprising:
In the preparation stage of destination node, when getting file destination from file directory, prepare specific item sending Record creation empty file;
In the practical transmission phase of destination node, when sending in preparation subdirectory includes empty file, empty file is moved Subdirectory is triggered to sending;
In the transmission result feedback stage of destination node, if file destination sends failure, empty file is moved into transmission State subdirectory;
In the transmission result feedback stage of destination node, if file destination is sent successfully, transmission is judged into subdirectory In empty file and send triggering subdirectory in empty file delete.
In the 4th kind of possible embodiment provided based on second of possible embodiment, server Also include instructions for performing the following operations in memory:
Each destination node has a transmission process, when destination node is arrived in the transmission process scanning of any destination node When sending in preparation subdirectory with empty file, file destination is sent to destination node.
In the 5th kind of possible embodiment provided based on second of possible embodiment, server Also include instructions for performing the following operations in memory:
In any one destination node catalogue, when the empty file storage in the transmission state subdirectory of destination node catalogue When length is more than preset duration, the empty file in the transmission state subdirectory of destination node catalogue is moved to the hair of destination node catalogue It send and prepares in subdirectory.
Server provided in an embodiment of the present invention, by carrying out file in parallel transmission, so that file destination is sent to multiple mesh Node when, the transmission phases of different destination nodes is mutually indepedent, is independent of each other, and therefore, file destination is to some destination node When sending failure, has no effect on the file destination and be sent to other purposes node, improve transmitting efficiency;And when file destination is sent out Toward when the failure of some destination node, need to only file be re-started to the destination node for sending failure and sent, save time and money Source.
It should be understood that the device that file multichannel provided by the above embodiment is sent is when sending multichannel file, only with The division progress of above-mentioned each functional module can according to need and for example, in practical application by above-mentioned function distribution by not Same functional module is completed, i.e., the internal structure of device is divided into different functional modules, to complete whole described above Or partial function.In addition, the method that device and file multichannel that file multichannel provided by the above embodiment is sent are sent is implemented Example belongs to same design, and specific implementation process is detailed in embodiment of the method, and which is not described herein again.
Those of ordinary skill in the art will appreciate that realizing that all or part of the steps of above-described embodiment can pass through hardware It completes, relevant hardware can also be instructed to complete by program, the program can store in a kind of computer-readable In storage medium, storage medium mentioned above can be read-only memory, disk or CD etc..
The foregoing is merely presently preferred embodiments of the present invention, is not intended to limit the invention, it is all in spirit of the invention and Within principle, any modification, equivalent replacement, improvement and so on be should all be included in the protection scope of the present invention.

Claims (10)

1. a kind of method that file multichannel is sent, which is characterized in that the described method includes:
Determine file destination information and multiple destination nodes to be sent;
At least one identification information is created for each destination node, at least one described identification information is sent not for identifying file The same stage;
When getting the file destination from file directory, based on the file destination, each destination node and The identification information of each destination node carries out file in parallel transmission;
Wherein, in the transmission phase to each destination node, according to the different phase that file is sent, to each purpose section The identification information of point is modified;
Wherein, described to create at least one identification information for each destination node, comprising: to create mesh for each destination node Nodal directory;Creation, which is sent, in each destination node catalogue judges subdirectory, sends preparation subdirectory, sends triggering specific item Record sends state subdirectory;It is described transmission judge to create empty file in subdirectory, the file name of the empty file with it is described File destination is identical, and each subdirectory is an identification information.
2. the method according to claim 1, wherein the transmission phase of each destination node includes preparing rank Section, practical transmission phase and transmission result feedback stage;
Correspondingly, in the transmission phase to each destination node, according to the different phase that file is sent, to described each The identification information of destination node is modified, comprising:
In the preparation stage of destination node, when getting the file destination from file directory, prepare specific item sending Record creates the empty file;
It, will when the transmission prepares in subdirectory to include the empty file in the practical transmission phase of the destination node The empty file moves to transmission triggering subdirectory;
In the transmission result feedback stage of the destination node, if file destination sends failure, the empty file is moved to Transmission state subdirectory;
In the transmission result feedback stage of the destination node, if file destination is sent successfully, the transmission is judged into son Empty file and the empty file sent in triggering subdirectory in catalogue are deleted.
3. the method according to claim 1, wherein the method also includes:
Each destination node has a transmission process, when the transmission process of any destination node is scanned to the purpose section When the transmission of point prepares to have empty file in subdirectory, Xiang Suoshu destination node sends the file destination.
4. the method according to claim 1, wherein the method also includes:
In any one destination node catalogue, when the empty file storage in the transmission state subdirectory of the destination node catalogue When length is more than preset duration, the empty file in the transmission state subdirectory of the destination node catalogue is moved into the destination node The transmission of catalogue prepares in subdirectory.
5. the device that a kind of file multichannel is sent, which is characterized in that described device includes:
Determining module, for determining file destination information and multiple destination nodes to be sent;
Creation module, for creating at least one identification information for each destination node, at least one described identification information is used for It identifies file and sends different phase;
Sending module, for when getting the file destination from file directory, based on the file destination, described each The identification information of destination node and each destination node carries out file in parallel transmission;
Identification information changes module, in the transmission phase to each destination node, according to the different phase that file is sent, The identification information of each destination node is modified;
The creation module, comprising:
First creating unit, for creating destination node catalogue for each destination node;
Second creating unit judges that subdirectory, transmission prepare subdirectory, hair for creating to send in each destination node catalogue It send triggering subdirectory, send state subdirectory;
Third creating unit, for it is described transmission judge to create empty file in subdirectory, the file name of the empty file and The file destination is identical, and each subdirectory is an identification information.
6. device according to claim 5, which is characterized in that the transmission phase of each destination node includes preparing rank Section, practical transmission phase and transmission result feedback stage;
Correspondingly, the identification information changes module, in the preparation stage of destination node, when obtaining from file directory When to the file destination, prepares subdirectory sending and create the empty file;In the practical transmission phase of the destination node In, when the transmission prepares in subdirectory to include the empty file, the empty file is moved into transmission triggering subdirectory;Institute It states in the transmission result feedback stage of destination node, if file destination sends failure, the empty file is moved into transmission state Subdirectory;In the transmission result feedback stage of the destination node, if file destination is sent successfully, the transmission is judged Empty file and the empty file sent in triggering subdirectory in subdirectory are deleted.
7. device according to claim 5, which is characterized in that the sending module is also used to when any destination node Transmission process scans when having empty file into the transmission preparation subdirectory of the destination node, and Xiang Suoshu destination node sends institute State file destination.
8. device according to claim 5, which is characterized in that the identification information changes module, in any one mesh Nodal directory in, when in the transmission state subdirectory of the destination node catalogue empty file storage duration be more than preset duration When, the transmission that the empty file in the transmission state subdirectory of the destination node catalogue moves to the destination node catalogue is prepared In subdirectory.
9. a kind of server, which is characterized in that the server includes processor and memory, is stored with one in the memory A or more than one program, described program are loaded by the processor and are executed to realize such as claim 1 to claim 4 Operation performed by the method that described in any item file multichannels are sent.
10. a kind of computer readable storage medium, which is characterized in that be stored in the computer readable storage medium one or More than one program of person, described program are loaded by server and are executed to realize such as any one of claim 1 to claim 4 institute Operation performed by the method that the file multichannel stated is sent.
CN201410705373.9A 2014-11-26 2014-11-26 The method and device that file multichannel is sent Active CN105701109B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410705373.9A CN105701109B (en) 2014-11-26 2014-11-26 The method and device that file multichannel is sent

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410705373.9A CN105701109B (en) 2014-11-26 2014-11-26 The method and device that file multichannel is sent

Publications (2)

Publication Number Publication Date
CN105701109A CN105701109A (en) 2016-06-22
CN105701109B true CN105701109B (en) 2019-12-03

Family

ID=56230293

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410705373.9A Active CN105701109B (en) 2014-11-26 2014-11-26 The method and device that file multichannel is sent

Country Status (1)

Country Link
CN (1) CN105701109B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107526816B (en) * 2017-08-28 2020-11-24 创新先进技术有限公司 Stream distribution record storage method and device and electronic equipment
CN112600928A (en) * 2020-12-17 2021-04-02 北京锐安科技有限公司 File transmission method and device, electronic equipment and medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1273473A (en) * 1999-05-11 2000-11-15 Lg情报通信株式会社 Asynchronous transmission model packet network and method for transmitting block data in it
CN1855909A (en) * 2005-02-22 2006-11-01 阿尔卡特公司 Multimedia content delivery system
CN101135981A (en) * 2007-08-29 2008-03-05 中兴通讯股份有限公司 Method and device for realizing batch report generation
CN102360310A (en) * 2011-09-28 2012-02-22 中国电子科技集团公司第二十八研究所 Multitask process monitoring method and system in distributed system environment

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8732208B2 (en) * 2010-04-19 2014-05-20 Facebook, Inc. Structured search queries based on social-graph information

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1273473A (en) * 1999-05-11 2000-11-15 Lg情报通信株式会社 Asynchronous transmission model packet network and method for transmitting block data in it
CN1855909A (en) * 2005-02-22 2006-11-01 阿尔卡特公司 Multimedia content delivery system
CN101135981A (en) * 2007-08-29 2008-03-05 中兴通讯股份有限公司 Method and device for realizing batch report generation
CN102360310A (en) * 2011-09-28 2012-02-22 中国电子科技集团公司第二十八研究所 Multitask process monitoring method and system in distributed system environment

Also Published As

Publication number Publication date
CN105701109A (en) 2016-06-22

Similar Documents

Publication Publication Date Title
US9792297B2 (en) File folder transmission on network
CN109040252B (en) File transmission method, system, computer device and storage medium
US10769113B2 (en) Attribute-based dependency identification for operation ordering
CN107770229B (en) Cloud file sharing method and system and cloud server
US20160179495A1 (en) Device and method for packaging application
JP6459258B2 (en) Information processing apparatus, information processing system, information processing method, and program
CN104348859B (en) File synchronisation method, device, server, terminal and system
CN103916479B (en) Cloud synchronous local area network accelerating system based on working group document
JP2015215885A (en) Change planning system, change planning method and change planning program
CN103905495B (en) A kind of synchronous method and background server of application
GB2515192A (en) Systems and methods for synchronization event building and/or collapsing by a synchronization component of a cloud-based platform
CN111666129B (en) Container mirror image processing method, electronic device, storage medium and system
CN102420782A (en) Method, client and system for sharing webpage by instant messaging
CN105518619A (en) Scanning files for inappropriate content during synchronization
CN103944811A (en) Method and device for reminding emails
US20220342518A1 (en) Card-based information management method and system
US11265182B2 (en) Messaging to enforce operation serialization for consistency of a distributed data structure
CN103841180B (en) A kind of network data synchronizing method, apparatus, terminal device and server based on operational order
WO2020226913A1 (en) Merge trees for collaboration
CN105701109B (en) The method and device that file multichannel is sent
CN105335186A (en) Data downloading management method and system
CN106302641B (en) A kind of methods, devices and systems of upper transmitting file
CN107113281A (en) Content shared method, terminal, server and system
CN111200623B (en) Method and system for realizing terminal data synchronization based on distributed storage
JP5913196B2 (en) Computer system and fault identification method

Legal Events

Date Code Title Description
C06 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