Skip to content

[Gitlab Bugtracker] [Report a new issue] Slow form display if a lot of data to load

Affected version : 7.0.1.RELEASE

This issue must analyse performances form display when an user reports a new issue with Gitlab bugtracker when a lot of data must be charged (milestone, assignee, labels...)

To prevent users from waiting for the data to load, a cache should be built with the bugtracker data.
To do so, on the bugtracker page (only for GitLab BT for now), it should be possible for an admin to enter a token that would be used to build the cache.
The cache would be built/updated:

  • when a GitLab project is linked to a Squash project (in the bugtracker section of a project)
  • according to a delay that would probably be configured in the Squash property file (default value: 1 time per day)

Configure a token used for the cache

On the bugtrakcer page, only for gitlab.bugtracker type, add a new block at the end:

  • name: Cache configuration
  • icon: TBD
  • content:
    • info message
    • "Token" field => standard token field with save and delete buttons
    • Above the token field, add the mention "Credentials used to build the cache"
    • Nice to have (can be done later):
      • display the cache last update date
      • allow to force the cache

Display a message below the token field:

  • if no token is configured
  • if the token has expired (if possible)

If no token is configured, display an info message in the "Report an issue" dialog while the form is loading.

Build and update the cache

Once the token is configured, the cache shoud be initialized:

  • for new bugtrackers, when a GitLab project is linked to a Squash project for the first time (in the bugtracker section of a project)
  • for existing bugtrackers, if it is already to projects, the cache should be built after configuring the token

Then, the cache should be updated:

  • each time a GitLab project is linked or unlinked to a Squash project on the project conf page
  • when the server URL is modified
  • when the token used for the cache is modified
  • according to a delay configured in the Squash property file
Edited by Marion Delobeau
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information