As I have some free time, 
I have tested this out using the parametrized trigger plugin.

Warning I am not a SVN user so these are all from reading docs and testing 
them out.


if Job A and Job B both checkout from the same URL, 
using the parametrised trigger in job A, add Subversion parameters this 
will then cause job B to use the same revision as was used in A.

if Job A and Job B checkout from different URLs but share revision ids the 
above case does not work as the revision seems to be tied to the URLs
however you can do this via 

using the parametrised trigger in job A, add Predefined parameters and 
setting a parameter 
JOBA_REVISION=@$SVN_REVISION

Then in Job B set  this build is parametrised and add a string Parameter 
with the name as
JOBA_REVISION
leave the default blank or set as @HEAD for latest 

then add to the end of the svn URL  /$JOBA_REVISION


tested using the ant svn repos listed under
http://ant.apache.org/svn.html 

Job A
Subvision Repo 
http://svn.apache.org/repos/asf/ant/core/trunk/
Predefined Parameter 
JOBA_REVISION=@$SVN_REVISION


Job B 
String Parameter
name = "JOBA_REVISION"
default = ""
Subvision Repo 
http://svn.apache.org/repos/asf/ant/ivy/ivyde/trunk/$JOBA_REVISION


In both cases if Job B is triggered by changes to the repo it will use that 
latest revision.

You might also want to look at the block when upstream/downstream is 
building to get them to run in the correct order.



Hope that helps you out.

Chris


On Wednesday, 7 March 2012 17:46:38 UTC, Ulli Hafner wrote:
>
> I have a simple setup of two projects A and B using subversion. Both use
> subversion polling as build trigger.
>
> Is the following use case possible (using the parameterized-trigger
> plug-in)?
>
> - When there is a change in A (SVN rev-x), then a successful build of A
> triggers a build of B with SVN rev-x (parameterized trigger).
> - When there is a change in B (SVN rev-x) and no change in A, then build
> B is triggered using rev-x (but no build of A)
> - When there is a change in A (SVN rev-x), and during this build a new
> revision rev-y is committed to project A and B, then I would like to
> have as next build project B with revision rev-x, then again project A
> with rev-y and then project B with rev-y. From the comments in the wiki
> it seems that after A rev-x a build of B rev-y is triggered. In that
> case I might get compile errors if the files in rev-y refer to classes
> in project A that are introduced in subversion rev-y.
>
> Ulli
>
>

Reply via email to