> On Oct 17, 2022, at 6:11 AM, Daan Hoogland <daan.hoogl...@gmail.com> wrote:
> 
> - can a jenkins job be restarted for the apache jenkins server for the
> exact same (merged) code? It seems the analysis job doensn´t start correctly

        Broadly, yes.  The caveat here is that Jenkins is branch aware and 
tends to use the last commit to a branch as the place where restarts  tend to 
happen.  This means if you need a _specific_ commit on a branch that has had 
additional commits, then you’ll need something to mark that location with 
something that Jenkins sees (branch, pr, and tags if configured). There are 
some tricks to work around that “limitation.”  But in practice, it generally 
isn’t one since the vaaaaaast majority of time, people seem to want to always 
test the latest commit of their branch/pr/tag.

> - can the apache jenkins job be started from a PR if it wasn't added for
> some reason.

        The same trick mentioned above is basically to change your job to take 
the repo/commit info and forcibly check that out. But if the PR isn’t showing 
up, something else went wrong, especially if a Scan Repository isn’t pulling in 
the PR but others are there.  (I’m assuming Github Multibranch is being used… 
if something else is being used, Step 1: switch to GHMB!)


Reply via email to