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

Gerrit Verified Commands ignored when RestAPI is enabled

XMLWordPrintable

      Took me a lot of time to figure it out... But it seems like the commands specified in "Gerrit Verified Commands" are ignored if RestAPI is enabled.

      The RestAPI has two functions:

      1. Event "Missed Events Playback" - I thought this is the only one.
      2. Review comments.

      If I read the code correctly, yhere is no way to distinguish between the two as far as I read the code:

      NotificationFactory::queueBuildStarted
      if (config.isUseRestApi() && event instanceof ChangeBasedEvent) {
      
      NotificationFactory::queueBuildCompleted
      if (config.isUseRestApi()
              && memoryImprint.getEvent() instanceof ChangeBasedEvent) 

       

      I guess there should be a switch in configuration if to use the "Verified Commands" via RestAPI or not, so that both "Missed Events Playback" and the "Verified Commands" can work.

      Currently I disabled the RestAPI as it is more important to have a custom command that sets a custom label.

            rsandell rsandell
            alonbl Alon Bar-Lev
            Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated: