Skip to content

Support per-blob queries in snippets

Denys Mishunov requested to merge dmishunov-multiple-snippet-queries into master

What does this MR do?

As per the relevant issue this MR introduces:

  1. [BE] Updated GraphQL schema for snippet and blobs within it
  2. [FE] Disabled batching for GraphQL queries within the snippet Vue application
  3. [FE] Per-blob query (employing updated data structure introduced in 1.) to get the blob's content

Screenshots

Note:

  • discrete rendering of the blobs: all blobs' contents are fetched independently from each other in this MR
  • discrete network requests to get graphql data (this MR) instead of a massive one (current master), containing all contents
  • significant decrease (1.7 MB vs. 73.4 MB) of data transferred in the network requests due to not fetching content for the too large blobs that are not rendered anyway
Before After
Rendering Screenshot_2020-09-21_at_10.42.27 Screenshot_2020-09-21_at_10.40.53
Network request Screenshot_2020-09-21_at_10.43.08 Screenshot_2020-09-21_at_10.41.50

Since multi-file snippets are still behind the feature flag (:snippet_multiple_files), there's no changelog entry provided

Does this MR meet the acceptance criteria?

Conformity

Availability and Testing

References #254198 (closed)

Edited by Peter Leitzen

Merge request reports