Buildbot multiple slaves working on same directory efficiently

225 Views Asked by At

I am using "buildbot" to accommodate some git projects, however I cannot seem to write it in an efficient manner. Lets say I have a project named "Project" and have 3 different componenets within them namely "A", "B", "C" and have three different builders for them namely "Builder_A", "Builder_B", "Builder_C". Currently the scripts for the builders are almost same, except they are building different components within them. Here is my sample build routine for each builder.

make clean
git checkout
make 
run sample tests

The problem occurs at git checkout, each bot is doing this step separately. However, if only one did this step it would be better in performance. How can I achieve this? Thanks in advance.

1

There are 1 best solutions below

3
On BEST ANSWER

What I read you suggesting is that one builder should checkout your source and then the other builders would depend on this first builder to get their source rather than perform their own checkout. I would advise against this. In effect this makes builders dependent on the files that are present in the working directory of another builder. It is possible to write a configuration that will do this but it will complicate your configuration quite a bit.

There are other things you can do:

  1. Use the shallow option so that git does not fetch the whole history of a project. This would enable you to continue using clobber (as you mentioned in a comment).

  2. Use an option other than clobber. fresh, for instance.