CN117435229A - File version updating method, system, device and storage medium - Google Patents

File version updating method, system, device and storage medium Download PDF

Info

Publication number
CN117435229A
CN117435229A CN202311281227.3A CN202311281227A CN117435229A CN 117435229 A CN117435229 A CN 117435229A CN 202311281227 A CN202311281227 A CN 202311281227A CN 117435229 A CN117435229 A CN 117435229A
Authority
CN
China
Prior art keywords
file
version
file information
local cache
target
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
CN202311281227.3A
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.)
Lianyou Zhilian Technology Co ltd
Original Assignee
Lianyou Zhilian 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 Lianyou Zhilian Technology Co ltd filed Critical Lianyou Zhilian Technology Co ltd
Priority to CN202311281227.3A priority Critical patent/CN117435229A/en
Publication of CN117435229A publication Critical patent/CN117435229A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/65Updates
    • G06F8/658Incremental updates; Differential updates
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/11File system administration, e.g. details of archiving or snapshots
    • G06F16/122File system administration, e.g. details of archiving or snapshots using management policies
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/17Details of further file system functions
    • G06F16/172Caching, prefetching or hoarding of files
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/18File system types
    • G06F16/1873Versioning file systems, temporal file systems, e.g. file system supporting different historic versions of files
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/70Software maintenance or management
    • G06F8/71Version control; Configuration management

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Software Systems (AREA)
  • Data Mining & Analysis (AREA)
  • Databases & Information Systems (AREA)
  • Computer Security & Cryptography (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The invention discloses a method, a system, a device and a storage medium for updating a version of a file. The method comprises the following steps: acquiring local cache file information; matching the local cache file information with the target file information through a network request; storing the target file information in a file server; if the local cache file information and the target file information are not successfully matched, and the local cache file information meets the condition of an incremental updating mechanism, receiving a differential packet; the incremental update mechanism condition is used for representing the version and the security condition which are required to be met by the local cache file; and carrying out patch combination processing on the local cache file and the differential packet to generate a target version file, and carrying out version updating on the file according to the target version file. The embodiment of the application saves flow consumption, transmission time and resource occupation by receiving and installing the differential packets, improves the efficiency of updating the file version, and can be widely applied to the technical field of file version management.

Description

File version updating method, system, device and storage medium
Technical Field
The invention relates to the technical field of file version management, in particular to a method, a system, a device and a storage medium for updating a version of a file.
Background
Along with the rapid development of mobile applications, the application fields of the mobile applications are wider and wider, the requirements of most enterprises on the mobile applications are larger and larger, the related links and functions are richer and richer, and the size of installation packages is increased continuously. The application software has an increasing demand for server resources in the updating process; at the same time, a great deal of traffic and time is consumed for file downloading. In the related technology, the version of the software file is updated in a direct downloading or full updating mode, so that the problems of large resource occupation, time consumption and flow consumption are easily generated.
Disclosure of Invention
The present invention aims to solve at least one of the technical problems existing in the prior art to a certain extent.
The invention aims to provide a method, a system, a device and a storage medium for updating the version of a file with time and resource saving.
In order to achieve the technical purpose, the technical scheme adopted by the embodiment of the invention comprises the following steps:
in one aspect, an embodiment of the present invention provides a method for updating a version of a file, including the following steps:
the version updating method of the file in the embodiment of the invention comprises the following steps: acquiring local cache file information; matching the local cache file information with target file information through a network request; the target file information is stored in a file server; if the local cache file information and the target file information are not successfully matched, and the local cache file information meets the condition of an incremental updating mechanism, receiving a differential packet; the increment updating mechanism condition is used for representing the version and the security condition to be met by the local cache file, and the differential packet is generated by the file management platform according to the local cache file information and the target file information; and carrying out patch combination processing on the local cache file and the differential packet to generate a target version file, and carrying out version updating on the file according to the target version file. According to the embodiment of the application, the local cache file information is matched with the target file information in the file server, and if the local cache file information is not successfully matched with the target file information, the version of the local file can be updated in a differential mode. The differential packet is a differential patch file between the local cache file information and the target file information, and through receiving and installing the differential packet, the flow consumption is saved, the transmission time and the resource occupation are also saved, and the file version updating efficiency is improved.
In addition, the version updating method of the file according to the above embodiment of the present invention may further have the following additional technical features:
further, the method for updating the version of the file according to the embodiment of the invention further comprises the following steps:
establishing a version updating frame, wherein the version updating frame comprises a file management platform, a file server and a terminal container;
the file management platform is used for acquiring and recording the version of the file; the file management platform is also used for generating differential packets according to the local cache file information and the target file information and issuing the differential packets;
the file server is used for storing the target file information and the differential packet;
the terminal container is used for receiving the differential packet, and the terminal container is also used for updating the version of the file.
Further, in one embodiment of the present invention, the receiving differential packet includes:
if the target temporary file exists locally, acquiring a first data length of the local target temporary file; the differential package comprises the target temporary file;
and downloading the target temporary file from the first data length, and placing the target temporary file into the differential packet.
Further, in one embodiment of the present invention, the method further comprises the steps of:
if the local cache file information does not pass the file security check, deleting the local cache file information;
or if the received differential packet does not pass the file security check, deleting the differential packet.
Further, in an embodiment of the present invention, if the local cache file information and the target file information are not successfully matched, and the local cache file information satisfies an incremental update mechanism condition, receiving a differential packet includes:
if the local cache file information and the target file information are not successfully matched, and the local cache file information and the reference packet are successfully matched, receiving a differential packet; the reference package is used for representing files with versions before the versions of the target files; the differential package is a differential patch file between the reference package and the target file information.
Further, in one embodiment of the present invention, the method further comprises:
if the local cache file information and the target file information are not successfully matched, and the local cache file information and the reference packet are not successfully matched, receiving a full-volume packet; the full package is stored in a file server, and the full package comprises the target file information;
or if the local cache file information and the target file information are successfully matched, updating the version of the file according to the local cache file.
Further, in one embodiment of the present invention, the method further comprises:
if the local cache file information and the target file information are not successfully matched, and the local cache file information and the reference packet are successfully matched, the version number between the reference packet and the target file information is obtained;
and determining a second number of differential packets to be received according to the version number, wherein the second number is equal to the version number.
On the other hand, the embodiment of the invention provides a version updating system of a file, which comprises the following steps:
the first module is used for acquiring the local cache file information;
the second module is used for matching the local cache file information with the target file information through a network request; the target file information is stored in a file server; the version of the target file information is the latest version;
a third module, configured to receive a differential packet if the local cache file information and the target file information are not successfully matched, and the local cache file information meets an incremental update mechanism condition; the increment updating mechanism condition is used for representing the version and the security condition to be met by the local cache file, and the differential packet is generated by the file management platform according to the local cache file information and the target file information;
and a fourth module, configured to perform patch combination processing on the local cache file and the differential packet, generate a target version file, and perform version update on the file according to the target version file.
On the other hand, the embodiment of the invention provides a version updating device of a file, which comprises the following steps:
at least one processor;
at least one memory for storing at least one program;
the at least one program, when executed by the at least one processor, causes the at least one processor to implement the version updating method of the file described above.
In another aspect, an embodiment of the present invention provides a storage medium in which a processor-executable program is stored, where the processor-executable program is configured to implement the above-described version updating method of a file when executed by a processor.
According to the embodiment of the application, the local cache file information is matched with the target file information in the file server, and if the local cache file information is not successfully matched with the target file information, the version of the local file can be updated in a differential mode. The differential packet is a differential patch file between the local cache file information and the target file information, and through receiving and installing the differential packet, the flow consumption is saved, the transmission time and the resource occupation are also saved, and the file version updating efficiency is improved.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the following description is made with reference to the accompanying drawings of the embodiments of the present invention or the related technical solutions in the prior art, and it should be understood that the drawings in the following description are only for convenience and clarity of describing some embodiments in the technical solutions of the present invention, and other drawings may be obtained according to these drawings without the need of inventive labor for those skilled in the art.
FIG. 1 is a flowchart illustrating an embodiment of a method for updating a version of a file according to the present invention;
FIG. 2 is a flowchart illustrating another embodiment of a method for updating a version of a file according to the present invention;
FIG. 3 is a flow chart illustrating an embodiment of a differential packet based update process according to the present invention;
FIG. 4 is a schematic diagram illustrating an embodiment of a version update framework according to the present invention;
FIG. 5 is a schematic flow chart of an embodiment of a downloading process of a target temporary file according to the present invention;
FIG. 6 is a flow chart illustrating an embodiment of a security verification process for a file according to the present invention;
FIG. 7 is a schematic diagram illustrating an embodiment of a version updating system of a file according to the present invention;
fig. 8 is a schematic structural diagram of an embodiment of a device for updating a version of a file according to the present invention.
Detailed Description
Embodiments of the present invention are described in detail below, examples of which are illustrated in the accompanying drawings, wherein like or similar reference numerals refer to like or similar elements or elements having like or similar functions throughout. The embodiments described below by referring to the drawings are illustrative only and are not to be construed as limiting the invention. The step numbers in the following embodiments are set for convenience of illustration only, and the order between the steps is not limited in any way, and the execution order of the steps in the embodiments may be adaptively adjusted according to the understanding of those skilled in the art.
First, terms related to the embodiments of the present application will be explained, specifically:
breakpoint continuous downloading: in the downloading process of large files, most of downloaded software uses breakpoint downloading technology, and the principle is that: and fragmenting the file, marking the fragmented file, then downloading the fragmented file, reorganizing the data stream after the downloading is completed, and writing the data stream into the local file.
Differential packet: and comparing the reference package (original file) with the modified latest file through a difference algorithm (bsdiff algorithm) to obtain a differential patch file.
Patch combination: patch combining is a process of combining file differential packets and reference packets by a differential algorithm (bspatich algorithm).
Incremental update: incremental update refers to that when an update operation is performed, only the place needing to be changed is updated, and the updated update is not repeated. The principle is that a place with a new version different from an old version is found out through a difference algorithm, then the place which is different is extracted to form an update patch, when a client detects the update, only a difference packet is downloaded to the local, and then the difference packet is combined into a local original file packet to form a new file packet, so that the effect of quick update is achieved.
Reference package: for example, the file a is modified to obtain the file B, and then the file a is the reference package of the file B.
Full update: the full-volume update refers to that when the update operation is performed, the whole complete file package needs to be downloaded and then subjected to the overlay update.
Along with the rapid development of mobile applications, the related fields are wide, the requirements of most enterprises on the mobile applications are larger and larger, the related links and functions are more and more, the size of an apk installation package is continuously increased, the pressure on server resources is more and more increased in the APP updating process, the loss of flow in the user downloading process is also continuously increased, the user downloading and updating time is also influenced, and unfriendly user embodiment is caused. Meanwhile, in the business demands of the day and month, the rapid iteration modes of small programs, offline packages and the like are also induced, but the modes also need to depend on the downloading and updating functions.
Therefore, the following disadvantages exist in the conventional update method: for direct downloading, the downloading process of the user must be carried out once, such as the common scenes of network abnormality, network jitter, active exit of the user and the like, which occur in the downloading process, and the downloading is interrupted, so that the downloading needs to be restarted from zero. This is very wasteful of server resources and traffic and also very affects the user experience. Version updating method of full update: the complete file package needs to be downloaded, so that the server pressure is increased, the server resources are occupied greatly, the downloading flow of a user is increased, the waiting time of the user for downloading is prolonged, and the like. The single download updating mode, the traditional downloading mode, does not have the concepts of multi-file and multi-version management, and the single download can not meet the requirement in the business scenes such as small programs, offline packages and the like.
The main disadvantages of many existing downloading technologies are basically concentrated on: the server resources are large in occupied amount, the traffic is large in use, the downloading time is too long or breakpoint downloading cannot be used, or file downloading does not carry out safety check, file tampering is prevented, multi-file and multi-version management cannot be carried out, and the like. The file downloading and updating system aims to solve the defects. Based on the above technical background and user experience requirements, there are some ways of single increment update, single breakpoint download and the like at present, but it is difficult to better meet the above requirements at the same time.
The method and system for updating a version of a file according to an embodiment of the present invention will be described in detail with reference to the accompanying drawings, and first, the method for updating a version of a file according to an embodiment of the present invention will be described with reference to the accompanying drawings.
Referring to fig. 1, a method for updating a version of a file is provided in an embodiment of the present invention, and the method for updating a version of a file in an embodiment of the present invention may be applied to a terminal, a server, software running in a terminal or a server, and the like. The terminal may be, but is not limited to, a tablet computer, a notebook computer, a desktop computer, etc. The server may be an independent physical server, a server cluster or a distributed system formed by a plurality of physical servers, or a cloud server providing cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, CDNs, basic cloud computing services such as big data and artificial intelligent platforms. The version updating method of the file in the embodiment of the invention mainly comprises the following steps:
s100: acquiring local cache file information;
s200: matching the local cache file information with the target file information through a network request; storing the target file information in a file server; the version of the target file information is the latest version;
s300: if the local cache file information and the target file information are not successfully matched, and the local cache file information meets the condition of an incremental updating mechanism, receiving a differential packet; the incremental updating mechanism condition is used for representing the version and the security condition to be met by the local cache file, and the differential packet is generated by the file management platform according to the local cache file information and the target file information;
s400: and carrying out patch combination processing on the local cache file and the differential packet to generate a target version file, and carrying out version updating on the file according to the target version file.
In some possible implementations, to reduce resource consumption and waste during downloading, the embodiments of the present application introduce a design scheme of incremental update. Referring to fig. 2, by comparing the local version cache (i.e., the local cache file) with the target file information through network matching, it is checked whether the two are identical. If the files are consistent, the local version cache can be used for updating the files. If not, the updated portion (i.e., differential packet) of the target file information is used for version updating of the file.
In some possible implementations, referring to fig. 3, the file management platform uses a full-volume packet a (reference packet) and a full-volume packet B, and generates a differential packet B1 in cooperation with a differential algorithm, an APP container obtains the differential packet B1 in a file server through a network, and then combines the differential packet B with the full-volume packet a (reference packet) locally cached by the APP container, and cooperates with the differential algorithm to form the full-volume packet B, so as to implement iterative update of the file. The problem that the whole file must be completely downloaded and the local version coverage iteration is carried out in the file updating iteration process is avoided. This can greatly reduce the amount of resources occupied and the stress on the server. Specifically: the APP container can read the local version cache information first, and performs file matching with the file server through the network request, whether the file needs to be updated or not, and if the version of the APP container is consistent with the version of the file server file, the APP container can be directly used for locally caching the file. If the file server is inconsistent with the local file version, the file server can judge whether the use increment updating condition (version and safety check) is met according to the local version cache information of the APP container, and if the use increment updating condition is not met, the APP container is required to download the full package again for use. If the increment updating mechanism condition is met, the file server can issue differential packets according to the version information of the APP local cache. After the App container downloads the differential packet, the App container performs patch combination and splicing with the reference packet of the corresponding version locally cached by the App container through a differential algorithm to perform version iterative updating.
It can be seen from this: the buffer mechanism occupies an important position in the embodiment of the invention, and the buffer mechanism needs to be used throughout the whole process of downloading the file to the patch combination. The method is a bridge of the functions, and records all file version information, file downloading cache information, file foundation packages and the like, wherein the information carries the foundation conditions of functions such as downloading update, incremental update, security check, version management and the like.
The invention is directed to a multi-file management download update function which can cope with multi-file and multi-version management mechanisms. The file creates a unique item ID when the file management platform is first uploaded. Based on this item ID, file discrimination management is performed. And each item ID may be assigned to a different version of the file. Thus, multi-file and multi-version management can be realized. The file updating and downloading function is more flexible and practical. Based on the application engineering frameworks such as the applet frameworks, the offline package frameworks and the like developed by the application platform of the mobile terminal, the multi-file and multi-version management downloading and updating applet package/offline package functions are needed. The invention can provide the mobile phone terminal application framework with the function of quickly accessing the file downloading update version management, and once accessed, the mobile phone terminal application framework directly has a whole set of multi-file downloading update capability for multi-version management without any judgment processing of a user.
Optionally, in one embodiment of the present invention, the method further comprises:
establishing a version updating frame, wherein the version updating frame comprises a file management platform, a file server and a terminal container;
the file management platform is used for acquiring and recording the version of the file; the file management platform is also used for generating differential packets according to the local cache file information and the target file information and issuing the differential packets;
the file server is used for storing target file information and differential packets;
the terminal container is used for receiving the differential packets and is also used for updating the version of the file.
In some possible embodiments, in order to meet the urgent needs in the current technical background, the overall technical architecture of the present invention is shown in fig. 4, and is generally divided into three layers, namely, a file management platform, a static resource server and an APP container environment. The file management platform mainly comprises the following functions: account management, file version management, log management and incremental update management; APP container environmental functions include; host protocol, breakpoint mechanism, security mechanism, cache mechanism, incremental update mechanism, file version management and other major functions; static resource server function: is responsible for storing the file package.
The invention has the main functions of realizing incremental update of files, breakpoint continuous downloading, file version management, a safety mechanism and the like by closely matching three layers, solving the problems of long-time occupation pressure and bandwidth pressure on server resources, reducing user downloading flow, reducing user downloading time, avoiding redundant file generation and waste of resources such as flow and the like and solving downloading service requirements of multi-file and multi-version management caused by APP in a downloading failure scene of weak network disconnection.
Optionally, in one embodiment of the present invention, receiving the differential packet includes:
if the target temporary file exists locally, acquiring a first data length of the local target temporary file; the differential package comprises a target temporary file;
and downloading the target temporary file from the first data length, and placing the target temporary file into the differential packet.
In some possible embodiments, the receiving of the differential packet and the receiving of the target file information in the embodiments of the present application may use a breakpoint continuous downloading manner, so as to save downloading flow and time, and a specific flow is shown in fig. 5, including: downloading a file, caching the local file, downloading and writing the residual length according to the existing length of the file, reconnecting after downloading is interrupted, checking the integrity of the file, and the like. The breakpoint downloading function makes up for the mode that the traditional downloading cannot be reconnected after the interruption, thereby reducing the waste of resources and flow of the interruption of the downloading, accelerating the whole downloading time and improving the user experience.
Optionally, in one embodiment of the present invention, the method further comprises:
if the local cache file information does not pass the file security check, deleting the local cache file information;
or if the received differential packet does not pass the file security check, deleting the differential packet.
In some possible embodiments, during the network transmission process and during the local cache, there may be security problems such as file tampering, so in the present invention, a security check mechanism is introduced to ensure the security of the file. The flow chart of the security verification mechanism is shown in fig. 6, and the security mechanism is to utilize algorithms such as MD5 to correct the integrity of the downloaded file and the local file through the local cache information of the APP container in the file version iteration process. The APP container takes the local cache file information, checks the safety and the integrity of the file through a network request and a file server, and if the safety check is not passed, deletes the local cache file data at the same time, and downloads the full package; if the security check passes, differential or full packet downloads may be performed. And (3) after the downloading is finished, carrying out the security check of the file obtained by final downloading, and processing and using the file according to the corresponding business logic through the final security check. Such a security mechanism ensures security when locally caching the file and security when transmitting the file in a network connection.
Optionally, in an embodiment of the present invention, if the local cache file information and the target file information are not successfully matched, and the local cache file information meets the condition of the incremental update mechanism, receiving the differential packet includes:
if the local cache file information and the target file information are not successfully matched, and the local cache file information is successfully matched with the reference packet, receiving the differential packet; the reference package is used for representing the file with the version before the version of the target file; the differential packet is a differential patch file between the reference packet and the target file information.
In some possible implementations, the differential packet in the embodiments of the present application refers to a differential patch file between the reference packet and the target file information, and by receiving the differential packet, the flow consumption and the downloading time of file update are reduced, so that the user experience is improved.
Optionally, in one embodiment of the present invention, the method further comprises:
if the local cache file information and the target file information are not successfully matched, and the local cache file information and the reference packet are not successfully matched, receiving a full packet; the full package is stored in the file server, and the full package comprises target file information;
or if the local cache file information and the target file information are successfully matched, updating the version of the file according to the local cache file.
Optionally, in one embodiment of the present invention, the method further comprises:
if the local cache file information and the target file information are not successfully matched, and the local cache file information and the reference packet are successfully matched, the version number between the reference packet and the target file information is obtained;
and determining a second number of differential packets to be received according to the number of versions, wherein the second number is equal to the number of versions.
In some possible embodiments, the number of versions, that is, the number of versions, that the local cache file differs from the current target file information before is obtained by detecting which reference packet the local cache file matches. The number of differential packets to be received is determined according to the number of versions, so that the accuracy of version updating is improved.
In summary, the invention provides a multi-file and multi-version file downloading and updating scheme based on a mobile application mobile phone terminal, which comprises a file management platform, a static resource server and an APP container environment, wherein the file management platform mainly comprises the following functions: account management, file version management, log management and incremental update management; APP container environmental function package: host protocol, breakpoint mechanism, security mechanism, cache mechanism, incremental update mechanism, file version management and other major functions; static resource server function: is responsible for storing the file package. The user can realize the file downloading and updating function fast by accessing the APP container environment and operating with the simple file management platform, and the downloading and updating function can automatically download and update the file according to different states (the specific principle can refer to a file complaint flow chart), and the user does not need to select. The access cost of the user is reduced to the minimum.
The embodiment of the invention mainly provides version updating mechanisms including breakpoint continuous transmission, increment updating, a caching mechanism, a security mechanism, a version management mechanism and the like, and specific implementation steps and function interaction modes of functions related to each mechanism. Compared with the related art, the embodiment of the invention realizes that a developer can realize a multi-file and multi-version file updating scheme by integrating the APP container environment framework into the application program without modifying the original code, thereby reducing the workload and the maintenance cost. The embodiment of the invention is suitable for various file downloading and updating service requirements, such as various downloading service scenes of offline packages, applets, application markets and the like. Compared with the traditional downloading and updating mode, the embodiment of the invention can better save server resources and file downloading flow, reduce downloading time and better ensure file security by introducing a security mechanism.
Next, a version updating system of a file according to an embodiment of the present invention will be described with reference to fig. 7.
FIG. 7 is a schematic diagram of a version update system of a file according to an embodiment of the present invention, where the system specifically includes:
a first module 710, configured to obtain local cache file information;
a second module 720, configured to match the local cache file information with the target file information through the network request; storing the target file information in a file server; the version of the target file information is the latest version;
a third module 730, configured to receive the differential packet if the local cache file information and the target file information are not successfully matched, and the local cache file information satisfies the condition of the incremental update mechanism; the incremental updating mechanism condition is used for representing the version and the security condition to be met by the local cache file, and the differential packet is generated by the file management platform according to the local cache file information and the target file information;
and a fourth module 740, configured to perform patch combination processing on the local cache file and the differential packet, generate a target version file, and perform version update on the file according to the target version file.
It can be seen that the content in the above method embodiment is applicable to the system embodiment, and the functions specifically implemented by the system embodiment are the same as those of the method embodiment, and the beneficial effects achieved by the method embodiment are the same as those achieved by the method embodiment.
Referring to fig. 8, an embodiment of the present invention provides a version updating apparatus for a file, including:
at least one processor 810;
at least one memory 820 for storing at least one program;
the at least one program, when executed by the at least one processor 810, causes the at least one processor 810 to implement a version updating method of a file.
Similarly, the content in the above method embodiment is applicable to the embodiment of the present device, and the functions specifically implemented by the embodiment of the present device are the same as those of the embodiment of the above method, and the beneficial effects achieved by the embodiment of the above method are the same as those achieved by the embodiment of the above method.
The embodiment of the invention also provides a computer readable storage medium, in which a program executable by a processor is stored, the program executable by the processor being used for executing the version updating method of the file.
Similarly, the content in the above method embodiment is applicable to the present storage medium embodiment, and the specific functions of the present storage medium embodiment are the same as those of the above method embodiment, and the achieved beneficial effects are the same as those of the above method embodiment.
In some alternative embodiments, the functions/acts noted in the block diagrams may occur out of the order noted in the operational illustrations. For example, two blocks shown in succession may in fact be executed substantially concurrently or the blocks may sometimes be executed in the reverse order, depending upon the functionality/acts involved. Furthermore, the embodiments presented and described in the flowcharts of the present invention are provided by way of example in order to provide a more thorough understanding of the technology. The disclosed methods are not limited to the operations and logic flows presented herein. Alternative embodiments are contemplated in which the order of various operations is changed, and in which sub-operations described as part of a larger operation are performed independently.
Furthermore, while the invention is described in the context of functional modules, it should be appreciated that, unless otherwise indicated, one or more of the functions and/or features may be integrated in a single physical device and/or software module or may be implemented in separate physical devices or software modules. It will also be appreciated that a detailed discussion of the actual implementation of each module is not necessary to an understanding of the present invention. Rather, the actual implementation of the various functional modules in the apparatus disclosed herein will be apparent to those skilled in the art from consideration of their attributes, functions and internal relationships. Accordingly, one of ordinary skill in the art can implement the invention as set forth in the claims without undue experimentation. It is also to be understood that the specific concepts disclosed are merely illustrative and are not intended to be limiting upon the scope of the invention, which is to be defined in the appended claims and their full scope of equivalents.
The functions, if implemented in the form of software functional units and sold or used as a stand-alone product, may be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention may be embodied essentially or in a part contributing to the prior art or in the form of a software product stored in a storage medium, including several programs for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a random access Memory (RAM, random Access Memory), a magnetic disk, or an optical disk, or other various media capable of storing program codes.
Logic and/or steps represented in the flowcharts or otherwise described herein, e.g., a ordered listing of executable programs for implementing logical functions, can be embodied in any computer-readable medium for use by or in connection with a program execution system, apparatus, or device, such as a computer-based system, processor-containing system, or other system that can fetch the programs from the program execution system, apparatus, or device and execute the programs. For the purposes of this description, a "computer-readable medium" can be any means that can contain, store, communicate, propagate, or transport the program for use by or in connection with the program execution system, apparatus, or device.
More specific examples (a non-exhaustive list) of the computer-readable medium would include the following: an electrical connection (electronic device) having one or more wires, a portable computer diskette (magnetic device), a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber device, and a portable compact disc read-only memory (CDROM). In addition, the computer readable medium may even be paper or other suitable medium on which the program is printed, as the program may be electronically captured, via, for instance, optical scanning of the paper or other medium, then compiled, interpreted or otherwise processed in a suitable manner, if necessary, and then stored in a computer memory.
It is to be understood that portions of the present invention may be implemented in hardware, software, firmware, or a combination thereof. In the above embodiments, the various steps or methods may be implemented in software or firmware stored in a memory and executed by a suitable program execution system. For example, if implemented in hardware, as in another embodiment, may be implemented using any one or combination of the following techniques, as is well known in the art: discrete logic circuits having logic gates for implementing logic functions on data signals, application specific integrated circuits having suitable combinational logic gates, programmable Gate Arrays (PGAs), field Programmable Gate Arrays (FPGAs), and the like.
In the foregoing description of the present specification, reference has been made to the terms "one embodiment/example", "another embodiment/example", "certain embodiments/examples", and the like, means that a particular feature, structure, material, or characteristic described in connection with the embodiment or example is included in at least one embodiment or example of the invention. In this specification, schematic representations of the above terms do not necessarily refer to the same embodiments or examples. Furthermore, the particular features, structures, materials, or characteristics described may be combined in any suitable manner in any one or more embodiments or examples.
While embodiments of the present invention have been shown and described, it will be understood by those of ordinary skill in the art that: many changes, modifications, substitutions and variations may be made to the embodiments without departing from the spirit and principles of the invention, the scope of which is defined by the claims and their equivalents.
While the preferred embodiment of the present invention has been described in detail, the present invention is not limited to the embodiments described above, and various equivalent modifications and substitutions can be made by those skilled in the art without departing from the spirit of the present invention, and these equivalent modifications and substitutions are intended to be included in the scope of the present invention as defined in the appended claims.

Claims (10)

1. A version updating method of a file, comprising the steps of:
acquiring local cache file information;
matching the local cache file information with target file information through a network request; the target file information is stored in a file server; the version of the target file information is the latest version;
if the local cache file information and the target file information are not successfully matched, and the local cache file information meets the condition of an incremental updating mechanism, receiving a differential packet; the increment updating mechanism condition is used for representing the version and the security condition to be met by the local cache file, and the differential packet is generated by the file management platform according to the local cache file information and the target file information;
and carrying out patch combination processing on the local cache file and the differential packet to generate a target version file, and carrying out version updating on the file according to the target version file.
2. The version-up method of a file according to claim 1, characterized in that the method further comprises:
establishing a version updating frame, wherein the version updating frame comprises a file management platform, a file server and a terminal container;
the file management platform is used for acquiring and recording the version of the file; the file management platform is also used for generating differential packets according to the local cache file information and the target file information and issuing the differential packets;
the file server is used for storing the target file information and the differential packet;
the terminal container is used for receiving the differential packet, and the terminal container is also used for updating the version of the file.
3. The version-up method of a file according to claim 1, wherein said receiving differential packets comprises:
if the target temporary file exists locally, acquiring a first data length of the local target temporary file; the differential package comprises the target temporary file;
and downloading the target temporary file from the first data length, and placing the target temporary file into the differential packet.
4. The version-up method of a file according to claim 1, characterized in that the method further comprises the steps of:
if the local cache file information does not pass the file security check, deleting the local cache file information;
or if the received differential packet does not pass the file security check, deleting the differential packet.
5. The method of claim 1, wherein if the local cache file information and the target file information are not successfully matched, and the local cache file information satisfies an incremental update mechanism condition, receiving a differential packet, comprises:
if the local cache file information and the target file information are not successfully matched, and the local cache file information and the reference packet are successfully matched, receiving a differential packet; the reference package is used for representing files with versions before the versions of the target files; the differential package is a differential patch file between the reference package and the target file information.
6. The version-up method of a file according to claim 5, further comprising:
if the local cache file information and the target file information are not successfully matched, and the local cache file information and the reference packet are not successfully matched, receiving a full-volume packet; the full package is stored in a file server, and the full package comprises the target file information;
or if the local cache file information and the target file information are successfully matched, updating the version of the file according to the local cache file.
7. The version-up method of a file according to claim 2, characterized in that the method further comprises:
if the local cache file information and the target file information are not successfully matched, and the local cache file information and the reference packet are successfully matched, the version number between the reference packet and the target file information is obtained;
and determining a second number of differential packets to be received according to the version number, wherein the second number is equal to the version number.
8. A version-up system for a file, comprising:
the first module is used for acquiring the local cache file information;
the second module is used for matching the local cache file information with the target file information through a network request; the target file information is stored in a file server; the version of the target file information is the latest version;
a third module, configured to receive a differential packet if the local cache file information and the target file information are not successfully matched, and the local cache file information meets an incremental update mechanism condition; the increment updating mechanism condition is used for representing the version and the security condition to be met by the local cache file, and the differential packet is generated by the file management platform according to the local cache file information and the target file information;
and a fourth module, configured to perform patch combination processing on the local cache file and the differential packet, generate a target version file, and perform version update on the file according to the target version file.
9. A version updating apparatus of a file, comprising:
at least one processor;
at least one memory for storing at least one program;
the at least one program, when executed by the at least one processor, causes the at least one processor to implement the version updating method of a file as claimed in any one of claims 1 to 7.
10. A computer-readable storage medium in which a processor-executable program is stored, characterized in that the processor-executable program is for realizing the version updating method of a file according to any one of claims 1 to 7 when being executed by a processor.
CN202311281227.3A 2023-09-28 2023-09-28 File version updating method, system, device and storage medium Pending CN117435229A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311281227.3A CN117435229A (en) 2023-09-28 2023-09-28 File version updating method, system, device and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311281227.3A CN117435229A (en) 2023-09-28 2023-09-28 File version updating method, system, device and storage medium

Publications (1)

Publication Number Publication Date
CN117435229A true CN117435229A (en) 2024-01-23

Family

ID=89548926

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311281227.3A Pending CN117435229A (en) 2023-09-28 2023-09-28 File version updating method, system, device and storage medium

Country Status (1)

Country Link
CN (1) CN117435229A (en)

Similar Documents

Publication Publication Date Title
US10114630B2 (en) Management of software and operating system updates required for the process of creating a virtual machine facsimile of an existing physical or virtual machine
CN101110788B (en) Method and system for updating client software
US7600021B2 (en) Delta replication of source files and packages across networked resources
US9244673B2 (en) System and method for updating application archive files
US8630978B2 (en) Method of bi-directional synchronization of user data
EP2021937B1 (en) Techniques to perform gradual upgrades
US20140379656A1 (en) System and Method for Maintaining a Cluster Setup
CN110147240B (en) Cloud storage-based application program installation method, system and storage medium
US20140143647A1 (en) Method for improving browser cache by reducing duplicate stored content
CN105335253A (en) Method and device for creating virtual machine system disk snapshots
CN101079763A (en) A remote configuration and management system and method of servers
CN109360029B (en) Self-management method of remote terminal advertising machine
US9336218B2 (en) Managing a binary object in a database system
CN111598575A (en) Business process control method and device, electronic equipment and readable storage medium
CN115080515A (en) Block chain based system file sharing method and system
US20100185582A1 (en) Web Deployment Functions and Interfaces
KR100653280B1 (en) Mobile phone capable of updating application and method for updating application of mobile phone
CN117435229A (en) File version updating method, system, device and storage medium
CN112395437A (en) 3D model loading method and device, electronic equipment and storage medium
CN111611510B (en) Cache clearing method, device and system
CN112988738B (en) Data slicing method and device for block chain
CN114579167A (en) Method, device and storage medium for downloading application upgrade file
WO2022001203A1 (en) Mirror image distribution method, electronic device, and storage medium
CN115421785B (en) Method, device and medium for transplanting application program
CN115529332B (en) Cloud car machine system for car machine central control and remote access method

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