Skip to content
Snippets Groups Projects
  1. Sep 04, 2019
  2. Sep 11, 2018
  3. Jul 17, 2018
  4. Jun 25, 2018
  5. Jun 21, 2018
  6. May 24, 2018
  7. Dec 04, 2017
  8. Dec 01, 2017
  9. Nov 16, 2017
    • Yorick Peterse's avatar
      Cache the number of user SSH keys · 3e561736
      Yorick Peterse authored
      By caching the number of personal SSH keys we reduce the number of
      queries necessary on pages such as ProjectsController#show (which can
      end up querying this data multiple times).
      
      The cache is refreshed/flushed whenever an SSH key is added, removed, or
      when a user is removed.
      Verified
      3e561736
  10. Aug 23, 2017
    • Yorick Peterse's avatar
      Cache the number of open issues and merge requests · 6ec53f5d
      Yorick Peterse authored
      Every project page displays a navigation menu that in turn displays the
      number of open issues and merge requests. This means that for every
      project page we run two COUNT(*) queries, each taking up roughly 30
      milliseconds on GitLab.com. By caching these numbers and refreshing them
      whenever necessary we can reduce loading times of all these pages by up
      to roughly 60 milliseconds.
      
      The number of open issues does not include confidential issues. This is
      a trade-off to keep the code simple and to ensure refreshing the data
      only needs 2 COUNT(*) queries instead of 3. A downside is that if a
      project only has 5 confidential issues the counter will be set to 0.
      
      Because we now have 3 similar counting service classes the code
      previously used in Projects::ForksCountService has mostly been moved to
      Projects::CountService, which in turn is reused by the various service
      classes.
      
      Fixes https://gitlab.com/gitlab-org/gitlab-ce/issues/36622
      Verified
      6ec53f5d
Loading