CN112953812A - File message uploading and storing method and device thereof - Google Patents

File message uploading and storing method and device thereof Download PDF

Info

Publication number
CN112953812A
CN112953812A CN202110126667.6A CN202110126667A CN112953812A CN 112953812 A CN112953812 A CN 112953812A CN 202110126667 A CN202110126667 A CN 202110126667A CN 112953812 A CN112953812 A CN 112953812A
Authority
CN
China
Prior art keywords
file
instant message
message
instant
user
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202110126667.6A
Other languages
Chinese (zh)
Inventor
白天
陶昌军
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Tibet Ningsuan Technology Group Co ltd
Original Assignee
Tibet Ningsuan Technology Group 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 Tibet Ningsuan Technology Group Co ltd filed Critical Tibet Ningsuan Technology Group Co ltd
Priority to CN202110126667.6A priority Critical patent/CN112953812A/en
Publication of CN112953812A publication Critical patent/CN112953812A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L51/00User-to-user messaging in packet-switching networks, transmitted according to store-and-forward or real-time protocols, e.g. e-mail
    • H04L51/04Real-time or near real-time messaging, e.g. instant messaging [IM]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L51/00User-to-user messaging in packet-switching networks, transmitted according to store-and-forward or real-time protocols, e.g. e-mail
    • H04L51/07User-to-user messaging in packet-switching networks, transmitted according to store-and-forward or real-time protocols, e.g. e-mail characterised by the inclusion of specific contents
    • H04L51/18Commands or executable codes
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/06Protocols specially adapted for file transfer, e.g. file transfer protocol [FTP]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/55Push-based network services

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Information Transfer Between Computers (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The application discloses a file message uploading and storing method and a device thereof, wherein the method comprises the following steps: step S10: the user A selects a local storage file F1 by using an instant message client and sends the local storage file F1 to the user B through the instant message client; step S20: the instant messaging client calculates the unique identification IdF1 of the local file F1; step S30: the instant message client sends the IdF1 to the instant message server, the instant message server scans the stored file identification, if the file with the same identification is found, the file uploading success prompt is returned to the instant message client, and the uploading operation of the instant message client to the file F1 is stopped. By marking the same file and firstly scanning the file identification on the message server, after the file with the consistent file identification is obtained, the prompt of uploading completion is returned, the high-speed experience of the user on the file uploading efficiency can be effectively improved, the waiting uploading time of the user is reduced, and the method is particularly suitable for large files which are repeatedly uploaded and downloaded.

Description

File message uploading and storing method and device thereof
Technical Field
The application relates to a file message uploading and storing method and a device thereof, belonging to the technical field of file processing.
Background
Instant messaging is a service where a terminal is networked to an instant messaging network. Instant messaging differs from email in that conversations are sent immediately (in real time). Most instant messaging services provide the feature of status information-display a list of contacts, whether they are online, and whether they can talk to. Instant messaging apps such as QQ, wechat, etc. all have this functionality. Instant messaging services support sending file messages in addition to traditional text messages, i.e. the user can send local files to other contacts in the instant messaging service.
The user (same user or different users) sends (except for forwarding) files with completely same content for multiple times, the instant communication client uploads the complete files to the instant communication server for multiple times, and the instant communication server stores the files uploaded each time, so that the file storage server stores too many copies of the same file, the memory of the server is not occupied by the copies of the same file, the reading efficiency of the same file is reduced, and the transmission efficiency of the instant communication file is influenced.
Disclosure of Invention
The application provides a file message uploading and storing method and a device thereof, which are used for solving the technical problems that the same file is repeatedly uploaded in the instant communication process to occupy the internal memory of a server and the uploading and downloading efficiency is reduced in the prior art.
The application provides a file message uploading and storing method, which comprises the following steps:
step S10: the user A selects a local storage file F1 by using an instant message client and sends the local storage file F1 to the user B through the instant message client;
step S20: the instant messaging client calculates the unique identification IdF1 of the local file F1;
step S30: the instant message client sends the IdF1 to the instant message server, the instant message server scans the stored file identification, if the file with the same identification is found, the file uploading success prompt is returned to the instant message client, and the uploading operation of the instant message client to the file F1 is stopped.
Preferably, the method comprises the following steps:
step S40: if the same identification file is not found after the instant message server is scanned, a result that the file F1 does not exist is returned to the instant message client, the instant message client sends the file F1 and the file identification IdF1 to the instant message server after receiving the result, and the instant message server stores the file F1 to the file storage server and acquires a download address urlF1 of the file from the file storage server.
Preferably, step S40 includes:
step S42: the instant messaging service stores the download address urlF1, the file identifier IdF1 and the file count value CF1 of the file F1 in a one-to-one correspondence to a file ID mapping table, and generates a new record in the mapping table, wherein the record comprises: four fields of IDF, URLF, CF and MetaF, and a file ID mapping table is obtained: the file ID mapping table is stored in the instant message server.
Preferably, the method comprises the following steps: step S50: the instant message server generates a file message record, wherein the file message record at least comprises: file download address (URLF), file id (idf), and file MetaF; the file MetaF field includes the content of the instant message for that file.
Preferably, step S61: the instant messaging service pushes the file message record recorded in the step S40 to the user A and the user B, the user B downloads the file according to the file download address URL in the file message and renames the file to F2 to store the file to the local, and when the user B selects the file F2 from the local storage by using the instant messaging client and sends the file F2 to the user C, the instant messaging client obtains the unique identifier IdF2 of the file F2;
step S62: the instant message client sends the file identifier IdF2 to the instant message server, the instant message server checks whether the file identifier IdF2 exists in the file ID mapping table described in step S42, and if so, the instant message server returns a response of the existence of the file to the instant message server, and the instant message client notifies the user B that the file uploading is successful.
Preferably, the method comprises the following steps:
step S63: the instant message server obtains the file ID value of the file identifier IdF1 and the corresponding record thereof from the file ID mapping table obtained in step S42, and updates the CF value in the record to 2, and the instant message server generates a file message record, where the file message record includes: the download address URLF of the file, the ID of the file and the MetaF of the file; and the instant message server side pushes the file message record to the user B and the user C.
Another aspect of the present application further provides a file message uploading and storing apparatus as described above, including:
the sending module is used for selecting a local storage file F1 by the user A through the instant message client and sending the local storage file F1 to the user B through the instant message client;
the identification module is used for the instant messaging client to calculate the unique identification IdF1 of the local file F1;
and the scanning module is used for sending the IdF1 to the instant message server by the instant message client, the instant message server scans the stored file identification, if the file with the same identification is found, the file uploading success prompt is returned to the instant message client, and the uploading operation of the instant message client on the file F1 is stopped.
Preferably, the method comprises the following steps:
and the download address acquisition module is used for returning a result that the file F1 does not exist to the instant message client if the same identification file is not found after the instant message server is scanned, sending the file F1 and the file identification IdF1 to the instant message server after the instant message client receives the result, and storing the file F1 in the file storage server and acquiring a download address urlF1 of the file from the file storage server by the instant message server.
Preferably, the method comprises the following steps:
the file mapping table module is used for the instant messaging service to store the download address urlF1, the file identifier IdF1 and the file count value CF1 of the file F1 in a mapping table from the file ID to the instant messaging service according to a one-to-one correspondence, and a new record is generated in the mapping table, wherein the record comprises: four fields of IDF, URLF, CF and MetaF, and a file ID mapping table is obtained: the file ID mapping table is stored in the instant message server.
Preferably, the method comprises the following steps:
the file message recording module is used for the instant message server side to generate a file message record, and the file message record at least comprises: the file downloading address, the ID of the file and the MetaF of the file; the file MetaF field includes the content of the instant message for that file.
The beneficial effects that this application can produce include:
1) according to the file message uploading and storing method, the same file is marked, the file identification is firstly scanned on the message server, and after the file with the consistent file identification is obtained, the prompt of uploading completion is returned, so that the high-speed experience of a user on the file uploading efficiency can be effectively improved, the waiting uploading time of the user is shortened, and the method is particularly suitable for large files which are repeatedly uploaded and downloaded for many times.
2) According to the file message uploading and storing method, the file is mapped and stored through the download address, the identification and the MetaF of the file, when another user uploads the same file, even if the user modifies the file name, the file can be identified through the MetaF and the identification, so that the downloading and uploading experience of the user on the same file is improved, the encroachment of the same file on the internal memory of a server is reduced, and the utilization efficiency of an instant messaging service end is improved.
Drawings
Fig. 1 is a schematic flowchart of a file message uploading and storing method provided by the present application;
FIG. 2 is a schematic block diagram of a file message uploading and storing device provided in the present application;
Detailed Description
The present application will be described in detail with reference to examples, but the present application is not limited to these examples.
Referring to fig. 1, the file message uploading and storing method provided by the present application includes the following steps:
step S10: the user A selects a local storage file F1 by using an instant message client and sends the local storage file F1 to the user B through the instant message client;
step S20: the instant messaging client calculates the unique identification IdF1 of the local file F1;
step S30: the instant message client sends the IdF1 to the instant message server, the instant message server scans the stored file identification, if the file with the same identification is found, the file uploading success prompt is returned to the instant message client, and the uploading operation of the instant message client to the file F1 is stopped;
the operation can realize the quick uploading of the same file, is particularly suitable for the quick uploading of a large file, effectively improves the uploading efficiency, reduces the encroachment of the same file on the memory of the server, and simultaneously ensures the accuracy of file transmission.
Starting from step S30, it is the flow of file upload from the viewpoint of the user a. The instant message client only sends the IdF1 to the instant message server in step 3, and does not carry the file content. If the instant messaging server determines that IdF1 already exists, indicating that a user has uploaded F1 before, it will return the result that the file already exists to the instant messaging client. Subsequently, the instant message client does not upload the file any more, but directly prompts the user A that the file is uploaded successfully. The uploading speed of the file is very high from the perspective of the user A, and particularly when the file is large, the user experience is more obvious.
Preferably, in step S30, after the instant messaging server finds the same file F1, the method further includes the step of returning a prompt that the file F1 to be uploaded already exists to the instant messaging client. The user is prompted according to the method, so that the user can conveniently check the files existing in the instant message server according to actual needs, whether specific contents are modified or not is determined, the uploading accuracy of the same file is improved, and the condition of error transmission is avoided.
Preferably, the method comprises the following steps:
step S40: if the same identification file is not found after the instant message server is scanned, a result that the file F1 does not exist is returned to the instant message client, the instant message client sends the file F1 and the file identification IdF1 to the instant message server after receiving the result, and the instant message server stores the file F1 to the file storage server and acquires a download address urlF1 of the file from the file storage server.
Preferably, step S40 includes:
step S42: the instant messaging service stores the download address urlF1, the file identifier IdF1 and the file count value CF1 of the file F1 in a one-to-one correspondence to a file ID mapping table, and generates a new record in the mapping table, wherein the record comprises: four fields of IDF, URLF, CF and MetaF, and a file ID mapping table is obtained: the file ID mapping table is stored in the instant message server.
The CF1 value is the same file download address save count value, which when saved once, is marked as 1.
Preferably, the IDF field is described as: a unique identifier generated based on the file content, the identifier being related to the file content and independent of the file name;
the content-based file unique identifier may be implemented by computing a file digest. The file summarization algorithm can be obtained by adopting the existing file summarization algorithm, and the existing file summarization algorithm comprises the following steps: MD5, SHA-265, etc.; for example 0ca175b9c0f726a831d895e 269332461;
the URLF field is described as: a download address generated by the file server; for example https:// www.abc.com/f/1001;
the CF field is described as: the file count represents the number of the instant messages related to the file to be uploaded; for example, if the user a and the user B respectively send instant messages of the file F1 having the same content, the CF value is defined as 2;
the MetaF field is described as: the meta information of the file is expressed by JSON and comprises the following steps: file type, file size, picture resolution information;
if the picture or the video is the picture, the resolution information of the picture is also included;
MetaF field example: {
"type": png ",// File type
Size 10234043// File size
Width 1024,// picture width
768 "// Picture height
}
Preferably, the method comprises the following steps: step S50: the instant message server generates a file message record, wherein the file message record at least comprises: file download address (URLF), file id (idf), and file MetaF; the file MetaF field includes the content of the instant message for that file.
The file field included in step S50 corresponds to the field data of each file record in the file ID mapping table in step S42, and is a MetaF field (file meta information), and the MetaF in the file message record includes not only the content of the MetaF field in the file ID mapping table, but also the unique content of the file message, such as the file name.
By generating a plurality of file message records in the file ID mapping table, each file message includes a plain text message and a file message. Common fields for plain text messages and file messages include: message ID, message timestamp, message sender information, message receiver information.
A field unique to the file message is the record field described in step S50. These fields are basically in one-to-one correspondence with the fields in the file ID mapping table in step S42, the only difference being the MetaF field (file meta information), and the MetaF in the file message record includes not only the content of the MetaF field in the file ID mapping table, but also the unique content of the file message, such as the file name. Since although the file contents are the same, the file names may be different. Because a user may download a file in a file message sent by another user to the local, then rename the file and send the file to other users
Sometimes, the contents of the files to be uploaded are the same, but there may be a case that the file names are different, and by setting the step S50, effective distinguishing of the files with the same file contents and different file names can be achieved. The situation that the user downloads the files in the file messages sent by other users to the local, then renames the files and sends the renamed files to other users is avoided, and the confidentiality of the uploaded files is improved.
In step S50, the saved file message record further includes: plain text messages and file messages. Common fields for plain text messages and file messages include: message ID, message timestamp, message sender information, message receiver information, and other information time.
Preferably, the method further comprises the following steps:
step S61: the instant messaging service pushes the file message record recorded in the step S40 to the user A and the user B, the user B downloads the file according to the file download address URL in the file message and renames the file to F2 to store the file to the local, and when the user B selects the file F2 from the local storage by using the instant messaging client and sends the file F2 to the user C, the instant messaging client obtains the unique identifier IdF2 of the file F2;
step S62: the instant message client sends the file identifier IdF2 to the instant message server, the instant message server checks whether the file identifier IdF2 exists in the file ID mapping table described in step S42, and if so, the instant message server returns a response of the existence of the file to the instant message server, and the instant message client notifies the user B that the file uploading is successful.
The step S61 is provided to effectively cope with the case where the local file F2 of the user B and the file F1 of the user a in the step S1 have completely the same contents although the file names are different from each other, and the case where the IdF2 and the file corresponding to the file id IdF1 are equal to each other in this step.
Step S62 shows that although the file name uploaded by user B is different from that uploaded by user a, the unique identifier of the file is calculated, so that the instant messaging server can determine that the file to be uploaded by user B already exists in the file storage server.
The instant message server side returns a response indicating that the file exists, so that the instant message client side of the user B can prompt the user B that the file uploading is successful without uploading the file. The user B can effectively improve the file uploading speed (especially under the scene of uploading large files by using the instant messaging client), so that the user experience is improved; on the other hand, the file memory does not need to store a copy of the file with the same content, which is beneficial to saving the storage space in the file memory and reducing the service cost, and finally, for the files such as the pictures and the videos, the instant messaging service end does not need to repeatedly waste the computing resources so as to compute the unique meta information (such as the resolution information) of the files.
Preferably, the method comprises the following steps:
step S63: the instant message server obtains the file ID value of the file identifier IdF1 and the corresponding record thereof from the file ID mapping table obtained in step S42, and updates the CF value in the record to 2, and the instant message server generates a file message record, where the file message record includes: download address of file (URLF), id of file (idf), and MetaF of file; and the instant message server side pushes the file message record to the user B and the user C.
The step S63 is set, so that F2 can be traced back to an original file F1, and mapping table records corresponding to the file F1 can be adaptively modified, thereby improving tracing accuracy of the same file, improving pipeline and summary reliability of the same type of file, reducing the occurrence of secondary storage and uploading of the same file after the file name is changed, effectively reducing encroachment of the same file on a server memory, simultaneously realizing effective statistics of files with high uploading and downloading frequency, and improving the file monitoring effect.
In one embodiment, the method provided herein comprises the steps of:
step 1: user A selects a local file F1 to send to user B using an instant messaging client
Step 2: the instant messaging client calculates the unique identity IdF1 of the local file F1
And step 3: the instant messaging client sends IdF1 to the instant messaging service.
Description of the drawings: starting from step 3, the process of uploading the file is observed from the perspective of the user a. The instant message client only sends the IdF1 to the instant message server in step 3, and does not carry the file content. If the instant messaging server determines that IdF1 already exists, indicating that a user has uploaded F1 before, it will return the result that the file already exists to the instant messaging client. Subsequently, the instant message client does not upload the file any more, but directly prompts the user A that the file is uploaded successfully. The uploading speed of the file is very high from the perspective of the user A, and particularly when the file is large, the user experience is more obvious. This is the core of the scheme
And 4, step 4: the instant message server detects the absence of IdF1 and returns the result (IdF1 does not exist) to the instant message client
And 5: after the instant message client receives the response, the instant message client sends the file and the IdF1 to the instant message server
Step 6: the instant message server side saves the file to the file storage service and obtains the download address urlF1 of the file from the file storage service
And 7: the instant messaging service maintains a new record in the urlF1, IdF1, and File count CF1(CF1 value is 1) to File ID mapping table, which has four fields: IDF, URLF, CF and MetaF, described below:
Figure BDA0002924256150000081
Figure BDA0002924256150000091
and 8: the instant message server generates a file message record, and the fields related to the file in the record comprise the download address (URLF) of the file, the id (idf) of the file and the MetaF of the file.
Description of the drawings: the message generated by the instant messaging service comprises: plain text messages and file messages. Common fields for plain text messages and file messages include: message ID, message timestamp, message sender information, message receiver information. These general fields above are not the focus of the present invention. The field unique to the file message is the record field described in step 8. These fields are basically in one-to-one correspondence with the fields in the file ID mapping table in step 7, the only difference being the MetaF field (file meta information), and the MetaF in the file message record includes not only the content of the MetaF field in the file ID mapping table, but also the unique content of the file message, such as the file name. Since although the file contents are the same, the file names may be different. Because a user may download a file in a file message sent by another user to the local, then rename the file and send the file to other users
And step 9: the instant message service pushes the file message record to the user A and the user B
Step 10: user B downloads the file according to the file download address URL in the message and renames F2 to save to the local.
Step 11: user B selects file F2 from local storage to send to user C using instant messaging client
Step 12: the instant messaging client calculates the unique identity IdF2 of F2
Description of the drawings: the local file F2 of user B and the file F1 of user A in step 1 are identical in content although their file names are different, and therefore IdF2 and IdF1 in step 2 are identical.
Step 13: instant messaging client sends IdF2 to instant messaging server
Step 14: the instant messaging service checks that IdF2 exists in the file ID mapping table described in step 7
Step 15: the instant message server returns the response of the existing file to the instant message server
Step 16: instant message client informing user B of successful file uploading
Description of the drawings: steps 12 to 16 show that although the file name uploaded by the user B is different from that uploaded by the user a, the instant messaging service end can judge that the file to be uploaded by the user B already exists in the file storage service by calculating the unique identifier of the file. The instant message server side can prompt the user B that the file uploading is successful without uploading the file by returning a response indicating that the file exists. The user feels that the file uploading speed is very high (especially in a large file scene), so that the user experience is greatly improved, on the other hand, the file storage does not need to store copies of files with the same content, the storage space of the files can be saved through masking, the service cost is reduced, and finally, for some picture video files, the service end does not need to repeatedly waste computing resources to compute the unique meta information (such as resolution information) of the picture video files. This is the core of the invention
And step 17: the instant message server side takes out the record of which the IDF value is IDF1 in the file ID mapping table, and updates the record of which the CF value is 2.
Step 18, the instant message server generates a file message record including the download address (URLF) of the file, the id (idf) of the file and the MetaF of the file.
Step 19: and the instant message server side pushes the file message record to the user B and the user C.
Referring to fig. 2, in another aspect, the present application further provides an apparatus for the method as described above, including:
a sending module 10, configured to enable a user a to select a local storage file F1 using an instant messaging client, and send the local storage file F1 to a user B through the instant messaging client;
an identification module 20 for the instant messaging client to calculate a unique identification IdF1 of the local file F1;
and the scanning module 30 is used for the instant message client to send the IdF1 to the instant message server, the instant message server scans the stored file identifier, if the file with the same identifier is found, the file uploading success prompt is returned to the instant message client, and the uploading operation of the instant message client on the file F1 is stopped.
Preferably, the method comprises the following steps:
and the download address acquisition module is used for returning a result that the file F1 does not exist to the instant message client if the same identification file is not found after the instant message server is scanned, sending the file F1 and the file identification IdF1 to the instant message server after the instant message client receives the result, and storing the file F1 in the file storage server and acquiring a download address urlF1 of the file from the file storage server by the instant message server.
Preferably, the method comprises the following steps: the file mapping table module is used for the instant messaging service to store the download address urlF1, the file identifier IdF1 and the file count value CF1 of the file F1 in a mapping table from the file ID to the instant messaging service according to a one-to-one correspondence, and a new record is generated in the mapping table, wherein the record comprises: four fields of IDF, URLF, CF and MetaF, and a file ID mapping table is obtained: the file ID mapping table is stored in the instant message server.
Preferably, the method comprises the following steps: the file message recording module is used for the instant message server side to generate a file message record, and the file message record at least comprises: file download address (URLF), file id (idf), and file MetaF; the file MetaF field includes the content of the instant message for that file.
Preferably, the method comprises the following steps:
a download address obtaining module, configured to push, by the instant messaging service, the file message record recorded in step S40 to user a and user B, where user B downloads a file according to the file download address URL in the file message and renames it as F2 to store it locally, and when user B selects file F2 from the local storage using the instant messaging client and sends it to user C, the instant messaging client obtains the unique identifier IdF2 of file F2;
the file-two-pass module is used for the instant message client to send the file identifier IdF2 to the instant message server, the instant message server checks whether the file identifier IdF2 exists in the file ID mapping table described in the file mapping table module, if so, the instant message server returns a response of the file existence to the instant message server, and the instant message client informs the user B that the file uploading is successful.
Preferably, the method comprises the following steps:
a file information obtaining module, configured to obtain, by the instant message server, a file ID value of the file identifier IdF1 and a record corresponding to the file ID value in the file ID mapping table obtained in the file mapping table module, and update a CF value in the record to be 2, where the instant message server generates a file message record, where the file message record includes: download address of file (URLF), id of file (idf), and MetaF of file; and the instant message server side pushes the file message record to the user B and the user C.
Reference throughout this specification to "one embodiment," "another embodiment," "an embodiment," "a preferred embodiment," or the like, means that a particular feature, structure, or characteristic described in connection with the embodiment is included in at least one embodiment described generally in this application. The appearances of the same phrase in various places in the specification are not necessarily all referring to the same embodiment. Further, when a particular feature, structure, or characteristic is described in connection with any embodiment, it is submitted that it is within the scope of the disclosure to effect such feature, structure, or characteristic in connection with other embodiments.
Although the present application has been described herein with reference to a number of illustrative embodiments thereof, it should be understood that numerous other modifications and embodiments can be devised by those skilled in the art that will fall within the spirit and scope of the principles of this disclosure. More specifically, various variations and modifications are possible in the component parts and/or arrangements of the subject combination arrangement within the scope of the disclosure and claims of this application. In addition to variations and modifications in the component parts and/or arrangements, other uses will also be apparent to those skilled in the art.

Claims (10)

1. A file message uploading and storing method is characterized by comprising the following steps:
step S10: the user A selects a local storage file F1 by using an instant message client and sends the local storage file F1 to the user B through the instant message client;
step S20: the instant messaging client calculates the unique identification IdF1 of the local file F1;
step S30: the instant message client sends the IdF1 to the instant message server, the instant message server scans the stored file identification, if the file with the same identification is found, the file uploading success prompt is returned to the instant message client, and the uploading operation of the instant message client to the file F1 is stopped.
2. The file message uploading and storing method according to claim 1, comprising:
step S40: if the same identification file is not found after the instant message server is scanned, a result that the file F1 does not exist is returned to the instant message client, the instant message client sends the file F1 and the file identification IdF1 to the instant message server after receiving the result, and the instant message server stores the file F1 to the file storage server and acquires a download address urlF1 of the file from the file storage server.
3. The file message uploading and storing method according to claim 2, wherein the step S40 includes:
step S42: the instant messaging service stores the download address urlF1, the file identifier IdF1 and the file count value CF1 of the file F1 in a one-to-one correspondence to a file ID mapping table, and generates a new record in the mapping table, wherein the record comprises: four fields of IDF, URLF, CF and MetaF, and a file ID mapping table is obtained: the file ID mapping table is stored in the instant message server.
4. The file message uploading and storing method according to claim 3, comprising: step S50: the instant message server generates a file message record, wherein the file message record at least comprises: file download address (URLF), file id (idf), and file MetaF; the file MetaF field includes the content of the instant message for that file.
5. The file message uploading and storing method according to claim 4, wherein the step S61: the instant messaging service pushes the file message record recorded in the step S40 to the user A and the user B, the user B downloads the file according to the file download address URL in the file message and renames the file to F2 to store the file to the local, and when the user B selects the file F2 from the local storage by using the instant messaging client and sends the file F2 to the user C, the instant messaging client obtains the unique identifier IdF2 of the file F2;
step S62: the instant message client sends the file identifier IdF2 to the instant message server, the instant message server checks whether the file identifier IdF2 exists in the file ID mapping table described in step S42, and if so, the instant message server returns a response of the existence of the file to the instant message server, and the instant message client notifies the user B that the file uploading is successful.
6. The file message uploading and storing method according to claim 5, comprising:
step S63: the instant message server obtains the file ID value of the file identifier IdF1 and the corresponding record thereof from the file ID mapping table obtained in step S42, and updates the CF value in the record to 2, and the instant message server generates a file message record, where the file message record includes: the download address URLF of the file, the ID of the file and the MetaF of the file; and the instant message server side pushes the file message record to the user B and the user C.
7. A file message upload and storage apparatus as claimed in any one of claims 1 to 6, comprising:
the sending module (10) is used for selecting a local storage file F1 by the user A through an instant messaging client and sending the local storage file F1 to the user B through the instant messaging client;
an identification module (20) for the instant messaging client to calculate a unique identification IdF1 of the local file F1;
and the scanning module (30) is used for sending the IdF1 to the instant message server by the instant message client, the instant message server scans the stored file identification, if the file with the same identification is found, the file uploading success prompt is returned to the instant message client, and the uploading operation of the instant message client on the file F1 is stopped.
8. The file message upload and storage device of claim 7, comprising:
and the download address acquisition module is used for returning a result that the file F1 does not exist to the instant message client if the same identification file is not found after the instant message server is scanned, sending the file F1 and the file identification IdF1 to the instant message server after the instant message client receives the result, and storing the file F1 in the file storage server and acquiring a download address urlF1 of the file from the file storage server by the instant message server.
9. The file message upload and storage device of claim 8, comprising:
the file mapping table module is used for the instant messaging service to store the download address urlF1, the file identifier IdF1 and the file count value CF1 of the file F1 in a mapping table from the file ID to the instant messaging service according to a one-to-one correspondence, and a new record is generated in the mapping table, wherein the record comprises: four fields of IDF, URLF, CF and MetaF, and a file ID mapping table is obtained: the file ID mapping table is stored in the instant message server.
10. The file message upload and storage device of claim 9, comprising:
the file message recording module is used for the instant message server side to generate a file message record, and the file message record at least comprises: the file downloading address, the ID of the file and the MetaF of the file; the file MetaF field includes the content of the instant message for that file.
CN202110126667.6A 2021-01-29 2021-01-29 File message uploading and storing method and device thereof Pending CN112953812A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110126667.6A CN112953812A (en) 2021-01-29 2021-01-29 File message uploading and storing method and device thereof

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110126667.6A CN112953812A (en) 2021-01-29 2021-01-29 File message uploading and storing method and device thereof

Publications (1)

Publication Number Publication Date
CN112953812A true CN112953812A (en) 2021-06-11

Family

ID=76239762

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110126667.6A Pending CN112953812A (en) 2021-01-29 2021-01-29 File message uploading and storing method and device thereof

Country Status (1)

Country Link
CN (1) CN112953812A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113609532A (en) * 2021-08-13 2021-11-05 阳光电源股份有限公司 Data integrity checking method and device, computer equipment and storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102546836A (en) * 2012-03-09 2012-07-04 腾讯科技(深圳)有限公司 Method, terminal, server and system for uploading files
CN102821057A (en) * 2011-06-09 2012-12-12 腾讯科技(深圳)有限公司 File sending method, device and system
CN104123385A (en) * 2014-08-07 2014-10-29 肖龙旭 File storage and management method
CN104156376A (en) * 2013-05-15 2014-11-19 腾讯科技(深圳)有限公司 Storage method, device and server for file
CN107547352A (en) * 2016-06-24 2018-01-05 腾讯科技(深圳)有限公司 Document sending method, apparatus and system

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102821057A (en) * 2011-06-09 2012-12-12 腾讯科技(深圳)有限公司 File sending method, device and system
CN102546836A (en) * 2012-03-09 2012-07-04 腾讯科技(深圳)有限公司 Method, terminal, server and system for uploading files
CN104156376A (en) * 2013-05-15 2014-11-19 腾讯科技(深圳)有限公司 Storage method, device and server for file
CN104123385A (en) * 2014-08-07 2014-10-29 肖龙旭 File storage and management method
CN107547352A (en) * 2016-06-24 2018-01-05 腾讯科技(深圳)有限公司 Document sending method, apparatus and system

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113609532A (en) * 2021-08-13 2021-11-05 阳光电源股份有限公司 Data integrity checking method and device, computer equipment and storage medium
CN113609532B (en) * 2021-08-13 2024-04-12 阳光电源股份有限公司 Data integrity checking method and device, computer equipment and storage medium

Similar Documents

Publication Publication Date Title
US7925615B1 (en) Reducing duplication of files on a network
US10764228B1 (en) Automated message recall from a sender's device
CN108881354B (en) Push information storage method and device, server and computer storage medium
US20090187622A1 (en) Method, system and apparatus for data synchronization
US20140365451A1 (en) Method and system for cleaning up files on a device
US20120293826A1 (en) Systems and methods for providing multiple images
CN103440247A (en) Method and device for sending photos
CN107147945B (en) Multimedia resource playing system, method and device
CN112788126A (en) Resource downloading method, device, server and storage medium
US7328244B1 (en) Electronic mail system
CN111182331B (en) Media data slicing method, system and storage medium
CN112953812A (en) File message uploading and storing method and device thereof
US9106626B2 (en) Method, apparatus and computer program product for copying content between servers
CN103237074A (en) Data interactive method and data interactive system between intelligent terminals
EP2237170A1 (en) Data sorage system
CN107645475B (en) File resource distribution system and method in heterogeneous network
CN112307058A (en) Short link processing method and device, storage medium and computer equipment
CN107241446A (en) Document transmission method, device and the terminal device and storage medium of application program
CN112541143B (en) Asynchronous picture acquisition method and system
CN104580276B (en) Information-pushing method, device, system and information access device
CN114390452B (en) Message sending method and related equipment
CN107040455B (en) Instant message communication method and system based on redis
CN109947380A (en) Display methods, display equipment, server, mobile terminal and display system
CN107104889B (en) Draft mail synchronization method, draft mail synchronization device and draft mail synchronization terminal based on IMAP protocol
CN113254846B (en) Material pushing method and device and electronic equipment

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
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20210611