Uploaded image for project: 'SonarQube'
  1. SonarQube
  2. SONAR-2119 Analysis must not connect to database
  3. SONAR-6590

remove direct CE dependency on sonar-batch BatchReportReader

    XMLWordPrintable

    Details

    • Type: Sub-task
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 5.2
    • Component/s: Compute Engine
    • Labels:
      None

      Description

      ComputationStep implementation in CE are currently using the BatchReportReader class from the sonar-batch module directly.

      Using this class raises several issues:

      • this class reads files on disk. Therefor unit tests creates Protofbuf objects, writes them to disk, and Protobuf objects are then created again from these files => waste of time, memory, CPU and useless IOs
      • this is a class, we can not provide another implementation for unit tests unless we use mocks (doh!)
      • ComputationSteps could benefit from other methods that those defines by the sonar-batch class
        • eg. we could rather define methods returnings CloseableIterator of Protobuf objects than returning a File and have every step code the parsing

        Attachments

          Activity

            People

            Assignee:
            sebastien.lesaint Sebastien Lesaint
            Reporter:
            sns-seb OLD - S├ębastien Lesaint
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Due:
              Created:
              Updated:
              Resolved: