EP0981099A2

A method of and an apparatus for merging a sequence of delta files

Abstract

A method of and an apparatus for merging a sequence of delta files is described. The delta files together define a series of changes between a base file and an updated file. each delta file defining one or more changes in terms of one or more unique tokens each identifying original data or of one or more reused tokens identifying data reused from the immediately preceding delta file or the base file. The method comprises creating an initial merge structure from the base file and the first delta file in the sequence. A further merge structure is created from the initial merge structure and the next delta file in the sequence by comparing tokens in the initial merge structures and replacing reused tokens in the further merge structure with tokens in the initial merge structure. The initial merge structure is then replaced with the further merge structure so that the further merge structure becomes the initial merge structure. The operations of creating a further merge structure and replacing the initial merge structure with a further merge structure is repeated for all delta files in sequence order. The thus created merge structure represents all changes between the base file and the updated file. The apparatus, which may comprise a suitably configured computer, comprises means suitable for carrying out the method steps.

EP0981099A2, drawing sheet 1
Sheet 1 of 10

Term

Term ended

Projected expiry passed 11 August 2019, 7.1 years ago.

  1. Priority
  2. Filed
  3. Published
  4. Projected expiry
  5. Today

31 claims: 15 independent, 16 dependent

  1. 1
    A method of merging a sequence of delta files that together define a series of changes between a base file and an updated file, each delta file defining one or more changes in terms of one or more unique tokens each identifying original data or of one or more reuse tokens identifying data reused from the immediately preceding delta file or the base file, the method comprising:creating an initial merge structure from the base file and the first delta file in the sequence;creating a further merge structure from the initial merge structure and the next delta file in the sequence by comparing tokens in the initial and further merge structures and replacing reuse tokens in the further merge structure with tokens in the initial merge structure;replacing the initial merge structure with the further merge structure so that the further merge structure becomes the initial merge structure;and repeating the operations of creating a further merge structure and replacing the initial merge structure with the further merge structure, for all delta files in sequence order, whereby the thus created merge structure represents all changes between the base file and the updated file.
  2. 4
    A method as claimed in any preceding claim, wherein each reuse token comprises a reuse token indicator, an offset value identifying the position of bytes in another delta file or the base file and a number value representing the number of bytes associated with the position identified by the offset value.
  3. 5
    A method as claimed in any preceding claim, wherein each unique token comprises a unique token indicator, a file identifier for identifying the file containing unique data for the thus created merge structure, an offset value identifying the position of bytes in another delta file or the base file and a number value representing the number of bytes associated with the position identified by the offset value.
  4. 6
    A method as claimed in any preceding claim, wherein the initial merge structure is created by:identifying a file position corresponding to the start of the base file;identifying the first token in the first delta file;reading data associated with the identified token and the identified file position into a structure;adjusting the identified file position by a length associated with the identified token;identifying the next token in the first delta file;and repeating the steps of reading data, adjusting the identified file position and identifying the next token for all tokens in the first delta file, whereby the structure thus produced is the initial merge structure.
  5. 7
    A method as claimed in any preceding claim, further comprising:defining for each token in the further merge structure a window of locations in the initial merge structure from data associated with the token in the further merge structure;identifying for each window in the initial merge structure the or each token in the further merge structure that refers to data in the window;and replacing thus identified tokens in the further merge structure with data derived from tokens in the window of the initial merge structure.
  6. 8
    A method as claimed in any preceding claim. further comprising:identifying reuse tokens in a merge structure;appending in the merge structure the unique token or tokens to which the reuse token pertains;and replacing the reuse token with an offset token which comprises a pointer that identifies the position at which the unique token or tokens are appended in the merge structure.
  7. 12
    A method as claimed in any preceding claim further comprising reviewing tokens in the created merge structure to identify as redundant those delta files to which no reference is made.
  8. 14
    A method as claimed in any preceding claim, further comprising saving the created merge structure.
  9. 15
    A method as claimed in any preceding claim, further comprising using the created merge structure to create the updated file from the base file.
  10. 16
    A method of creating a current file from an initial file and a set of difference files that defines a sequence of changes between the initial file and the current file, the method comprising:merging the difference files to remove redundant information therefrom and thus create a changes file representing all changes to be applied to the initial file in order to arrive at the current file;and modifying the initial file using the information in the changes file.
  11. 19
    An apparatus for merging a sequence of delta files that together define a series of changes between a base file and an updated file, each delta file defining one or more changes in terms of one or more unique tokens each identifying original data or of one or more reuse tokens identifying data reused from the immediately preceding delta file or the base file, the apparatus comprising:means for creating an initial merge structure from the base file and the first delta file in the sequence;means for creating a further merge structure from the initial merge structure and the next delta file in the sequence by comparing tokens in the initial and further merge structures and replacing reuse tokens in the further merge structure with tokens in the initial merge structure;means for replacing the initial merge structure with the further merge structure so that the further merge structure becomes the initial merge structure;and means for repeating the operations of creating a further merge structure and replacing the initial merge structure with the further merge structure, for all delta files in sequence order, whereby the thus created merge structure represents all changes between the base file and the updated file.
  12. 26
    An apparatus as claimed in any of claims 19 to 25, further comprising means for reviewing tokens in the created merge structure to identify as redundant those delta files to which no reference is made.
  13. 28
    An apparatus as claimed in any of claims 19 to 27, further comprising means for saving the created merge structure.
  14. 29
    An apparatus as claimed in any of claims 19 to 28, further comprising means for using the created merge structure to create the updated file from the base file.
  15. 30
    An apparatus for creating a current file from an initial file and a set of difference files that defines a sequence of changes between the initial file and the current file, the apparatus comprising:means for merging the difference files to remove redundant information therefrom and thus create a changes file representing all changes to be applied to the initial file in order to arrive at the current file;and means for modifying the initial file using the information in the changes file.