Add comparing diff versions and specific commit support for rapid diffs

Background

We decided to keep the initial implementation of streaming endpoint for MR diffs simple. As discussed in #450990 (comment 1901990588), we are splitting adding support for existing features that diffs_batch.json supports.

This issue is for supporting comparing different diff versions and specific commit. Currently, the streaming endpoint is only getting the diff of latest base diff.

The feature is behind rapid_diffs_on_mr_show feature flag.

Proposal

Update MergeRequests::DiffsStreamController (this is the controller being used for streaming rest of the diffs) and RapidDiffs::MergeRequestPresenter (this is the presenter we used when rendering first N diffs when the page loads) to support rendering context commit diffs.

Edited Feb 03, 2026 by 🤖 GitLab Bot 🤖
Assignee Loading
Time tracking Loading