Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-50783

Support file based comments

    XMLWordPrintable

Details

    • gerrit-code-review-0.2

    Description

      Hi,

      It would be super great to be able to submit a file based (given file + lineno) comments and not only change comments.

      This will enable to make use of gerrit as frontend for managing warnings/errors of build, static code analysis (such as sonar or style) etc...

      As far as I imagine there can be two ways to perform this:

      1. The simple - have an optional array of [

      {file, lineno, comment}

      ] provided to the current API.

      2. The cool - use a transaction syntax such as:

      withGerritReview() {
          gerritAddComment("file1", 12, "bla bla")
          gerritAddComment("file2", 44, "bla bla sdf")
          gerritSetFlag("Code-Review", "+1")
      }
      

      Please also keep in mind parallel work. I could not understand how the magic of triggering is working due to lack of documentation, however, if a parallel job is invoked it should share the context/state of the parent job so that the parallel job can also add its information, two options here as well:

      1. The simple - parallel job has its own comments, share is only the change information, can be given as standard job parameters.

      2. The super-cool - the parallel job, if called within transaction context will be able to append to the existing transaction, share the change information + the state of transaction.

      Thank you for working on this, I am looking forward to be able to switch.
      Alon

      Attachments

        Activity

          People

            lucamilanesio Luca Domenico Milanesio
            alonbl Alon Bar-Lev
            Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: