Hi,

I'm not sure if you've received any response, but I see two possible solutions:

* create a separate job in Jenkins for these merges, subscribe to the "code 
review approved" events from Github and work from that
* in the pipeline, create an "infinite loop" with some sensible upper limit 
(like 3 days) to wait for the code review to happen, check the PR state in a 
loop and then sleep some minutes to save computational power and when the PR is 
approved, do the merge. Or if the time limit is up, exit the job with failure.

Both of them have advantages and disadvantages: the second one is more aligned 
with the "1 job for 1 PR" idea, but the waiting in loop wastes computational 
power and also keeps agents reserved. In this regard the first one is much 
better, but then the testing and merging actions are done by separate jobs.

I don't know technical details about how to implement these since I don't use 
the Github plugin, but I hope these ideas help.
BR,
Laszlo


On 20 Feb 2019, at 19:35, Sameera Priyatham Tadikonda 
<priyathamj...@gmail.com<mailto:priyathamj...@gmail.com>> wrote:

I integrated Jenkins with Github using web hooks and I created a multi-branch 
pipeline and I am using JenkinsFile.

Jobs are created automatically and I am able to run the tests when a PR is 
created.Once the tests are passed my pipeline waits for the code review to be 
completed before merging.

I would like to merge the PR when the code review is done.

I am pushing all the Web hook events from Github to Jenkins.

How can I resume my pipeline when a code-review event is pushed to my Jenkins.

Please help me if anyone worked on this.

--
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to 
jenkinsci-users+unsubscr...@googlegroups.com<mailto:jenkinsci-users+unsubscr...@googlegroups.com>.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/e1f72226-99c6-4221-acfb-8047c76805c4%40googlegroups.com<https://groups.google.com/d/msgid/jenkinsci-users/e1f72226-99c6-4221-acfb-8047c76805c4%40googlegroups.com?utm_medium=email&utm_source=footer>.
For more options, visit 
https://groups.google.com/d/optout<https://groups.google.com/d/optout>.

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/9BDCD0C4-6E23-4F07-8804-7A05B06432D0%40skyscanner.net.
For more options, visit https://groups.google.com/d/optout.

Reply via email to