[Buildbot-devel] multiple subversion repositories

Brian Warner warner-buildbot at lothar.com
Mon Jan 23 23:15:34 UTC 2006


> I am trying to setup a single buildmaster that has multiple subversion
> repositories (project1 and project2).  I have two schedulers, one for
> each repository that uses the fileIsImportant, and I currently have to
> builders, one to build each repository.
...
> And of course, since project2 doesn't have a revision 3000 or 3001 it
> fails when checking out the code.  I'm confused as to why each scheduler
> is queuing up the changes of the other scheduler even when the
> filesIsImportant is returning false.

Ah. The fileIsImportant() function was originally meant for distinguishing
documentation files from source code. The idea was that you wouldn't want to
waste CPU time doing a compile and test when the only thing that had changed
in your source tree were some HTML files that weren't used in the build
anyway. But, you also don't want to exclude those changes forever. So
fileIsImportant just puts off the build. (specifically it doesn't schedule a
new one unless there are some files that *are* important in the Change). The
next build that happens (because of changes to other files) *will* include
the "unimportant changes" too.

To handle completely separate subprojects, you need something else. I'd
suggest making a subclass of Scheduler which completely ignores the Changes
that occur on the wrong subproject, rather than merely marking them as
unimportant. You'd do this in the addChange() method, by simply returning
without doing anything if the change is not a part of the subproject you're
handling. You'll have two such Schedulers, one for each subproject. Each
Scheduler would then trigger its own Builder, just as you were doing before.

Is there any particular reason you want both projects to be handled by the
same buildmaster? It may be the case that the projects are better served by
separate buildmaster instances. Our multiple-subproject support isn't very
strong right now, but to figure out what needs to be done to improve it, it
would help me to understand what your motivations.. are the subprojects being
combined together somehow? Are there buildsteps which use source code from
both projects together at some point? Or is it just a reporting convenience,
having one web page instead of two?

thanks,
 -Brian





More information about the devel mailing list