Jenkins does see and build the commit right away, but the fact that the commit passed its test is not getting passed back to Gerrit. I can apply "+1 Verified" manually to a patch set, and that works, but this mode of operation is not particularly ideal. (Some other points of information: I can issue Gerrit queries in Jenkins under "Query and Trigger Gerrit Patches". This works, but if I trigger a selected search result in order to trigger a build, it still doesn't result in the "+1 Verified" making it to Gerrit. Additionally, the Gerrit user that Jenkins uses to do this is authorized to apply +1 Verified to refs/* in Gerrit.
[1] https://wiki.jenkins-ci.org/display/JENKINS/Gerrit+Trigger
Jason
> --
> To unsubscribe, email repo-discuss...@googlegroups.com
> More info at http://groups.google.com/group/repo-discuss?hl=en
>
> Assuming this [1] is the gerrit plugin you're using you should verify
> that in the gerrit trigger settings (under
> manage-jenkins->gerrit-trigger) that success is set to 1 and failed is
> set to -1. Although I think those are the defaults.
Yes, those are set correctly, but I now have a better inkling of
what's going on. I found in the Gerrit Trigger Jenkins config the
section that specifies the ssh commands that are issued to Gerrit's
built-in ssh server. I've been able to successfully get the "+1
Verified" into Gerrit by typing the following to bash:
$ ssh jenkins@gerrithost -p 29418 gerrit review --project
gerrit-sandbox --message=Hi --verified 1 10,1
The apparent cause of the problem is that while the above succeeds, it
never actually returns. This explains why I've been seeing comments in
Gerrit that look like this:
Jenkins Nov 29
Patch Set 1:
Build Started
http://jenkins.foo.org:28080/jenkins/job/Gerrit%20Sandbox%20(for%20review)/27/
I.e., the ssh command that tells Gerrit that the build has started
succeeds, but then it never returns. So then Jenkins never gets around
to issuing the ssh command that sends the "Verify +1", since Jenkins
is still waiting for the previous ssh command to finish.
If I put in a nonexistent change id into the ssh command, on the other
hand, the ssh *does* return, after outputting an error message.
Any ideas what might be causing this problem?
|>ouglas
|>ouglas
--
To unsubscribe, email repo-discuss...@googlegroups.com
More info at http://groups.google.com/group/repo-discuss?hl=en
The review command does actually work when I execute it manually.
Although it never returns, as I mentioned in my previous message. I'm
guessing that it's the not-returning issue that is causing the
problem.
As to whether the jenkins user has the "Label Verified" permissions,
the Jenkins user is in the "Non-Interactive Users" group and the
All-Projects project grants -1/+1 Label Verified on refs/* to
Non-Interactive Users. The gerrit-sandbox project is set with "Rights
Inherit From: All-Projects".
|>ouglas
> Try restarting the connection between gerrit-trigger plugin and Gerrit.
> If this doesn't help try restarting Jenkins.
I've tried all of those things, and many more. I've moved this
question to here:
http://groups.google.com/group/repo-discuss/browse_frm/thread/efb5286e993df62c?hl=en#
as I now have a great deal more evidence about what is causing the
problem.
|>ouglas