class GerritReview extends java.lang.Object
Gerrit review that can be used to comment on a gerrit patchset
import org.wikimedia.integration.GerritReview
import org.wikimedia.integration.GerritComment
stage('comment') {
comment = new GerritComment(
jobName: xx,
buildNumber: xx,
jobStatus: xx,
image: xx,
tags: xx
)
GerritReview.post(this, comment)
}
Type | Name and description |
---|---|
GerritComment |
comment GerritComment with information for message body |
java.lang.Object |
gerritAuthCreds Name of the auth credentials in jenkins to use in gerrit |
java.lang.Object |
gerritURL Gerrit URL |
java.lang.Object |
workflowScript Jenkins pipeline workflow script context. |
Constructor and description |
---|
GerritReview
(java.lang.Object workflowScript, GerritComment comment) |
Type Params | Return Type | Name and description |
---|---|---|
|
java.lang.String |
getBody() Format gerritcomment as a json message. |
|
java.lang.String |
getProject() URLEncoded ZUUL_PROJECT from the environment. |
|
java.lang.String |
getRequestURL() Return a full authorized url for a gerrit revision review. |
|
static java.lang.String |
post(java.lang.Object workflowScript, GerritComment comment) Static method to POST GerritComment to a particular change. |
Methods inherited from class | Name |
---|---|
class java.lang.Object |
java.lang.Object#wait(long), java.lang.Object#wait(long, int), java.lang.Object#wait(), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll() |
GerritComment with information for message body
Name of the auth credentials in jenkins to use in gerrit
Gerrit URL
Jenkins pipeline workflow script context.
Format gerritcomment as a json message.
URLEncoded ZUUL_PROJECT from the environment. This should be set for all patchsets.
Return a full authorized url for a gerrit revision review. May return an empty string in the cases of an unexpected environment.
Static method to POST GerritComment to a particular change. Uses the Gerrit RESTAPI to POST a comment on a patchset revision.
workflowScript
- Jenkins workflow script context.comment
- GerritCommentGroovy Documentation