Systems and methods for generating and applying a patch package
AssigneeFilo Systems Ltd.
InventorsEtamar H. Laron, Michael J. May
Life of this patent
Estimating the term…
Abstract
Systems and methods of creating and applying a software package (commonly referred to as “patch” or “patch package”) that enables to more efficiently create an updated version of a software package, by applying the patch over the original software version. Embodiments of the present invention may require more resources, e.g., time, processing power and storage space, to prepare (create) a patch (compared to differencing modules of the art) as they spend more time analyzing the logical structure of each version, but the result is oftentimes a smaller and more efficient patch package. Also are disclosed systems and methods of compressing and decompressing a patch package, whether as an update or by using a single-archive input.
Claims20
A patch generating computing system comprising:
- at least one processor;
- and
- at least one memory communicatively coupled to said at least one processor comprising computer-readable instructions that when executed by the at least one processor cause the computing system to implement a method of generating a patch package 170 comprising patch data 172 and patch instructions 174, said patch package adapted to update an original archive element 130 to a destination archive element 132, the method comprising:
- (i) assigning the original archive element 130 as an original element in a matching pair, and assign the destination archive element 132 as a destination element in said matching pair;
- (ii) comparing said original element and said destination element in said matching pair, and if different, preparing a corresponding patch instruction 174 comprising an action indicating a patch operation of either addition, deletion or updating related to said destination element;
- (iii) identifying a structural type of said original element and said destination element, said structural type being one of directory, archive, compressed or data;
- (iv) if said structural type is a complex archive element:
- a. identifying at least one decompressing module 144 or unpacking module 145 adapted to be applied to said original element and said destination element;
- b. applying the identified at least one decompressing module or unpacking module to said original element, and saving resulting zero or more internal archive elements to an original archive structure 152 comprising a plurality of archive elements;
- c. applying the identified at least one decompression module or unpacking module to said destination element, and saving the resulting zero or more internal archive elements to a destination archive structure 154 comprising the plurality of archive elements;
- (v) updating a patch instruction 174 in respect of said destination element, the patch instruction comprising said patch instruction action, the structural type, an identifier of said destination element, and the identified at least one decompressing module or unpacking module;
- (vi) identifying further one or more matching pairs, each further one or more matching pair comprising of one internal archive element from said resulting zero or more internal archive elements of step (iv.b) assigned as internal element, and the one internal archive element from said resulting zero or more internal archive elements of step (iv.c) assigned as destination element, wherein said original element and said destination element are matched by identifying an identical identifier;
- (vii) repeating steps (ii) to (vi) for said further one or more matching pairs;
- and
- (viii) applying a differencing module 160 to the original archive structure and the destination archive structure and generating the patch package 170 comprising the patch data 172 and the patch instructions 174 such that the destination archive element 132 can be constructed by applying said patch data 172 together with said patch instructions 174 to the corresponding original archive element 130.
A patch generating method, implemented in a computing system comprising:
- at least one processor;
- and
- at least one memory communicatively coupled to said at least one processor comprising computer-readable instructions that when executed by the at least one processor cause the computing system to implement a method of generating a patch package 170 comprising patch data 172 and patch instructions 174, said patch package adapted to update an original archive element 130 to a destination archive element 132, the method comprising:
- (i) assigning the original archive element 130 as an original element in a matching pair, and the assign destination archive element 132 as a destination element in said matching pair;
- (ii) comparing said original element and said destination element in said matching pair, and if different, preparing a corresponding patch instruction 174 comprising an action indicating a patch operation of either addition, deletion or updating related to said destination element;
- (iii) identifying a structural type of said original element and said destination element, said structural type being one of directory, archive, compressed or data;
- (iv) if said structural type is a complex archive element:
- a. identifying at least one decompressing module 144 or unpacking module 145 adapted to be applied to said original element and said destination element;
- b. applying the identified at least one decompressing module or unpacking module to said original element, and saving resulting zero or more internal archive elements to an original archive structure 152 comprising a plurality of archive elements;
- c. applying the identified at least one decompression module or unpacking module to said destination element, and saving the resulting zero or more internal archive elements to a destination archive structure 154 comprising the plurality of archive elements;
- (v) updating a patch instruction 174 in respect of said destination element, the patch instruction comprising said patch instruction action, the structural type, an identifier of said destination element, and the identified at least one decompressing module or unpacking module;
- (vi) identifying further one or more matching pairs, each further one or more matching pair comprising of one internal archive element from said resulting zero or more internal archive elements of step (iv.b) assigned as internal element, and the one internal archive element from said resulting zero or more internal archive elements of step (iv.c) assigned as destination element, wherein said original element and said destination element are matched by identifying an identical identifier;
- (vii) repeating steps (ii) to (vi) for said further one or more matching pairs;
- and
- (viii) applying a differencing module 160 to the original archive structure and the destination archive structure and generating the patch package 170 comprising the patch data 172 and the patch instructions 174 such that the destination archive element 132 can be constructed by applying said patch data 172 together with said patch instructions 174 to the corresponding original archive element 130.
A patch application computing system comprising:
- at least one processor;
- and
- at least one memory communicatively coupled to said at least one processor comprising computer-readable instructions that when executed by the at least one processor cause the computing system to implement a method of generating a destination archive element 132 based on an original archive element 130 and a patch package 170 comprising a plurality of patch instructions 174 and patch data 172, the method comprising:
- for each patch instruction of said patch instructions 174, perform on the element indicated by said patch instruction:
- (i) identifying the structural type of said element, said structural type comprising directory, archive, compressed, link or data, and an action in respect of said element;
- (ii) identifying said element within said original archive element as original element, and if necessary, applying steps (iii) and (iv) to its location in order to obtain said element in cases it is within an archive or within a compressed location;
- (iii) if said structural type is compressed:
- a. identifying a decompression module 144 capable of decompressing said original element;
- b. decompressing said original element to destination elements and storing said destination elements in a destination archive structure 154;
- c. marking said original element for compressing;
- (iv) if said structural type is archive;
- a. identifying an unpacking module 145 capable of unpacking said original element;
- b. unpacking said original element to destination elements and storing said destination elements in the destination archive structure 154;
- c. marking said original element for archiving;
- d. if said action indicates link, obtain another element in the destination archive structure 154 indicated in said patch instruction 174, and replacing data of said element with the data of said another element in the destination archive structure 154;
- (v) if said original element was marked for archiving or for compressing, identifying all patch instructions 174 having a location in the location of said original element, and executing steps (i) to (v) for each of said patch instructions having such location;
- (vi) if said action indicates add or update execute patch application module 180 on said destination element using the patch data 172 resulting in an updated version of said destination element;
- (vii) if said action indicates delete, delete said element;
- otherwise:
- a. if said structural type is archive or said element was marked for archiving, identifying an archiving module 142 capable of archiving said element, archiving said element according to an indication and/or metadata in the patch instruction 174;
- and
- b. if said structural type is compressed or said element was marked for compression, identifying a compression module 141 capable of compressing said element, compressing said element according to an indication and/or metadata in the patch instruction 174.
A compression computing system comprising:
- at least one processor;
- and
- at least one memory communicatively coupled to said at least one processor comprising computer-readable instructions that when executed by the at least one processor cause the computing system to implement a method of compressing a plurality of destination archive elements 132 into a patch package 170 comprising patch data 172 and patch instructions 174, the method comprising:
- (i) assigning the destination archive element 132 as a destination element in a matching pair, and a null indication as an original element in said matching pair;
- (ii) for every destination archive element 132 in said plurality of destination archive elements, perform:
- a. identifying a structural type of said destination archive element 130, said structural type comprising directory, archive, compressed or data,
- b. if the structural type is compressed, then
- A. identifying at least one decompression module 144 compatible with said destination element;
- B. applying said at least one decompression module 144 to said destination element;
- C. storing results of B comprising of archive elements, each archive element being an internal archive element in a destination archive structure 154;
- c. if structural type is archive, then
- A. identifying at least one unpacking module 145 compatible with said destination element;
- B. applying said at least one unpacking module 145 to the destination archive structure 154 comprising of the archive elements, each archive element being then internal archive element;
- C. storing the results of B comprising of the archive elements, each archive element being the internal archive element in the destination archive structure 154;
- d. updating the patch data 170 and the patch instruction 174 in respect of said destination element, adding said structural type, identifier of said destination element, said identified at least one decompressing module if applicable and said identified at least one unpacking module 145 as applicable;
- (iii) repeating step (ii) for a plurality of said archive elements, each archive element being the internal archive element in said destination archive structure 154;
- and
- (iv) applying a selected compression module 141 or differencing module 160 to said destination archive structure 154, and generating the patch package 170 comprising the patch data 172 and the patch instructions 174 adapted to reconstructing said plurality of destination archive elements 132.
A compression computing system comprising:
- at least one processor;
- and
- at least one memory communicatively coupled to said at least one processor comprising computer-readable instructions that when executed by the at least one processor cause the computing system to implement a method of compressing a plurality of destination archive elements 132 into a patch package 170 comprising patch data 172 and patch instructions 174, the method comprising:
- (i) assigning the destination archive element 132 as a destination element in a matching pair, and a null indication as an original element in said matching pair;
- (ii) for every matching pair comprising of a null indication as the original element, and one archive element of said plurality of destination elements as the destination element:
- a. identifying datatype of said destination element and attempt matching a decoding module 146 capable of transforming said destination element into a decoded data format;
- b. if successful matching the decoding module 146, decoding said destination element into the decoded data format, and updating the patch data 170 and the patch instructions 174 accordingly;
- c. storing in a destination archive structure 154 said decoded data format as an archive element if available, and if not, storing said destination element;
- (iii) packaging said destination archive structure 154 into an archive using an archiving module 142 if applicable;
- and
- (iv) applying a selected compression module 141 or differencing module 160 to said destination archive structure 154, and generating the patch package 170 comprising the patch data 172 and the patch instructions 174 adapted to reconstructing said plurality of destination archive elements 132.
Dependencies are inferred from the claim text.