Skip to content

Improve handling of large diffs

Yorick Peterse requested to merge better-large-diff-handling into master

This MR adjusts the way checking for large diffs takes place. Prior to this MR the procedure was basically as follows:

  1. Iterate over every diff in a collection
  2. Just load the entire diff into memory, why not
  3. Check if the resulting content including any diff markers/meta data exceed a threshold
  4. Prune or collapse the diff

This MR changes things around so the procedure is instead as follows:

  1. Iterate over every diff in a collection
  2. Check if the data modified (excluding diff markers) is larger than a threshold
  3. If this is not the case, proceed as usual. if this is the case we'll prune/collapse the diff

Merge request reports