BigW Consortium Gitlab

  1. 29 Mar, 2016 2 commits
  2. 21 Mar, 2016 2 commits
  3. 20 Mar, 2016 3 commits
  4. 17 Mar, 2016 3 commits
  5. 16 Mar, 2016 1 commit
  6. 14 Mar, 2016 1 commit
  7. 13 Mar, 2016 3 commits
  8. 12 Mar, 2016 4 commits
  9. 11 Mar, 2016 2 commits
  10. 10 Mar, 2016 3 commits
  11. 07 Mar, 2016 1 commit
  12. 05 Mar, 2016 1 commit
  13. 20 Feb, 2016 2 commits
  14. 19 Feb, 2016 2 commits
  15. 18 Jan, 2016 1 commit
    • Scope issue projects to a Group when possible · d6a8021e
      Yorick Peterse authored
      When using IssuableFinder with a Group we can greatly reduce the amount
      of projects operated on (due to not including all public/internal
      projects) by simply passing it down to the ProjectsFinder class.
      
      This reduces the timings of the involved queries from roughly 300
      ms to roughly 20 ms.
      
      Fixes gitlab-org/gitlab-ce#4071, gitlab-org/gitlab-ce#3707
  16. 07 Jan, 2016 1 commit
    • Drop projects order in IssuableFinder · fc443ea7
      Yorick Peterse authored
      When grabbing the projects to filter issues by we don't care about the
      order they're returned in. By removing the ORDER BY the resulting query
      can be quite a bit faster.
  17. 04 Jan, 2016 1 commit
  18. 03 Dec, 2015 1 commit
  19. 20 Nov, 2015 1 commit
    • Port GitLab EE ProjectsFinder changes · fed059a1
      Yorick Peterse authored
      These changes were added in GitLab EE commit
      d39de0ea91b26b8840195e5674b92c353cc16661. The tests were a bit bugged
      (they used a non existing group, thus not testing a crucial part) which
      I only noticed when porting CE changes to EE.
  20. 19 Nov, 2015 3 commits
    • Use a JOIN in IssuableFinder#by_project · 8591cc02
      Yorick Peterse authored
      When using IssuableFinder/IssuesFinder to find issues for multiple
      projects it's more efficient to use a JOIN + a "WHERE project_id IN"
      condition opposed to running a sub-query.
      
      This change means that when finding issues without labels we're now
      using the following SQL:
      
          SELECT issues.*
          FROM issues
          JOIN projects ON projects.id = issues.project_id
      
          LEFT JOIN label_links ON label_links.target_type = 'Issue'
                                AND label_links.target_id  = issues.id
      
          WHERE (
              projects.id IN (...)
              OR projects.visibility_level IN (20, 10)
          )
          AND issues.state IN ('opened','reopened')
          AND label_links.id IS NULL
          ORDER BY issues.id DESC;
      
      instead of:
      
          SELECT issues.*
          FROM issues
          LEFT JOIN label_links ON label_links.target_type = 'Issue'
                                AND label_links.target_id  = issues.id
      
          WHERE issues.project_id IN (
              SELECT id
              FROM projects
              WHERE id IN (...)
              OR visibility_level IN (20,10)
          )
          AND issues.state IN ('opened','reopened')
          AND label_links.id IS NULL
          ORDER BY issues.id DESC;
      
      The big benefit here is that in the last case PostgreSQL can't properly
      use all available indexes. In particular it ends up performing a
      sequence scan on the "label_links" table (processing around 290 000
      rows). The new query is roughly 2x as fast as the old query.
    • Memoize IssuableFinder#projects · e9cd58f5
      Yorick Peterse authored
      Since this method's returned data doesn't change between calls on the
      same IssuableFinder instance we can just memoize this similar to the
      "project" method.
  21. 18 Nov, 2015 2 commits