Uploaded image for project: 'SonarQube'
  1. SonarQube
  2. SONAR-5959

Change behavior of issue search query

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 5.1
    • Component/s: Issues
    • Labels:
      None

      Description

      Using the renamed WS parameters, the behavior of the search query should be:

      • If "onComponentOnly" is true, perform a simple term query on the right attribute (projectUuid, fileUuid, moduleUuid)
      • Else, also perform an include query on the modulePath attribute; the term query must be included to handle the case of issues directly on a project/module (e.g clirr)

      In other words, let's use a hierarchy like below:

      • Project A
        • File a
        • Module 1
          • File b
          • Module 2
            • File c

      If there is exactly one issue on each component, the results should be:

      • projectUuids=A&onComponentOnly=false : 6 issues (all issues from project)
      • projectUuids=A&onComponentOnly=true : 1 issue (only issue on project A)
      • moduleUuids=1&onComponentOnly=false : 2 issues (module + file)
      • moduleUuids=1&onComponentOnly=true : 1 issue (only issue on module 1)
      • moduleUuids=2&onComponentOnly=false : 2 issues (module + file)
      • moduleUuids=2&onComponentOnly=true : 1 issue (only issue on module 2)
      • componentUuids=A&onComponentOnly=false : 6 issues (all issues from component - project A - and descendants)
      • componentUuids=A&onComponentOnly=true : 1 issue (only issues from component - project A)
      • componentUuids=1&onComponentOnly=false : 4 issues (all issues from component - module 1 - and descendants)
      • componentUuids=1&onComponentOnly=true : 1 issue (only issues from component - module 1)
      • componentUuids=2&onComponentOnly=false : 2 issues (all issues from component - module 2 - and descendants)
      • componentUuids=2&onComponentOnly=true : 1 issue (only issues from component - module 2)
      • componentUuids=a&onComponentOnly=true/false : 1 issue (all issues from file a)
      • componentUuids=b&onComponentOnly=true/false : 1 issue (all issues from file b)
      • componentUuids=c&onComponentOnly=true/false : 1 issue (all issues from file c)

        Attachments

          Activity

            People

            Assignee:
            jb.lievremont OLD - Jean-Baptiste Lièvremont (Inactive)
            Reporter:
            jb.lievremont OLD - Jean-Baptiste Lièvremont (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Due:
              Created:
              Updated:
              Resolved: