CN115378930B - File distribution method and device - Google Patents
File distribution method and device Download PDFInfo
- Publication number
- CN115378930B CN115378930B CN202110535441.1A CN202110535441A CN115378930B CN 115378930 B CN115378930 B CN 115378930B CN 202110535441 A CN202110535441 A CN 202110535441A CN 115378930 B CN115378930 B CN 115378930B
- Authority
- CN
- China
- Prior art keywords
- file
- terminal
- receiving
- server
- receiving terminal
- 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
Links
- 238000000034 method Methods 0.000 title claims abstract description 63
- 230000004044 response Effects 0.000 claims abstract description 52
- 238000004891 communication Methods 0.000 claims description 6
- 238000004590 computer program Methods 0.000 claims description 6
- 230000011664 signaling Effects 0.000 abstract description 11
- 238000010586 diagram Methods 0.000 description 17
- 230000000694 effects Effects 0.000 description 6
- 238000012546 transfer Methods 0.000 description 4
- 230000008878 coupling Effects 0.000 description 3
- 238000010168 coupling process Methods 0.000 description 3
- 238000005859 coupling reaction Methods 0.000 description 3
- 238000012545 processing Methods 0.000 description 3
- 239000002699 waste material Substances 0.000 description 2
- 238000005516 engineering process Methods 0.000 description 1
- 230000006870 function Effects 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 230000008569 process Effects 0.000 description 1
- 238000006467 substitution reaction Methods 0.000 description 1
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/06—Protocols specially adapted for file transfer, e.g. file transfer protocol [FTP]
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/10—Protocols in which an application is distributed across nodes in the network
- H04L67/1097—Protocols in which an application is distributed across nodes in the network for distributed storage of data in networks, e.g. transport arrangements for network file system [NFS], storage area networks [SAN] or network attached storage [NAS]
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/14—Session management
- H04L67/146—Markers for unambiguous identification of a particular session, e.g. session cookie or URL-encoding
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Information Transfer Between Computers (AREA)
Abstract
The application provides a file distribution method and device. The method comprises the following steps: when the sending terminal needs to send a plurality of files to the receiving terminal, generating a file distribution request, wherein the file distribution request comprises: the identification and the attributes of the files are used for determining a receiving terminal by the server according to the identification; the sending terminal sends the file distribution request to the server; and after receiving the response message returned by the server, the sending terminal sends the plurality of files to the receiving terminal through the server so that the receiving terminal stores the plurality of files according to the attribute of each file in the plurality of files. Compared with a mode that a file distribution request needs to be sent once for each file, the signaling overhead is saved.
Description
Technical Field
The present invention relates to communications technologies, and in particular, to a method and an apparatus for distributing files.
Background
In the third generation partnership project (3 rd Generation Partnership Project, 3GPP for short), mission critical data (MCData) specifications support one-to-one file distribution and group file distribution. One-to-one file distribution refers to one user terminal sending a file to another user terminal, and group file distribution refers to one user terminal sending a file to all other user terminals in the group where the user terminal is located. Whether one-to-one file distribution or group file distribution, the sending terminal needs to send a file distribution request to the receiving terminal before sending the file, and the sending terminal sends the file to the receiving terminal after receiving a response message returned by the receiving terminal.
At present MCData is specified, when a sending terminal sends a plurality of files to a receiving terminal, a file distribution request needs to be sent once for each file, signaling overhead is large, and resource waste is caused.
Disclosure of Invention
The application provides a file distribution method and device, which are used for solving the problem of high signaling overhead in the prior art.
In a first aspect, the present application provides a file distribution method, applied to a sending terminal, including: when the sending terminal needs to send a plurality of files to the receiving terminal, generating a file distribution request, wherein the file distribution request comprises: the identification and the attributes of the files are used for determining a receiving terminal by the server according to the identification; the sending terminal sends the file distribution request to the server so that the server determines the receiving terminal according to the identification, and sends the file distribution request to the receiving terminal so that the receiving terminal returns a response message to the server after receiving the file distribution request; and after receiving the response message returned by the server, the sending terminal sends the plurality of files to the receiving terminal through the server so that the receiving terminal stores the plurality of files according to the attribute of each file in the plurality of files.
Optionally, the number of the receiving terminals is one, and the identifier is a unique code ID of the user terminal.
Optionally, the number of the receiving terminals is at least two, and the identifier is an ID of a group where the sending terminal and the receiving terminal are located.
Optionally, the attribute of each file includes: a load attribute of the file and a metadata attribute of the file, the load attribute comprising: load coding, load attribute length, load sequence number and load attribute content; the metadata attributes include: metadata encoding, metadata attribute length, metadata sequence number, and metadata attribute content.
In a second aspect, the present application provides a file distribution method, applied to a server, including: the server receives a file distribution request, the file distribution request comprising: the file distribution request is generated when the sending terminal needs to send the plurality of files to the receiving terminal; the server determines the receiving terminal according to the identification, and sends the file distribution request to the receiving terminal, so that the receiving terminal returns a response message to the server after receiving the file distribution request; after receiving the response message, the server sends the response message to the sending terminal, so that the sending terminal sends the plurality of files to the receiving terminal through the server, and the receiving terminal stores the plurality of files according to the attribute of each file in the plurality of files.
Optionally, the number of the receiving terminals is one, and the identifier is a unique code ID of the user terminal; the server determines the receiving terminal according to the identification, and the method comprises the following steps: and the server determines the user terminal corresponding to the ID as the receiving terminal.
Optionally, the number of the receiving terminals is at least two, and the identifier is an ID of a group where the sending terminal and the receiving terminal are located; the server determines the receiving terminal according to the identification, and the method comprises the following steps: the server determines other user terminals except the sending terminal in the group according to the ID of the group; the server takes other user terminals except the sending terminal in the group as the receiving terminal.
In a third aspect, the present application provides a file distribution method, applied to a receiving terminal, including: the receiving terminal receives a file distribution request, wherein the file distribution request comprises: the file distribution request is generated when the sending terminal needs to send the files to the receiving terminal; the receiving terminal sends a response message to the server so that the server sends the response message to the sending terminal, and the sending terminal sends the files to the receiving terminal through the server; and the receiving terminal stores the files according to the attribute of each file in the files.
Optionally, the receiving terminal sends a response message to the server, including: the receiving terminal displays a file receiving prompt; and when the receiving terminal receives the touch operation of confirming the received file by the user, the response message is sent to the server.
In a fourth aspect, the present application provides a transmitting terminal, including: the generating module is configured to generate a file distribution request when the sending terminal needs to send a plurality of files to the receiving terminal, where the file distribution request includes: the identification and the attributes of the files are used for determining a receiving terminal by the server according to the identification; the sending module is used for sending the file distribution request to the server so that the server determines the receiving terminal according to the identification and sending the file distribution request to the receiving terminal so that the receiving terminal returns a response message to the server after receiving the file distribution request; the receiving module is used for receiving the response message returned by the server; the sending module is further configured to send the plurality of files to the receiving terminal through the server, so that the receiving terminal stores the plurality of files according to an attribute of each file in the plurality of files.
In a fifth aspect, the present application provides a server comprising: the receiving module is used for receiving a file distribution request, and the file distribution request comprises: the file distribution request is generated when the sending terminal needs to send the plurality of files to the receiving terminal; the sending module is used for determining the receiving terminal according to the identification, and sending the file distribution request to the receiving terminal so that the receiving terminal returns a response message to the server after receiving the file distribution request; the sending module is further configured to send the response message to the sending terminal after the receiving module receives the response message, so that the sending terminal sends the plurality of files to the receiving terminal through the server, and the receiving terminal stores the plurality of files according to the attribute of each file in the plurality of files.
In a sixth aspect, the present application provides a receiving terminal, including: the receiving module is used for receiving a file distribution request, and the file distribution request comprises: the file distribution request is generated when the sending terminal needs to send the files to the receiving terminal; a sending module, configured to send a response message to the server, so that the server sends the response message to the sending terminal, so that the sending terminal sends the plurality of files to the receiving terminal through the server; and the storage module is used for storing the files according to the attribute of each file in the files.
In a seventh aspect, the present application provides a communication system including the transmitting terminal of the fourth aspect, the server of the fifth aspect, and the receiving terminal of the sixth aspect.
In an eighth aspect, the present application provides a computer readable storage medium having stored thereon a computer program which when executed by a processor implements the method provided in any of the first to third aspects.
In a ninth aspect, the present application provides a chip comprising: a processor; and a memory for storing executable instructions of the processor; wherein the processor is configured to implement the method provided in any of the first to third aspects via execution of the executable instructions.
According to the file distribution method and device, when the file distribution request is added to the attributes of all files to be transmitted by the transmitting terminal, the receiving terminal knows that a plurality of files to be transmitted by the transmitting terminal exist after receiving the file distribution request, and the receiving terminal stores each file according to the attributes carried in the file distribution request after receiving the plurality of files. Compared with a mode that a file distribution request needs to be sent once for each file, the signaling overhead is saved.
Drawings
FIG. 1 is a first application scenario diagram provided by the present application;
FIG. 2 is a flowchart I of the MCData specification provided by the present application;
FIG. 3 is a second application scenario diagram provided by the present application;
FIG. 4 is a second flowchart of MCData according to the present application;
FIG. 5 is a flowchart illustrating a file distribution method according to a first embodiment of the present application;
FIG. 6 is a diagram of a user interface provided by the present application;
FIG. 7 is a schematic diagram of a Payload attribute provided by the present application;
FIG. 8 is a diagram illustrating Metadata attributes provided by the present application;
FIG. 9 is a second user interface diagram provided by the present application;
FIG. 10 is a flowchart illustrating a file distribution method according to a second embodiment of the present application;
FIG. 11 is a third user interface diagram provided by the present application;
fig. 12 is a schematic structural diagram of a transmitting terminal provided by the present application;
Fig. 13 is a schematic structural diagram of a server according to the present application;
Fig. 14 is a schematic structural diagram of a receiving terminal according to the present application;
Fig. 15 is a schematic diagram of a hardware structure of a chip provided by the present application.
Detailed Description
For the purpose of making the objects, technical solutions and advantages of the present application more apparent, the technical solutions of the present application will be clearly and completely described below with reference to the accompanying drawings, and it is apparent that the described embodiments are some embodiments of the present application, not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the application without making any inventive effort, are intended to be within the scope of the application.
In the present application, it should be construed that the terms "", "" are used for descriptive purposes only and are not to be construed as indicating or implying relative importance. Furthermore, "at least one" means one or more, and "a plurality" means two or more. "and/or", describes an association relationship of an association object, and indicates that there may be three relationships, for example, a and/or B, and may indicate: a alone, a and B together, and B alone, wherein a, B may be singular or plural. The character "may be a relationship that generally indicates that the front and rear associated objects are an" or ". "at least one of" or the like means any combination of these items, including any combination of single item(s) or plural items(s). For example, at least one (one) of a, b, or c may represent: a alone, b alone, c alone, a combination of a and b, a combination of a and c, b and c, or a combination of a, b and c, wherein a, b, c can be single or multiple.
Fig. 1 is a schematic diagram of an application scenario provided by the present application. The application scenario shown in fig. 1 is a one-to-one file distribution scenario. One-to-one file distribution refers to one user terminal sending a file to another user terminal. In fig. 1, a user terminal transmitting a file is represented by a user terminal 1, a user terminal receiving a file is represented by a user terminal 2, and the user terminal 1 interacts with the user terminal 2 through a server. In the scenario shown in fig. 1, the user terminal 1 is also called a transmitting terminal and the user terminal 2 is also called a receiving terminal.
Referring to fig. 2, in the present MCData specification, when the user terminal 1 transmits a certain file to the user terminal 2, the method includes the following steps:
When the file is transmitted by a hypertext transfer protocol (Hypertext Transfer Protocol, HTTP), the user terminal 1 firstly uploads the file to a server, then sends a file distribution request to the user terminal 2 through the server, wherein the file distribution request carries the attribute of the file, the attribute comprises a uniform resource location system (uniform resource locator, URL for short) of the file in the server, and the user terminal 2 downloads the file from the server according to the URL after receiving the file distribution request and stores the file according to other contents in the attribute. Alternatively, the URL may be fed back to the user terminal 1 after the server receives the file uploaded by the user terminal 1.
When the file is transmitted in a Multimedia (MEDIA) manner, the user terminal 1 sends a file distribution request to the user terminal 2 through the server, the file distribution request carries the attribute of the file, the user terminal 2 returns a response message to the user terminal 1 through the server after receiving the file distribution request, the user terminal 1 sends the file to the user terminal 2 after receiving the response message, and the user terminal 2 stores the received file according to the attribute carried in the file distribution request.
However, when the user terminal 1 transmits a plurality of files to the user terminal 2, whether the files are transmitted by HTTP or MEDIA, the user terminal 1 needs to transmit a file distribution request once for each file, and the signaling overhead is large.
Fig. 3 is a second application scenario diagram provided by the present application. The application scenario shown in fig. 3 is a group file distribution scenario. Group file distribution refers to a user terminal sending files to all user terminals except the user terminal in the group where the user terminal is located. In fig. 3, the user terminals that transmit the file are represented by user terminal 1, the group in which user terminal 1 is located is represented by group a, the other user terminals in group a than user terminal 1 are represented by user terminals 2 to N, and user terminal 1 interacts with user terminals 2 to N through a server. In the scenario shown in fig. 3, the user terminal 1 is also called a transmitting terminal, and the user terminals 2 to N are all called receiving terminals.
Referring to fig. 4, in the present MCData specification, when the ue 1 transmits a certain file to the ues 2 to N, the method comprises the following steps:
When the file is transmitted by a hypertext transfer protocol (Hypertext Transfer Protocol, HTTP), the user terminal 1 firstly uploads the file to the server, then sends a file distribution request to the server, the file distribution request carries the identification of the group A and the attribute of the file, the attribute comprises a uniform resource location system (uniform resource locator, URL for short) of the file in the server, after receiving the file distribution request, the server analyzes the file distribution request from the group management server according to the identification of the group A to obtain other user terminals except the user terminal 1 in the group A, namely the user terminal 2 to the user terminal N, sends the file distribution request to the user terminal 2 to the user terminal N, and after receiving the file distribution request, the user terminal 2 to the user terminal N downloads the file from the server according to the URL and stores the file according to other contents in the attribute. Alternatively, the URL may be fed back to the user terminal 1 after the server receives the file uploaded by the user terminal 1.
When the file is transmitted in a Multimedia (MEDIA) manner, the user terminal 1 sends a file distribution request to the server, the file distribution request carries an identifier of the group a and an attribute of the file, after receiving the file distribution request, the server analyzes the group a according to the identifier of the group a to obtain other user terminals except the user terminal 1, namely, the user terminals 2 to N in the group a, and sends the file distribution request to the user terminals 2 to N, after receiving the file distribution request, the user terminals 2 to N return a response message to the user terminal 1 through the server, and after receiving the response message, the user terminal 1 sends the file to the user terminals 2 to N. And the user terminals 2 to N store the received files according to the attributes carried in the file distribution requests.
However, when the user terminal 1 transmits a plurality of files to the user terminals 2 to N, the user terminal 1 needs to transmit a file distribution request once for each file, regardless of the file transmitted by the HTTP method or the file transmitted by the MEDIA method, and the signaling overhead is large.
It can be seen that, in either a one-to-one file distribution scenario or a group file distribution scenario, when the user terminal 1 needs to send a plurality of files, a file distribution request needs to be sent once for each file, which results in a large signaling overhead and a waste of resources.
Considering that the reason why the signaling overhead is large is that the transmitting terminal needs to transmit a file distribution request once for each file, one important role of the file distribution request is to inform the receiving terminal of the attribute of the file to be transmitted by the transmitting terminal. With the method and the device as the access point, the application provides that the file distribution request is added into the attribute of all files to be transmitted by the transmitting terminal, so that the receiving terminal can receive a plurality of files at one time after receiving the file distribution request. Compared with the mode that a file distribution request needs to be sent once for each file, the method saves signaling overhead.
Specific embodiments of the present application will be described in detail below with reference to specific examples. The following embodiments may be combined with each other, and the same or similar concepts or processes may not be described in detail in some embodiments. Embodiments of the present application will be described below with reference to the accompanying drawings.
Example 1
In the scenario shown in fig. 1, fig. 5 is a schematic flow chart of a first embodiment of a file distribution method provided by the present application, and as shown in fig. 5, the file distribution method provided by the present embodiment includes:
s501, when the transmitting terminal needs to transmit a plurality of files to the receiving terminal, the transmitting terminal generates a file distribution request. The file distribution request includes: the ID of the terminal and the attributes of the plurality of files are received.
Alternatively, the file in this embodiment may be a picture.
In a possible implementation manner, the transmitting terminal may determine that multiple pictures need to be transmitted to the receiving terminal in the following scenario:
Referring to fig. 6, after a user opens a chat interface with a friend a after developing any social software on a sending terminal, and makes a clicking operation shown in fig. 6 on the chat interface, the sending terminal displays a selection interface, where the selection interface includes options such as album, shooting, video call, and the like. Under the condition that the user selects the album, the user terminal displays the pictures in the album, after the user selects a plurality of pictures, the sending button is clicked, and at the moment, the sending terminal can determine that the plurality of pictures need to be sent to the user terminal corresponding to the friend A. The transmitting terminal may further generate a file distribution request, where the file distribution request includes an ID of the user terminal corresponding to the user a and attributes of the plurality of pictures selected by the user.
The attributes of the plurality of files are described below:
The file distribution request carries attributes of a plurality of files, and each attribute of the files comprises a load (Payload) attribute of the file and a Metadata (Metadata) attribute of the file.
Referring to fig. 7, the Payload attribute of the file includes: load coding, load attribute length, load sequence number, and load attribute content. In the art, load encoding may be represented using Payload IEI, load attribute length may be represented using Length of Payload contents, load sequence number may be represented using Sequence of Payload, and load attribute content may be represented using Payload contents. The load code may occupy one byte, the load attribute length may occupy two bytes, the load sequence number may occupy one byte, and the number of bytes occupied by the load attribute content is related to Length of Payload contents. The load attribute content includes: load type and specific load content.
Referring to fig. 8, metadata attributes of a file include: metadata encoding, metadata attribute length, metadata sequence number, and metadata attribute content. Metadata encoding may be represented using METADATA IEI, metadata attribute length may be represented using Length of Metadata contents, metadata sequence number may be represented using Sequence of Metadata, and metadata attribute content may be represented using Metadata contents, as is known in the art. Metadata encoding may occupy one byte, metadata attribute length may occupy two bytes, metadata sequence number may occupy one byte, and metadata attribute content may be related to number of bytes Length of Metadata contents. The metadata attribute content includes: file name, file date, file description, file size, etc.
In fig. 7 and 8, ott 1 represents the first byte, ott 2 represents the second byte, and so on, each byte having 8 bits.
S502, the sending terminal sends a file distribution request to the server.
S503, the server determines the receiving terminal according to the ID of the receiving terminal.
S504, the server sends a file distribution request to the receiving terminal.
In one possible implementation manner, the server directly uses the user terminal corresponding to the received ID as a receiving terminal, and sends the file distribution request to the user terminal.
S505, the receiving terminal sends a response message to the server.
In one possible implementation manner, after receiving the file distribution request, the receiving terminal may display a file receiving reminder first, and after receiving a touch operation for confirming that the file is received by the user, send a response message to the server. The method combines the receiving willingness of the user, and the sending terminal can not send the file to the receiving terminal under the condition that the user does not want to receive the file, so that network resources are saved, and meanwhile, the use experience of the user is improved.
In a possible implementation manner, the receiving terminal may display the file receipt reminder in the following manner:
As shown in fig. 9, the receiving terminal may display the dialog box shown in fig. 9 to ask the user whether to agree to receive the file, if the user clicks yes, the receiving terminal sends a response message to the server, if the user clicks no, the receiving terminal does not send a response message to the server, and since the sending terminal sends the file after receiving the response message, the sending terminal does not send the file to the receiving terminal if the user clicks no, thereby saving network resources.
S506, the server sends a response message to the sending terminal.
S507, the sending terminal sends the first file to the server.
S508, the server forwards the first file to the receiving terminal.
S509, the receiving terminal stores the first file according to the attribute of the first file.
It should be noted that: as shown in fig. 5, similar steps are performed for the second file, the third file, and … n-th file. Such as: after the sending terminal sends the first file, the second file is sent to the server, the server further forwards the second file to the receiving terminal, and the receiving terminal stores the second file according to the attribute of the second file after receiving the second file.
Specifically, referring to fig. 7 and 8, after receiving the first file, the receiving terminal searches for the load attribute with the load serial number of 1 from the load attributes of each file, uses the load attribute as the load attribute of the first file, and similarly searches for the metadata attribute with the metadata serial number of 1 from the metadata attributes of each file, and uses the metadata attribute as the metadata attribute of the first file. And storing the first file according to the load attribute content in the load attribute with the load serial number of 1 and the metadata attribute content in the metadata attribute with the metadata serial number of 1.
Similarly, after receiving the second file, the receiving terminal searches the load attribute with the load serial number of 2 from the load attributes of each file, uses the load attribute as the load attribute of the second file, and similarly searches the metadata attribute with the metadata serial number of 2 from the metadata attribute of each file, and uses the metadata attribute as the metadata attribute of the second file. And storing the second file according to the load attribute content in the load attribute with the load serial number of 2 and the metadata attribute content in the metadata attribute with the metadata serial number of 2. And so on for subsequent files.
It should be noted that: the above numbers of loads are represented by numbers 1,2, etc. merely as an example, and may be represented by other forms, which are not limiting to the present application. According to the file distribution method provided by the embodiment, under a one-to-one distribution scene, the file distribution request is added to the attributes of all files to be transmitted by the transmitting terminal, so that after the receiving terminal receives the file distribution request, the receiving terminal knows that a plurality of files to be transmitted by the transmitting terminal exist, and after receiving the plurality of files, the receiving terminal stores each file according to the attributes carried in the file distribution request. Compared with the mode that a file distribution request needs to be sent once for each file, the method saves signaling overhead.
It should be noted that: the above-described S501 to S509 describe in detail a distribution method when a plurality of files transmitted by the transmitting terminal are files transmitted by the MEDIA method. If the plurality of files sent by the sending terminal are files transmitted in the HTTP manner, the user terminal 1 may upload the plurality of files to the server, and the server feeds back URLs of the plurality of files in the server to the sending terminal, where the sending terminal sends, to the receiving terminal, a file distribution request through the server, where the file distribution request carries attributes of each file, where each attribute of the file includes a load (Payload) attribute of the file and a Metadata (Metadata) attribute of the file, and the load (Payload) attribute includes a corresponding URL, and in particular, the URL may be carried in the load attribute content in fig. 7. After receiving the file distribution request, the receiving terminal downloads the first file from the server according to the URL in the load attribute content with the load serial number of 1, and stores the first file according to other information in the load attribute content with the load serial number of 1 and the metadata attribute content with the metadata serial number of 1. And so on for subsequent files.
Example two
In the scenario shown in fig. 3, fig. 10 is a schematic flow chart of a second embodiment of the file distribution method provided by the present application, as shown in fig. 10, where the file distribution method provided by the present embodiment includes:
S1001, when the transmitting terminal needs to transmit a plurality of files to the receiving terminal, the transmitting terminal generates a file distribution request. The file distribution request includes: the IDs of the group in which the transmitting terminal and the receiving terminal are located and the attributes of the plurality of files.
In a possible implementation manner, the transmitting terminal may determine that multiple pictures need to be transmitted to the receiving terminal in the following scenario:
after participating in fig. 11, after the user opens any social software on the sending terminal, the chat interface of the group a is opened, and the clicking operation shown in fig. 11 is performed on the chat interface, and the sending terminal displays a selection interface, where the selection interface includes options such as album, shooting, video call, and the like. Under the condition that the user selects the album, the user terminal displays the pictures in the album, after the user selects a plurality of pictures, the sending button is clicked, and at the moment, the sending terminal can determine that the plurality of pictures need to be sent to the user terminals corresponding to other members in the group A. The transmitting terminal may further generate a file distribution request including the ID of the group a and the attributes of the plurality of pictures selected by the user.
S1002, a sending terminal sends a file distribution request to a server.
S1003, the server determines the receiving terminal according to the ID of the group.
In one possible implementation manner, the group management server maintains the correspondence between the group ID and the user terminal, and after receiving the file distribution request, the server searches the user terminal corresponding to the ID carried by the file distribution request from the group management server. And taking other user terminals except the sending terminal in the user terminals corresponding to the ID carried by the file distribution request as receiving terminals.
S1004, the server sends a file distribution request to the receiving terminal.
S1005, the receiving terminal sends a response message to the server.
In a possible implementation manner, like the above embodiment, after receiving the file distribution request, the receiving terminal may display a file receiving reminder first, and after receiving a touch operation that the user confirms to receive the file, send a response message to the server. The method combines the receiving willingness of the user, and the sending terminal can not send the file to the receiving terminal under the condition that the user does not want to receive the file, so that network resources are saved, and meanwhile, the use experience of the user is improved.
It should be noted that: s1006 applies to any one of the user terminals 2 to N in the scenario shown in fig. 3.
S1006, the server sends a response message to the sending terminal.
S1007, the sending terminal sends the first file to the server.
S1008, the server forwards the first file to the receiving terminal.
S1009, the receiving terminal stores the first file according to the attribute of the first file.
It should be noted that: as shown in fig. 10, similar steps are performed for the second file, the third file, and … n-th file. Such as: after the sending terminal sends the first file, the second file is sent to the server, the server further forwards the second file to the receiving terminal, and the receiving terminal stores the second file according to the attribute of the second file after receiving the second file.
The specific storage manner refers to the above embodiment, and this embodiment is not described herein.
In the file distribution method provided in this embodiment, in a group file distribution scenario, a file distribution request is added to attributes of all files to be transmitted by a transmitting terminal, so that after a plurality of receiving terminals receive the file distribution request, it is known that there are a plurality of files to be transmitted by the transmitting terminal, and after each receiving terminal receives the plurality of files, each file is stored according to the attributes carried in the file distribution request. Compared with the mode that a file distribution request needs to be sent once for each file, the method saves signaling overhead.
It should be noted that: in the group file distribution scenario, the above-described S1001 to S1009 describe in detail a distribution method when a plurality of files transmitted by the transmitting terminal are files transmitted by the MEDIA method. If the plurality of files sent by the sending terminal are files transmitted by the HTTP mode, the sending terminal can upload the plurality of files to the server first, and the server feeds back the URLs of the plurality of files in the server to the sending terminal. The sending terminal then sends a file distribution request to the server, the file distribution request carrying the ID of the group and the attributes of the respective files, each file's attributes including a load (Payload) attribute of the file and Metadata (Metadata) attribute of the file, the load (Payload) attribute in turn including a corresponding URL, which may be specifically carried in the load attribute content in fig. 7. After receiving the file distribution request, the server determines the receiving terminal according to the ID of the group. And then transmits a file distribution request to the receiving terminal. After receiving the file distribution request, the receiving terminal downloads the first file from the server according to the URL in the load attribute content with the load serial number of 1, and stores the first file according to other information in the load attribute content with the load serial number of 1 and the metadata attribute content with the metadata serial number of 1. And so on for subsequent files.
Fig. 12 is a schematic structural diagram of a transmitting terminal provided by the present application. As shown in fig. 12, the transmitting terminal provided by the present application includes:
A generating module 1201, configured to generate a file distribution request when the sending terminal needs to send a plurality of files to the receiving terminal, where the file distribution request includes: the identification and the attributes of the files are used for determining a receiving terminal by the server according to the identification;
A sending module 1202, configured to send the file distribution request to the server, so that the server determines the receiving terminal according to the identifier, and send the file distribution request to the receiving terminal, so that the receiving terminal returns a response message to the server after receiving the file distribution request;
a receiving module 1203, configured to receive the response message returned by the server;
The sending module is further configured to send the plurality of files to the receiving terminal through the server, so that the receiving terminal stores the plurality of files according to an attribute of each file in the plurality of files.
Optionally, the number of the receiving terminals is one, and the identifier is a unique code ID of the user terminal.
Optionally, the number of the receiving terminals is at least two, and the identifier is an ID of a group where the sending terminal and the receiving terminal are located.
Optionally, the attribute of each file includes: a load attribute of the file and a metadata attribute of the file, the load attribute comprising: load coding, load attribute length, load sequence number and load attribute content; the metadata attributes include: metadata encoding, metadata attribute length, metadata sequence number, and metadata attribute content.
The transmitting terminal shown in fig. 12 may be used to perform the steps performed by the transmitting terminal in any of the method embodiments described above. The implementation principle and the technical effect are similar, and are not repeated here.
Fig. 13 is a schematic structural diagram of a server according to the present application. As shown in fig. 13, the server provided by the present application includes:
A receiving module 1301, configured to receive a file distribution request, where the file distribution request includes: the file distribution request is generated when the sending terminal needs to send the plurality of files to the receiving terminal;
A sending module 1302, configured to determine the receiving terminal according to the identifier, and send the file distribution request to the receiving terminal, so that the receiving terminal returns a response message to the server after receiving the file distribution request;
The sending module 1302 is further configured to send the response message to the sending terminal after the receiving module receives the response message, so that the sending terminal sends the plurality of files to the receiving terminal through the server, so that the receiving terminal stores the plurality of files according to the attribute of each file in the plurality of files.
Optionally, the number of the receiving terminals is one, and the identifier is a unique code ID of the user terminal; the sending module 1302 is specifically configured to:
and the server determines the user terminal corresponding to the ID as the receiving terminal.
Optionally, the number of the receiving terminals is at least two, and the identifier is an ID of a group where the sending terminal and the receiving terminal are located; the sending module 1302 is specifically configured to:
The server determines other user terminals except the sending terminal in the group according to the ID of the group; the server takes other user terminals except the sending terminal in the group as the receiving terminal.
The sending terminal shown in fig. 13 may be used to perform the steps performed by the server in any of the method embodiments described above. The implementation principle and the technical effect are similar, and are not repeated here.
Fig. 14 is a schematic structural diagram of a receiving terminal according to the present application. As shown in fig. 14, the receiving terminal provided by the present application includes:
A receiving module 1401, configured to receive a file distribution request, where the file distribution request includes: the file distribution request is generated when the sending terminal needs to send the files to the receiving terminal;
A sending module 1402, configured to send a response message to the server, so that the server sends the response message to the sending terminal, so that the sending terminal sends the plurality of files to the receiving terminal through the server;
A storage module 1403 is configured to store the plurality of files according to an attribute of each of the plurality of files.
The transmitting terminal shown in fig. 14 may be used to perform the steps performed by the receiving terminal in any of the method embodiments described above. The implementation principle and the technical effect are similar, and are not repeated here.
Fig. 15 is a schematic diagram of a hardware structure of a chip provided by the present application. As shown in fig. 15, the chip of the present embodiment may include:
A memory 1501 for storing program instructions.
The processor 1502 is configured to implement the step of sending a terminal in any of the method embodiments described above, or implement the step of a server in any of the method embodiments described above, or implement the step of receiving a terminal in any of the method embodiments described above when the program instructions are executed. The implementation principle and the technical effect are similar, and are not repeated here.
The present application provides a computer readable storage medium having stored thereon a computer program which, when executed by a processor, implements the steps of transmitting a terminal in any of the method embodiments described above, or implements the steps of a server in any of the method embodiments described above, or implements the steps of receiving a terminal in any of the method embodiments described above. The implementation principle and the technical effect are similar, and are not repeated here.
The present application also provides a program product comprising a computer program stored in a readable storage medium, from which at least one processor can read, the at least one processor executing the computer program to cause the processor to implement the steps of transmitting a terminal in any of the method embodiments described above, or to implement the steps of a server in any of the method embodiments described above, or to implement the steps of receiving a terminal in any of the method embodiments described above. The implementation principle and the technical effect are similar, and are not repeated here.
The application also provides a communication system which comprises the transmitting terminal shown in fig. 12, the server shown in fig. 13 and the receiving terminal shown in fig. 14.
In the several embodiments provided by the present application, it should be understood that the disclosed apparatus and method may be implemented in other manners. For example, the apparatus embodiments described above are merely illustrative, e.g., the division of the units is merely a logical function division, and there may be additional divisions when actually implemented, e.g., multiple units or components may be combined or integrated into another system, or some features may be omitted or not performed. Alternatively, the coupling or direct coupling or communication connection shown or discussed with each other may be an indirect coupling or communication connection via some interfaces, devices or units, which may be in electrical, mechanical or other form.
The units described as separate units may or may not be physically separate, and units shown as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
In addition, each functional unit in the embodiments of the present application may be integrated in one processing unit, or each unit may exist alone physically, or two or more units may be integrated in one unit. The integrated units may be implemented in hardware or in hardware plus software functional units.
The integrated units implemented in the form of software functional units described above may be stored in a computer readable storage medium. The software functional unit is stored in a storage medium, and includes several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) or a processor (english: processor) to perform some of the steps of the methods according to the embodiments of the application. And the aforementioned storage medium includes: u disk, mobile hard disk, read-Only Memory (ROM), random access Memory (Random Access Memory, RAM), magnetic disk or optical disk, etc.
It should be understood that the Processor described in the present application may be a central processing unit (english: central Processing Unit, abbreviated as CPU), other general purpose processors, digital signal Processor (english: DIGITAL SIGNAL Processor, abbreviated as DSP), application specific integrated Circuit (english: application SPECIFIC INTEGRATED Circuit, abbreviated as ASIC), etc. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like. The steps of a method disclosed in connection with the present application may be embodied directly in a hardware processor for execution, or in a combination of hardware and software modules in a processor for execution.
Finally, it should be noted that: the above embodiments are only for illustrating the technical solution of the present application, and not for limiting the same; although the application has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical scheme described in the foregoing embodiments can be modified or some or all of the technical features thereof can be replaced by equivalents; such modifications and substitutions do not depart from the spirit of the application.
Claims (12)
1. A file distribution method applied to a transmitting terminal, comprising:
When the sending terminal needs to send a plurality of files to the receiving terminal, generating a file distribution request, wherein the file distribution request comprises: the identification and the attributes of the files are used for determining a receiving terminal by the server according to the identification; the identification is the ID of the group where the sending terminal and the receiving terminal are located;
The sending terminal sends the file distribution request to the server so that the server determines other user terminals except the sending terminal in the group according to the ID of the group, determines the receiving terminal for the other user terminals except the sending terminal in the group, and sends the file distribution request to the receiving terminal so that the receiving terminal displays a file receiving prompt after receiving the file distribution request, and returns a response message to the server when a user of the receiving terminal confirms the touch operation of receiving the file;
And after receiving the response message returned by the server, the sending terminal sends the plurality of files to the receiving terminal through the server so that the receiving terminal stores the plurality of files according to the attribute of each file in the plurality of files.
2. The method of claim 1, wherein the number of receiving terminals is one and the identification is a unique coded ID of the receiving terminal.
3. The method according to claim 1 or 2, wherein the attributes of each file include: a load attribute of the file and a metadata attribute of the file, the load attribute comprising: load coding, load attribute length, load sequence number and load attribute content; the metadata attributes include: metadata encoding, metadata attribute length, metadata sequence number, and metadata attribute content.
4. A file distribution method applied to a server, comprising:
The server receives a file distribution request, the file distribution request comprising: the method comprises the steps of identifying and attribute of a plurality of files, wherein a file distribution request is generated when a sending terminal needs to send the plurality of files to a receiving terminal; the identification is the ID of the group where the sending terminal and the receiving terminal are located;
The server determines other user terminals except the sending terminal in the group according to the ID of the group, determines the receiving terminal from the other user terminals except the sending terminal in the group, and sends the file distribution request to the receiving terminal, so that the receiving terminal displays a file receiving reminder after receiving the file distribution request, and returns a response message to the server when receiving a touch operation of confirming the received file by the user of the receiving terminal;
After receiving the response message, the server sends the response message to the sending terminal, so that the sending terminal sends the plurality of files to the receiving terminal through the server, and the receiving terminal stores the plurality of files according to the attribute of each file in the plurality of files.
5. The method of claim 4, wherein the number of receiving terminals is one, and the identification is a unique coded ID of the receiving terminal;
the server determines the receiving terminal according to the identification, and the method comprises the following steps:
and the server determines the user terminal corresponding to the ID as the receiving terminal.
6. A file distribution method applied to a receiving terminal, comprising:
The receiving terminal receives a file distribution request, wherein the file distribution request comprises: the file distribution request is generated when the sending terminal needs to send the files to the receiving terminal;
the receiving terminal displays a file receiving prompt; when the receiving terminal receives the touch operation of confirming the received file by the user, a response message is sent to a server, so that the server sends the response message to the sending terminal, and the sending terminal sends the files to the receiving terminal through the server;
And the receiving terminal stores the files according to the attribute of each file in the files.
7. A transmitting terminal, comprising:
The generating module is configured to generate a file distribution request when the sending terminal needs to send a plurality of files to the receiving terminal, where the file distribution request includes: the identification and the attributes of the files are used for determining a receiving terminal by the server according to the identification; the identification is the ID of the group where the sending terminal and the receiving terminal are located;
A sending module, configured to send the file distribution request to the server, so that the server determines, according to the ID of the group, other user terminals in the group except the sending terminal, uses the other user terminals in the group except the sending terminal as the receiving terminal, and sends the file distribution request to the receiving terminal, so that after the receiving terminal receives the file distribution request, a file receiving reminder is displayed, and when a user of the receiving terminal confirms a touch operation of receiving a file, a response message is returned to the server;
The receiving module is used for receiving the response message returned by the server;
The sending module is further configured to send the plurality of files to the receiving terminal through the server, so that the receiving terminal stores the plurality of files according to an attribute of each file in the plurality of files.
8. A server for a server, which comprises a server and a server, characterized by comprising the following steps:
The receiving module is used for receiving a file distribution request, and the file distribution request comprises: the method comprises the steps of identifying and attribute of a plurality of files, wherein a file distribution request is generated when a sending terminal needs to send the plurality of files to a receiving terminal; the identification is the ID of the group where the sending terminal and the receiving terminal are located;
A sending module, configured to determine, according to the ID of the group, other user terminals in the group except the sending terminal, determine the other user terminals in the group except the sending terminal as the receiving terminal, and send the file distribution request to the receiving terminal, so that after the receiving terminal receives the file distribution request, a file reception reminder is displayed, and when a touch operation of receiving a file is confirmed by a user of the receiving terminal, a response message is returned to the server;
The sending module is further configured to send the response message to the sending terminal after the receiving module receives the response message, so that the sending terminal sends the plurality of files to the receiving terminal through the server, and the receiving terminal stores the plurality of files according to the attribute of each file in the plurality of files.
9. A receiving terminal, comprising:
the receiving module is used for receiving a file distribution request, and the file distribution request comprises: the file distribution request is generated when the sending terminal needs to send the files to the receiving terminal;
The sending module is used for displaying a file receiving prompt; when the receiving terminal receives the touch operation of confirming the received file by the user, a response message is sent to a server, so that the server sends the response message to the sending terminal, and the sending terminal sends the files to the receiving terminal through the server;
And the storage module is used for storing the files according to the attribute of each file in the files.
10. A communication system comprising the transmitting terminal of claim 7, the server of claim 8, and the receiving terminal of claim 9.
11. A computer readable storage medium, on which a computer program is stored, characterized in that the computer program, when being executed by a processor, implements the method of any of claims 1-6.
12. A chip, comprising:
a processor; and
A memory for storing executable instructions of the processor;
Wherein the processor is configured to implement the method of any of claims 1-6 via execution of the executable instructions.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202110535441.1A CN115378930B (en) | 2021-05-17 | 2021-05-17 | File distribution method and device |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202110535441.1A CN115378930B (en) | 2021-05-17 | 2021-05-17 | File distribution method and device |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| CN115378930A CN115378930A (en) | 2022-11-22 |
| CN115378930B true CN115378930B (en) | 2024-08-13 |
Family
ID=84058978
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| CN202110535441.1A Active CN115378930B (en) | 2021-05-17 | 2021-05-17 | File distribution method and device |
Country Status (1)
| Country | Link |
|---|---|
| CN (1) | CN115378930B (en) |
Citations (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN102148835A (en) * | 2011-04-27 | 2011-08-10 | 许式伟 | Method and system for transmitting and sharing electronic documents |
| CN104521289A (en) * | 2012-08-08 | 2015-04-15 | 三星电子株式会社 | Apparatus and method of connecting service according to user intention |
| CN108737482A (en) * | 2017-04-24 | 2018-11-02 | 腾讯科技(深圳)有限公司 | Document sharing method, device and system |
| CN111478951A (en) * | 2020-03-26 | 2020-07-31 | 深圳市鸿合创新信息技术有限责任公司 | File issuing method and device |
Family Cites Families (19)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JPH11353247A (en) * | 1998-06-05 | 1999-12-24 | Nippon Telegr & Teleph Corp <Ntt> | File distribution method and system, and storage medium storing file distribution program |
| US6397246B1 (en) * | 1998-11-13 | 2002-05-28 | International Business Machines Corporation | Method and system for processing document requests in a network system |
| CN101860571A (en) * | 2010-06-12 | 2010-10-13 | 中兴通讯股份有限公司 | Method, system and terminal for realizing delivery of dynamic content distribution service files |
| KR20120110871A (en) * | 2011-03-30 | 2012-10-10 | 주식회사 케이티 | Method for determining and searching storage server in distributed file system |
| CN102833294B (en) * | 2011-06-17 | 2015-05-20 | 阿里巴巴集团控股有限公司 | File processing method and system based on cloud storage, and server cluster system |
| CN102571950B (en) * | 2011-12-31 | 2014-11-05 | 华为技术有限公司 | Media content providing and acquiring methods, server and user terminal |
| US8515904B1 (en) * | 2012-03-29 | 2013-08-20 | Emc Corporation | Providing file sytem quota support for a file system having separated data and metadata |
| CN104247376B (en) * | 2013-04-02 | 2018-06-26 | 华为技术有限公司 | File uploading method, client, application server and the cloud storage system of cloud storage |
| AU2013403132B2 (en) * | 2013-10-18 | 2016-11-24 | Huawei Technologies Co., Ltd. | Data storage method, data storage apparatus, and storage device |
| CN105357321A (en) * | 2015-12-11 | 2016-02-24 | 北京元心科技有限公司 | File transmission method based on abstract value, terminal, and file server |
| CN105677778A (en) * | 2015-12-30 | 2016-06-15 | 深圳市鼎芯无限科技有限公司 | Small picture batch processing method, intelligent terminal and server |
| CN107872489B (en) * | 2016-09-28 | 2020-06-05 | 杭州海康威视数字技术股份有限公司 | File slice uploading method and device and cloud storage system |
| CN108093015B (en) * | 2016-11-21 | 2020-09-01 | 北京京东尚科信息技术有限公司 | file transfer system |
| CN107070972B (en) * | 2016-12-30 | 2020-02-07 | 中国银联股份有限公司 | Distributed file processing method and device |
| US10387383B2 (en) * | 2017-02-15 | 2019-08-20 | Google Llc | Systems and methods for providing access to a data file stored at a data storage system |
| CN108280228A (en) * | 2018-02-26 | 2018-07-13 | 北京车和家信息技术有限公司 | A kind of processing method and relevant device of webpage |
| CN109471844B (en) * | 2018-10-10 | 2022-02-18 | 深圳市达仁基因科技有限公司 | File sharing method and device, computer equipment and storage medium |
| CN109862098A (en) * | 2019-02-01 | 2019-06-07 | 东软医疗系统股份有限公司 | Method and device for uploading medical image files to cloud |
| CN112261624B (en) * | 2019-12-31 | 2022-01-11 | 华为技术有限公司 | Method, electronic equipment and system for transmitting file in application |
-
2021
- 2021-05-17 CN CN202110535441.1A patent/CN115378930B/en active Active
Patent Citations (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN102148835A (en) * | 2011-04-27 | 2011-08-10 | 许式伟 | Method and system for transmitting and sharing electronic documents |
| CN104521289A (en) * | 2012-08-08 | 2015-04-15 | 三星电子株式会社 | Apparatus and method of connecting service according to user intention |
| CN108737482A (en) * | 2017-04-24 | 2018-11-02 | 腾讯科技(深圳)有限公司 | Document sharing method, device and system |
| CN111478951A (en) * | 2020-03-26 | 2020-07-31 | 深圳市鸿合创新信息技术有限责任公司 | File issuing method and device |
Also Published As
| Publication number | Publication date |
|---|---|
| CN115378930A (en) | 2022-11-22 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| US7801941B2 (en) | Apparatus and method for exchanging data between two devices | |
| CN111368173A (en) | File transmission method, device, electronic device and readable storage medium | |
| CN113391979A (en) | Processing method, equipment and system for monitoring data display and storage medium | |
| CN111163130A (en) | A network service system and data transmission method thereof | |
| CN110838969B (en) | Picture transmission method, device, equipment and medium | |
| CN108197210B (en) | User interactive reading method based on friend relationship and computing equipment | |
| CN110311855B (en) | User message processing method and device, electronic equipment and storage medium | |
| CN108880972B (en) | Information processing method, server and terminal | |
| JP5779955B2 (en) | Server device, attraction system, and attraction method | |
| CN104967646A (en) | File downloading method and apparatus | |
| TWI262678B (en) | Peer-to-peer communication system, method and machine-readable storage medium | |
| CN115378930B (en) | File distribution method and device | |
| CN105656769B (en) | Business data processing method, device and system | |
| CN113824625B (en) | Information interaction method and device | |
| CN115550380B (en) | Data synchronization methods, devices, equipment and storage media | |
| CN107835124B (en) | Mail sending method, device and system | |
| CN107370731B (en) | Method and device for realizing communication between different applications based on natural language | |
| CN113612676B (en) | Social group message synchronization method, device, equipment and storage medium | |
| CN105978853B (en) | Session scheduling method, scheduling server and terminal | |
| CN111478951B (en) | File issuing method and device | |
| CN107395583B (en) | Method and device for realizing communication between different applications based on natural language | |
| CN115002058A (en) | Information processing method and related device | |
| CN117201445A (en) | Message processing method and related product | |
| CN102333121B (en) | Method for sending and receiving HTTP (Hyper Text Transfer Protocol) attachment as well as server and terminal equipment | |
| CN101662740A (en) | Transmission method of multimedia message accessory at network side and equipment thereof |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| PB01 | Publication | ||
| PB01 | Publication | ||
| SE01 | Entry into force of request for substantive examination | ||
| SE01 | Entry into force of request for substantive examination | ||
| GR01 | Patent grant | ||
| GR01 | Patent grant |