Skip to content

Remove un-used data from discussions endpoint

What does this MR do?

Creates a specific serializer entity for the discussions.json call (DiscussionDiffFileEntity). Turns out we return quite some unnecessary data (mainly highlighted_diff_lines and parallel_diff_lines), which are not used.

This will dramatically reduce the payload size:

  • 6mb down to 1.1mb on a large merge request
  • Highlighting calls (which consumes considerable memory and CPU will dramatically be reduced as well)

EE MR: https://gitlab.com/gitlab-org/gitlab-ee/merge_requests/8736

What are the relevant issue numbers?

Closes https://gitlab.com/gitlab-org/gitlab-ce/issues/54288

Does this MR meet the acceptance criteria?

Edited by Oswaldo Ferreira

Merge request reports

Loading