8/27/2023 0 Comments Git setting up diffmerge macIn the last scenario, go the repository and fetch the diff Diff limitsĪs explained above, we limit single diff files and the size of the whole diff.Otherwise, if it’s a current MR revision, use the persisted.Check whether we have the NoteDiffFile#diff persisted and use it. Of hitting the repository every time we need the diff of the file, we: On NoteDiffFile (which is associated with the actual DiffNote). When commenting on a diff (any comparison), we persist a truncated diff version Using Gitlab::Diff::FileCollection::MergeRequestDiff Note diffs If the diff file is cacheable (text-based), it’s cached on Redis.Know which viewer it should use for each file (text, image, deleted, etc).Fetch the old and new file blobs in batch to:.Fetch all diff files from database merge_request_diff_files.In order to present diffs information on the merge request diffs page, we: (see the Diff limits section) are not persisted in the database. However, diff files larger than defined safety limits Then persisted on merge_request_diff_files table.Įven though diffs larger than 10% of the value of ApplicationSettings#diff_max_patch_bytes are collapsed, The diffs fetching process limits single file diff sizes and the overall size of the whole diff through a series of constant values. We fetch the comparison information using Gitlab::Git::Compare, which fetches base and head data using Gitaly and diff between them through When refreshing a merge request (pushing to a source branch, force-pushing to target branch, or if the target branch now contains any commits from the MR) Architecture overview Merge request diffs Have changed since then, it should still serve as a good introduction. ) on GitLab Diffs and Commenting on Diffsįunctionality to share domain-specific knowledge with anyone who may work in this part of theĮverything covered in this deep dive was accurate as of GitLab 11.7, and while specific details may In January 2019, Oswaldo Ferreira hosted a Deep Dive (GitLab team members only: Redis (cached highlighted diffs) Deep Dive.Database (through merge_request_diff_files).We rely on different sources to present diffs. Merge request diffs against the HEAD of the target branch Working with diffs.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |