Skip to content
Snippets Groups Projects
  1. Mar 18, 2021
    • alex pooley's avatar
      Cache namespace traversal path · 7fa6bcd8
      alex pooley authored
      Work towards replacing recursive namespace queries with linear queries.
      This commit tracks the path to each namespace, and future work will
      replace recursive queries with queries that utilize this new column.
      7fa6bcd8
  2. Mar 05, 2021
  3. Feb 24, 2021
  4. Feb 18, 2021
  5. Feb 16, 2021
    • Dylan Griffith's avatar
      Fix flaky epics_finder_spec race condition · 55c2a9bd
      Dylan Griffith authored
      As per https://gitlab.com/gitlab-org/gitlab/-/issues/321511 we've seen
      one of these tests fail. It seems likely the problem is caused by the
      use of `X.days.ago` throughout and then filtering with date ranges. The
      likely explanation is that when the test is running just before midnight
      then `2.days.ago` actually ends up being "3 days ago" from a date
      perspective by the time the assertion is made about it.
      
      Even though it's not easy to replicate this exact failure mode and this
      flakiness has never happened for this spec before (to my knowledge) in 3
      years it still is not a good way to write these kinds of tests as this
      is theoretically a problem.
      
      Instead of making all the times relative to "now" (which changes) I've
      just made everything relative to some arbitrary fixed time. This works
      fine, without any need for freezing time, as none of the methods being
      tested actually refer to the current time.
      
      The test is still quite difficult to read due to many different dates
      and times and the fact that the examples are separated from the test
      setup but I don't think this change makes it less clear.
      55c2a9bd
  6. Jan 21, 2021
    • Jan Provaznik's avatar
      Fix listing of epics by milestone · 77e16614
      Jan Provaznik authored
      When epics are filtered by milestone, this is done through `join` issues
      table. If an epic has multiple issues from the same milestone, then
      there are duplicit Epic instances returned - we should use distinct list
      in this case.
      77e16614
  7. Jan 11, 2021
  8. Nov 24, 2020
  9. Nov 18, 2020
  10. Oct 14, 2020
    • Nick Thomas's avatar
      Recover gracefully when issuable counts are too expensive · 517a05c7
      Nick Thomas authored
      On the MR list page, we like to display how many issues were found from
      the filtered search query *in total*. However, especially when the
      filter includes conditions on the MR title or description, this can be
      very expensive to calculate, and involve reading gigabytes of text data
      from the database.
      
      As long as the data is already in the page cache, this usually finishes
      within the 15-second timeout on GitLab.com, but if the database cache
      is cold, a statement timeout is the usual occurrence.
      
      More generally, it's not very clever to spend so much time calculating
      a piece of information with marginal value.
      
      This MR applies a shorter limit to the counting statements and provides
      for graceful fallback to a '?' value, with a nice tooltip, if the query
      times out. This means we're able to view the results in a reasonable
      time, rather than the page taking a long time to load, or not loading
      at all.
      517a05c7
  11. Sep 29, 2020
  12. Sep 03, 2020
  13. Aug 10, 2020
  14. Aug 04, 2020
  15. Jul 28, 2020
    • Eugenia Grieff's avatar
      Add milestone_title filter to EpicsFinder · 2944f413
      Eugenia Grieff authored
      -  Use a new method by_milestone in
      EpicsFinder to fetch milestone from params
      and filter epics that contain issues with
      given milestone
      - Add milestone_title argument to EpicsResolver
      - Add Finder and Resolver specs for filtering by
      milestone cases
      
      Update GraphQL schema
      
      Allow filtering by project milestones
      
      Update milestone_title argument description
      
      - Update GraphQL schema
      
      Use hierarchy params to determine milestones
      
      - If include_ancestor_groups or
      include_descendant_groups params are present these
      groups and their projects will be included in
      MilestoneFinder
      
      Add specs for filter by milestones with hierarchy
      2944f413
  16. Jul 27, 2020
  17. Jul 24, 2020
  18. Jul 07, 2020
  19. Jun 25, 2020
    • Jan Provaznik's avatar
      Ignore permission checking when counting epics · 9ed00f86
      Jan Provaznik authored
      When showing epics count on group show page, we just
      count all epics in the group and its subgroups no matter if
      user can see them or not. This is consistent with showing
      epic's child counts (where accessibility check is skipped too).
      9ed00f86
  20. Jun 24, 2020
  21. Jun 23, 2020
    • Jan Provaznik's avatar
      Optimize subgroup permission checking · 149f0fd6
      Jan Provaznik authored
      When finding epics, first check if user is member of top-level
      group, if so there is no need to check al subgroups - we just
      assume the user inherits permissions.
      149f0fd6
  22. Jun 05, 2020
  23. Jun 03, 2020
  24. May 19, 2020
  25. May 15, 2020
  26. May 13, 2020
  27. May 07, 2020
    • Felipe Artur's avatar
      Use EpicsFinder when fetching epics · 5719a5a5
      Felipe Artur authored
      This is part of the work to implement confidential epics.
      
      Use EpicsFinder to fetch epics on autocomplete and check
      for right permissions when exposing issues epics on API.
      5719a5a5
  28. Mar 31, 2020
  29. Mar 03, 2020
    • Patrick Derichs's avatar
      Add possibility to search for partial iids on EpicResolver · e31c1bfa
      Patrick Derichs authored
      Also add specs and update GraphQL schema
      
      Make EpicsFinder able to search for epics which
      start with a partial iid
      
      Constructs a combined where clause which includes all possible
      combinations for the given iid start string which would take advantage
      of the existing index on epics table.
      
      Use LIKE query for iid search with specialized index
      
      Add index for searching epics by iid and group_id
      
      Remove obsolete scopes and specs
      
      Change changelog entry
      e31c1bfa
  30. Sep 26, 2019
  31. Sep 16, 2019
  32. Jul 25, 2019
  33. May 29, 2019
  34. May 07, 2019
    • James Edwards-Jones's avatar
      Enforce active Group SAML SSO session · 11e0c6ea
      James Edwards-Jones authored
      Prevents access to group resources when user hasn't signed in with SAML
      and SSO enforcement is turned on.
      
      Uses the session to track which SAML group the user has signed in with.
      This works using global GitLab::Session from the policy via SsoState.
      11e0c6ea
  35. Jan 24, 2019
  36. Dec 20, 2018
  37. Dec 17, 2018
    • Jan Provaznik's avatar
      Support both integer and string as epic count key · 700bd970
      Jan Provaznik authored
      Epic state uses enum for saving state (other issuables use
      string), because of this inconsistency we override `count_key`
      which should return state as string converted to symbol
      (.e.g. :closed). In rails 5 these integer states are automatically
      converted to strings by Active Record.
      
      But if subquery is used (to optimize searching), Active Record doesn't
      convert state into string automatically (probably it can not deal with
      the more complex query).
      
      This means that epic state can be either integer (if subquery is used)
      or string (if AR converted state to string automatically), so in
      `count_key` we should convert state into string only if it's an integer.
      700bd970
  38. Dec 07, 2018
  39. Sep 27, 2018
Loading