CN110460668B - File uploading method and device, computer equipment and storage medium - Google Patents

File uploading method and device, computer equipment and storage medium Download PDF

Info

Publication number
CN110460668B
CN110460668B CN201910755333.8A CN201910755333A CN110460668B CN 110460668 B CN110460668 B CN 110460668B CN 201910755333 A CN201910755333 A CN 201910755333A CN 110460668 B CN110460668 B CN 110460668B
Authority
CN
China
Prior art keywords
file
uploaded
path information
target server
files
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201910755333.8A
Other languages
Chinese (zh)
Other versions
CN110460668A (en
Inventor
彭师衍
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen Lexin Software Technology Co Ltd
Original Assignee
Shenzhen Mengtian Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen Mengtian Technology Co ltd filed Critical Shenzhen Mengtian Technology Co ltd
Priority to CN201910755333.8A priority Critical patent/CN110460668B/en
Publication of CN110460668A publication Critical patent/CN110460668A/en
Application granted granted Critical
Publication of CN110460668B publication Critical patent/CN110460668B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/06Protocols specially adapted for file transfer, e.g. file transfer protocol [FTP]

Abstract

The embodiment of the invention discloses a file uploading method and device, computer equipment and a storage medium. The method comprises the following steps: the method comprises the steps of obtaining a file path information list, wherein the file path information list comprises path information of files needing to be uploaded, sending the files needing to be uploaded to a target server according to the path information of the files needing to be uploaded, obtaining the path information of the files uploaded in the server according to preset time, and sending corresponding files to the target server according to the path information of the files needing to be uploaded when the obtained path information of the files needing to be uploaded is more than the path information of the files uploaded. According to the invention, the file to be uploaded which is not uploaded is obtained by automatically comparing the file to be uploaded with the uploaded file, and the automatic uploading of the file is realized, so that the integrity of file uploading can be improved, and the manual maintenance cost of the uploaded file is reduced.

Description

File uploading method and device, computer equipment and storage medium
Technical Field
The embodiment of the invention relates to a data management technology, in particular to a file uploading method, a file uploading device, computer equipment and a storage medium.
Background
The business volume of companies is continuously increased, more and more files need to be transmitted to the partners every day, and the total size of the files is larger and larger. Only a single partner, the amount of contracts, pictures, etc. for a day sometimes reaches the size of a hundred tens of thousands, a dozen G or even tens of G.
In this context, with a common file transmission method, a worker needs to send a file periodically, and search and check a file which is missed to be transmitted periodically, so as to perform supplementary transmission in time.
The common file transmission mode has huge workload, the situation of missed file transmission is easy to occur, technicians are required to periodically search and check the missed file and perform supplementary transmission, and the operation cost is greatly increased.
Disclosure of Invention
The embodiment of the invention provides a file uploading method and device, computer equipment and a storage medium, so as to realize automatic comparison, acquisition and uploading of files.
In a first aspect, an embodiment of the present invention provides a file uploading method, including:
acquiring a file path information list, wherein the file path information list comprises path information of files needing to be uploaded;
according to the path information of the file to be uploaded, sending the file to be uploaded to a target server;
acquiring path information of the uploaded files in the target server according to preset time;
and when the path information of the file to be uploaded is more than that of the uploaded file, sending the corresponding file to the target server according to the path information of the excessive file to be uploaded.
In a second aspect, an embodiment of the present invention further provides a file uploading apparatus, including:
the file path information list acquisition module is used for acquiring a file path information list, wherein the file path information list comprises path information of files needing to be uploaded;
the file sending module is used for sending the file to be uploaded to a target server according to the path information of the file to be uploaded;
the uploaded file path information acquisition module is used for acquiring the uploaded file path information in the target server according to preset time;
and the path information comparison module is used for sending the corresponding file to the target server according to the path information of the excessive file to be uploaded when the path information of the file to be uploaded is more than the path information of the uploaded file.
According to the embodiment of the invention, the path information of the file to be uploaded is compared with the path information of the uploaded file according to the preset time, the path information of the file which is not uploaded and needs to be uploaded is obtained, and the corresponding file which needs to be uploaded is sent, so that the problems that the file which needs to be uploaded needs to be checked regularly and is subjected to re-transmission in time in the prior art are solved, the effect of automatically comparing to obtain the file which needs to be uploaded and automatically uploading the file is realized, the manual operation cost is greatly reduced, and the efficiency and the integrity of file transmission are improved.
Drawings
Fig. 1 is a flowchart of a file uploading method in a first embodiment of the present invention;
fig. 2 is a flowchart of a file uploading method in a second embodiment of the present invention;
fig. 3 is a schematic structural diagram of a file uploading apparatus in a third embodiment of the present invention;
fig. 4 is a schematic structural diagram of a computer device in the fourth embodiment of the present invention.
Detailed Description
The present invention will be described in further detail with reference to the accompanying drawings and examples. It is to be understood that the specific embodiments described herein are merely illustrative of the invention and are not limiting of the invention. It should be further noted that, for the convenience of description, only some of the structures related to the present invention are shown in the drawings, not all of the structures.
Example one
Fig. 1 is a flowchart of a file uploading method according to an embodiment of the present invention, where this embodiment is applicable to a case where a company and a partner automatically send contract files on time, and the method may be executed by a file uploading device, where the device may be implemented by hardware and/or software, and the method specifically includes the following steps:
s110, acquiring a file path information list, wherein the file path information list comprises path information of files needing to be uploaded;
the file information path list is preset in a database of the client and comprises a plurality of file paths, and the files in the database can be positioned according to each file path. The so-called file path is the folder line that is traversed when a file is found in the database of the client. For example, "C: \ windows \ system32\ cmd. Specifically, the file path is divided into an absolute path and a relative path, the absolute path is a path from the root folder with "\" as a start, and the relative path is a path from the current folder.
Optionally, before the file path information list is obtained, the path information of the file to be uploaded in the file path information list is configured according to the input of the user. Specifically, a user input interface and a file path information list can be preset at the client, the user input interface is provided with a file path searching function, and file path information input by the user input interface is acquired and then stored in the file path information list.
S120, sending the file to be uploaded to a target server according to the path information of the file to be uploaded;
according to the path information of the files needing to be uploaded in the acquired file path information list, the files needing to be uploaded in the database can be directly located, and the files needing to be uploaded are sent to the target server. Specifically, a folder with the same name as the folder on the client can be created on the target server according to the path information of the file to be uploaded, and the folder can be directly uploaded to the server on the client.
S130, acquiring path information of the uploaded files in the target server according to preset time;
the preset time is set by a user at the client and can be changed at any time. For example, the file may be compared and transmitted every other day, or the file may be compared and transmitted on a certain day or a certain number of days.
Since the folder with the same name as the client can be directly created in the target server in S120, the path information of the uploaded file in the server can be directly acquired.
And S140, when the path information of the file to be uploaded is more than that of the uploaded file, sending the corresponding file to a target server according to the path information of the excessive file to be uploaded.
After the path information of the uploaded file in the target server is obtained in S130, whether the path information of the file to be uploaded in the preset time period is greater than the obtained path information of the uploaded file may be determined by comparing the path information of the file to be uploaded in the preset time period with the obtained path information of the uploaded file, and then according to the comparison result. When the path information of the file that needs to be uploaded is more than the acquired path information of the uploaded file, the operation of S140 is performed.
According to the technical scheme, the path information of the uploaded files and the path information to be uploaded are obtained respectively and compared, when the path information to be uploaded is more than the path information of the uploaded files, the corresponding files are obtained according to the excess path information, and reissue is carried out on the files, so that the problems of manual rechecking, tedious reissue files and time consumption are solved, the effects of automatic comparison, acquisition of the files to be uploaded and automatic reissue of the files to be uploaded are achieved, the manual operation cost is reduced, and the efficiency and the integrity of file transmission are improved.
Example two
Fig. 2 is a flowchart of a file uploading method provided in the second embodiment of the present invention, which is further detailed based on the foregoing technical solution in the present embodiment, and the method includes:
s210, a file path information list is obtained, wherein the file path information list comprises path information of files needing to be uploaded.
S220, configuring a corresponding connection relation between the secure transport protocol (SFTP) software and the target server.
And S230, establishing connection with the target server through SFTP software.
Wherein, SFTP is an abbreviation of SSH File Transfer Protocol, secure transport Protocol. A secure network encryption method may be provided for transferring files. SFTP is part of SSH, and has no separate daemon per se, and the SFTP has to use sshd daemon to complete corresponding connection and reply operations, and is very safe to use.
And S240, sending the file to be uploaded to the target server according to the path information of the file to be uploaded.
And S250, acquiring the path information of the uploaded file in the target server according to preset time.
And S260, when the path information of the file to be uploaded is more than that of the uploaded file, sending the corresponding file to a target server according to the path information of the excessive file to be uploaded.
In the embodiment, the user configures the corresponding connection relationship between the SFTP software and the target server, the SFTP software establishes connection with the target server at regular time, and the file to be sent is sent to the target server at regular time, so that the automatic sending of the file can be realized, and the sending efficiency of the file is improved.
EXAMPLE III
Fig. 3 is a schematic structural diagram of a file uploading apparatus provided in a third embodiment of the present invention, where the file uploading apparatus includes:
a file path information list obtaining module 310, configured to obtain a file path information list, where the file path information list includes path information of a file to be uploaded;
the file sending module 320 is configured to send the file to be uploaded to the target server according to the path information of the file to be uploaded;
the uploaded file path information acquiring module 330 is configured to acquire path information of an uploaded file in a target server according to preset time;
and the path information comparison module 340 is configured to, when the path information of the file to be uploaded is greater than the path information of the uploaded file, send the corresponding file to the target server according to the path information of the excessive file to be uploaded.
Optionally, the file uploading apparatus further includes:
and the path information configuration module is used for configuring the path information of the file to be uploaded in the file path information list according to the input of a user before the file path information list is acquired.
Optionally, the file uploading apparatus further includes:
and the connection establishing module is used for establishing connection with the target server through preset secure transport protocol (SFTP) software before sending the file to be uploaded to the target server according to the path information of the file to be uploaded.
Optionally, the file uploading apparatus further includes:
and the connection relation configuration module is used for configuring the corresponding connection relation between the SFTP software and the target server before the connection is established between the SFTP software and the target server through the preset secure transport protocol (SFTP).
Optionally, the path information comparing module 340 is specifically configured to:
comparing the path information of the file to be uploaded in a preset time period with the path information of the uploaded file;
and determining whether the path information of the file needing to be uploaded in the preset time period is more than the path information of the uploaded file or not according to the comparison result.
According to the technical scheme, the problems that files are easy to miss and the operation cost is increased due to the fact that files needing to be uploaded need to be manually rechecked and reissued regularly under the condition that a company and a partner need to send a large number of contract files on time are solved. The device can realize the regular automatic comparison and reissue of the files only by configuring the connection between the SFTP software and the server and selecting the file path to be uploaded by a user, thereby reducing the manual operation cost and improving the efficiency and the integrity of file transmission.
The file uploading device provided by the embodiment of the invention can execute the file uploading method provided by any embodiment of the invention, and has the corresponding functional modules and beneficial effects of executing the file uploading method.
Example four
Fig. 4 is a schematic structural diagram of a computer apparatus according to a fourth embodiment of the present invention, as shown in fig. 4, the computer apparatus includes a processor 410, a memory 420, an input device 430, and an output device 440; the number of the processors 410 in the computer device may be one or more, and one processor 410 is taken as an example in fig. 4; the processor 410, the memory 420, the input device 430 and the output device 440 in the computer apparatus may be connected by a bus or other means, and the connection by the bus is exemplified in fig. 4.
The memory 420 is used as a computer-readable storage medium, and can be used for storing software programs, computer-executable programs, and modules, such as program instructions/modules corresponding to the file uploading method in the embodiment of the present invention (for example, the file path information list obtaining module 310, the file sending module 320, the uploaded file path information obtaining module 330, and the path information comparing module 340). The processor 410 executes various functional applications and data processing of the computer device by executing software programs, instructions and modules stored in the memory 420, that is, implements the above-described file uploading method.
The memory 420 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application program required for at least one function; the storage data area may store data created according to the use of the terminal, and the like. Further, the memory 420 may include high speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other non-volatile solid state storage device. In some examples, memory 420 may further include memory located remotely from processor 410, which may be connected to a computer device through a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
The input means 430 may be used to receive input numeric or character information and to generate key signal inputs related to user settings and function controls of the computer device. The output device 440 may include a display device such as a display screen.
EXAMPLE five
An embodiment of the present invention further provides a storage medium containing computer-executable instructions, where the computer-executable instructions are executed by a computer processor to perform a file uploading method, and the method includes:
acquiring a file path information list, wherein the file path information list comprises path information of files needing to be uploaded;
according to the path information of the files needing to be uploaded, the files needing to be uploaded are sent to a target server;
acquiring path information of the uploaded files in the target server according to preset time;
and when the path information of the file to be uploaded is more than that of the uploaded file, sending the corresponding file to the target server according to the path information of the excessive file to be uploaded.
Of course, the storage medium provided by the embodiment of the present invention contains computer-executable instructions, and the computer-executable instructions are not limited to the operations of the method described above, and may also perform related operations in the file uploading method provided by any embodiment of the present invention.
From the above description of the embodiments, it is obvious for those skilled in the art that the present invention can be implemented by software and necessary general hardware, and certainly, can also be implemented by hardware, but the former is a better embodiment in many cases. Based on such understanding, the technical solutions of the present invention or portions thereof contributing to the prior art may be embodied in the form of a software product, which can be stored in a computer readable storage medium, such as a floppy disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a FLASH Memory (FLASH), a hard disk or an optical disk of a computer, and includes several instructions for enabling a computer device (which may be a personal computer, a server, or a network device) to execute the methods according to the embodiments of the present invention.
It should be noted that, in the embodiment of the file uploading apparatus, each included unit and each included module are only divided according to functional logic, but are not limited to the above division as long as the corresponding function can be realized; in addition, specific names of the functional units are only for convenience of distinguishing from each other, and are not used for limiting the protection scope of the present invention.
It is to be noted that the foregoing description is only exemplary of the invention and that the principles of the technology may be employed. Those skilled in the art will appreciate that the present invention is not limited to the particular embodiments described herein, and that various obvious changes, rearrangements and substitutions will now be apparent to those skilled in the art without departing from the scope of the invention. Therefore, although the present invention has been described in greater detail by the above embodiments, the present invention is not limited to the above embodiments, and may include other equivalent embodiments without departing from the spirit of the present invention, and the scope of the present invention is determined by the scope of the appended claims.

Claims (8)

1. A file uploading method is characterized by comprising the following steps:
acquiring a file path information list, wherein the file path information list comprises path information of files needing to be uploaded;
according to the path information of the file to be uploaded, sending the file to be uploaded to a target server;
acquiring path information of the uploaded files in the target server according to preset time;
the path information of the uploaded files is obtained after the target server creates a folder with the same name as the folder on the client according to the path information of the files needing to be uploaded;
comparing the path information of the file to be uploaded in a preset time period with the path information of the uploaded file;
determining whether the path information of the file needing to be uploaded in the preset time period is more than the path information of the uploaded file or not according to a comparison result;
and when the path information of the file to be uploaded is more than the path information of the uploaded file, sending the corresponding file to the target server according to the path information of the file to be uploaded which is more than the path information of the uploaded file.
2. The file uploading method according to claim 1, further comprising, before the obtaining the file path information list:
and configuring the path information of the files needing to be uploaded in the file path information list according to the input of a user.
3. The file uploading method according to claim 1, wherein before sending the file to be uploaded to a target server according to the path information of the file to be uploaded, the method further comprises:
and establishing connection with the target server through the preset secure transport protocol (SFTP) software.
4. The file uploading method according to claim 3, further comprising, before the establishing a connection with the target server through a preset secure transport protocol (SFTP) software:
and configuring the corresponding connection relation between the SFTP software and the target server.
5. A file uploading apparatus, comprising:
the file path information list acquisition module is used for acquiring a file path information list, wherein the file path information list comprises path information of files needing to be uploaded;
the file sending module is used for sending the file to be uploaded to a target server according to the path information of the file to be uploaded;
the uploaded file path information acquisition module is used for acquiring the uploaded file path information in the target server according to preset time;
the path information of the uploaded files is obtained after the target server creates a folder with the same name as the folder on the client according to the path information of the files needing to be uploaded;
the path information comparison module is used for sending the corresponding file to the target server according to the path information of the excessive file to be uploaded when the path information of the file to be uploaded is more than the path information of the uploaded file;
the path information comparison module is specifically configured to:
comparing the path information of the file to be uploaded in a preset time period with the path information of the uploaded file;
and determining whether the path information of the file needing to be uploaded in the preset time period is more than the path information of the uploaded file or not according to the comparison result.
6. The document uploading apparatus according to claim 5, further comprising:
and the connection establishing module is used for establishing connection with a target server through a preset secure transport protocol (SFTP) software before the file to be uploaded is sent to the target server according to the path information of the file to be uploaded.
7. A computer device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, wherein the processor implements the file upload method of any of claims 1 to 4 when executing the program.
8. A storage medium containing computer-executable instructions for performing the file upload method of any of claims 1-4 when executed by a computer processor.
CN201910755333.8A 2019-08-15 2019-08-15 File uploading method and device, computer equipment and storage medium Active CN110460668B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910755333.8A CN110460668B (en) 2019-08-15 2019-08-15 File uploading method and device, computer equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910755333.8A CN110460668B (en) 2019-08-15 2019-08-15 File uploading method and device, computer equipment and storage medium

Publications (2)

Publication Number Publication Date
CN110460668A CN110460668A (en) 2019-11-15
CN110460668B true CN110460668B (en) 2022-09-13

Family

ID=68486926

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910755333.8A Active CN110460668B (en) 2019-08-15 2019-08-15 File uploading method and device, computer equipment and storage medium

Country Status (1)

Country Link
CN (1) CN110460668B (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111352904B (en) * 2020-03-04 2023-05-05 海南金盘智能科技股份有限公司 Method and device for replacing model file
CN111563210A (en) * 2020-03-18 2020-08-21 深圳点猫科技有限公司 Method and device for exporting curriculum resources after archiving
CN114024955B (en) * 2021-11-01 2024-03-12 北京来也网络科技有限公司 File processing method, device, equipment and medium based on RPA and AI

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108156238A (en) * 2017-12-23 2018-06-12 贵阳朗玛信息技术股份有限公司 The method and device that a kind of data automation uploads
CN109376126A (en) * 2018-09-26 2019-02-22 Oppo广东移动通信有限公司 A kind of file or folder processing method, mobile terminal and storage medium

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9613047B2 (en) * 2013-02-13 2017-04-04 Dropbox, Inc. Automatic content item upload
CN103281362B (en) * 2013-05-14 2016-09-14 周信兰 A kind of file transfer protocol (FTP)
CN104883404B (en) * 2015-06-04 2017-05-24 上海斐讯数据通信技术有限公司 Network based file cloud synchronization method
CN105868401A (en) * 2016-04-19 2016-08-17 乐视控股(北京)有限公司 Image management method for terminal equipment and terminal device
CN109391694B (en) * 2018-10-26 2022-07-26 深圳壹账通智能科技有限公司 SFTP-based file transmission method and related equipment

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108156238A (en) * 2017-12-23 2018-06-12 贵阳朗玛信息技术股份有限公司 The method and device that a kind of data automation uploads
CN109376126A (en) * 2018-09-26 2019-02-22 Oppo广东移动通信有限公司 A kind of file or folder processing method, mobile terminal and storage medium

Also Published As

Publication number Publication date
CN110460668A (en) 2019-11-15

Similar Documents

Publication Publication Date Title
US10949253B2 (en) Data forwarder for distributed data acquisition, indexing and search system
CN109040252B (en) File transmission method, system, computer device and storage medium
CN110460668B (en) File uploading method and device, computer equipment and storage medium
US20150237113A1 (en) Method and system for file transmission
CN110995513B (en) Data sending and receiving method in Internet of things system, internet of things equipment and platform
CN107800565B (en) Inspection method, inspection device, inspection system, computer equipment and storage medium
EP2985707A1 (en) Method and apparatus for finding file in storage device and router and medium
CN104378234A (en) Cross-data-center data transmission processing method and system
CN107347062A (en) A kind of method, electronic equipment and the readable storage medium storing program for executing of daily record data processing
CN104283723A (en) Network access log processing method and device
CN109361525B (en) Method, device, control terminal and medium for restarting distributed deployment of multiple services
CN109101664B (en) Data transmission method, device, equipment and medium for lightweight node
US11502899B2 (en) Dynamic product installation based on user feedback
CN103905495A (en) Application synchronization method and backstage server
CN103744699A (en) Method and device for software upgrading of intelligent electric equipment
CN106034113A (en) Data processing method and data processing device
CN104079623A (en) Method and system for controlling multilevel cloud storage synchrony
US20140156809A1 (en) Data downloading method, terminal, server, and system
CN106302641B (en) A kind of methods, devices and systems of upper transmitting file
CN109788034B (en) Configuration method for gateway access equipment, electronic equipment and storage medium
CN110990360A (en) File synchronization method based on network storage device and related components
CN103220327B (en) user information storage method and device
KR20210000041A (en) Method and apparatus for analyzing log data in real time
CN112559546B (en) Database synchronization method, database synchronization device, computer equipment and readable storage medium
US20150229701A1 (en) Sending files with multiple job sessions

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
TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20230410

Address after: Floor 24, China energy storage building, 3099 Keyuan South Road, Yuehai street, Nanshan District, Shenzhen, Guangdong 518000

Patentee after: SHENZHEN LEXIN SOFTWARE TECHNOLOGY Co.,Ltd.

Address before: 23 / F, China energy storage building, 3099 Keyuan South Road, Yuehai street, Nanshan District, Shenzhen, Guangdong 518000

Patentee before: SHENZHEN MENGTIAN TECHNOLOGY Co.,Ltd.