[Buildbot-devel] Svnpoller with externals
Eveque, Philippe
philippe.eveque at hp.com
Wed Apr 30 14:19:27 UTC 2008
Some collegues having some similar needs.
For Me, this raises the following:.
May be if you can "componentize" things in the repoB and make a "package" of it,
(with proper API) Then you do not end in having this needs anymore.
So code refactoring might be a better alternative.
Ok, As in our case it is not always practical.
Then extending your example:
if you have, say, N svn repos with svn external references intead of just 2,
with one parent (RepoA) and N-1 children (repoB,C,D,...) then with a table of
revision_number_from_svnurls it could also work. Ok it could be not that great
if the number of svn external references are many (but then there is a real refactoring need :-) )
(Note that would practically work only for limited trees of svn repos)
More generally, as I understand it, it seems that for each file participating to the build process, buildbot needs to keep their explicit svn URL+version at some point.
Then having an extension so that builbot can consider a loosely "aggregated" svn repo
from multi svn repo using svn externals or not.
Not sure about the impacts on BB (my knowledge is too low), but seems linked to the need
for master and slave to be able to interact with N svn repos and their respective set-up.
Phil.
> -----Original Message-----
> From: buildbot-devel-bounces at lists.sourceforge.net
> [mailto:buildbot-devel-bounces at lists.sourceforge.net] On
> Behalf Of Matisse Enzer
> Sent: mardi 29 avril 2008 18:54
> To: GD
> Cc: 'BuildBot Devel'
> Subject: Re: [Buildbot-devel] Svnpoller with externals
>
> Here is a new idea that sort of touches on this issue of using
> buildbot with SVN externals:
>
> - We have two repositories, RepoA and RepoB.
> - We have a project in RepoA that uses files from RepoB.
> - We would would like to set up RepoA like this:
>
> https://repoA/svn/trunk/project-puffball/
> reference_files/ svn:externals set on this dir
> svn+ssh://repoB/trunk/some-code/
> svn+ssh://repoB/trunk/more-code/
>
> Then, in buildbot we have three change sources defined which poll:
>
> https://repoA/svn/trunk/project-puffball/
> svn+ssh://repoB/trunk/some-code/
> svn+ssh://repoB/trunk/more-code/
>
> and our build factories have as their first step:
>
> f1.addStep(source.SVN,
> baseURL="https://repoA/svn/trunk/project-puffball/",
> defaultBranch="",
> mode="clobber")
>
> The ALMOST works.
>
> What happens is that when a commit happens inside one of the external
> directories (in RepoB) the poller does see it, and a build does get
> triggered, but, the SVNPoller reports the revision number from repoB
> (which is reasonable) but the factory tries to use that revision
> number during the checkout from repoA which is wrong.
>
> So, a possible solution, that i am looking for feedback on:
>
> - We create a subclass of SVNPoller that overrides the constructor and
> create_changes.
> - The sub-class constructor takes an additional svn URL:
> revision_number_from_svnurl
> - The sub-class create_changes() gets the revision number of the
> revision_number_from_svnurl
> and then calls the super class create_changes() and then
> iterates over the changes, replacing the revision with the number
> from revision_number_from_svnurl.
>
> What do you all think of this?
>
More information about the devel
mailing list