Jenkins Gerrit-Trigger not reporting +1 verified after successful job run Jenkins Gerrit-Trigger not reporting +1 verified after successful job run jenkins jenkins

Jenkins Gerrit-Trigger not reporting +1 verified after successful job run


In short this is a Gerrit permission issue for the Jenkins user.

The Gerrit trigger when submitting requests over the RESTAPI was including both "Verify" & "Code Review" votes. Now our Jenkins user only had the Verify permission, so any "Code Review" modification was forbidden (explains the 403 response code).

Now as a solution it wasn't practical to simply give the Jenkins user "Code Review" permissions. Instead theres an option to configure the Gerrit vote settings within the Jenkins Job:

"Gerrit Trigger" > click "Advanced..." > "Gerrit Reporting Values"

Under the "Verify" heading, adding "1" for successful, while ensuring all other fields are blank allows the RESTAPI to only send the verify +1 vote after the build.


In Jenkins >> Gerrit Trigger >> your server name >> Gerrit Reporting Values >> Advanced >> reset api, please check the ‘Enable Verified’.