[Buildbot-devel] modules, reconfig, lazy_reload & a better alternative?

Vitali Lovich vlovich at gmail.com
Sat Jan 24 23:26:49 UTC 2015

> On Jan 24, 2015, at 2:17 AM, Pierre Tardy <tardyp at gmail.com> wrote:
> Idea is that all things that you need to reconfigure are put in the yaml files, not in python. reconfig will just load new version of yaml files, and the problem is solved..
> If you need a change to the python logic, then you'll need a restart.
> Thinking of that, I am generating factories in my python code, so that would never work, unless I add a level of indirection, generating the config files instead.
> For this kind of usecase, I've been working on buildbot_travis lately:
> https://github.com/isotoma/buildbot_travis/pull/5 <https://github.com/isotoma/buildbot_travis/pull/5>
> You can look at the code to see how the factories are generated dynamically based on config files stored on the source code itself.
> Then it would be interesting, should Buildbot provide some sort of standard configuration format that a general factory reads and created Buildbot objects from.  But I suppose there ain't such a thing.
> This discussion comes back from time to time. Its actually pretty difficult to create a one size fits all design that would make everybody happy.
Coming up with some kind of IPC mechanism might be feasible, but every step would have to support serialization across the wire (& probably a lot of other stuff too).

> But generally, code as configuration is very powerful, and the main point that hooks me on Buildbot. But if there were a configuration format with code supporting its creation, it would be even sweeter.
> Dan has made some attempt for simple configurations, and it is available here:
> https://github.com/buildbot/buildbot/blob/master/master/contrib/SimpleConfig.py <https://github.com/buildbot/buildbot/blob/master/master/contrib/SimpleConfig.py> 
> Ideally, I would only change my "imports" to another name space, run my buildbot configuration code, and it would output stuff, that can be used loaded and updated to a  master.cfg.
> If you go as crazy as generating json to generate your conf, you can just spawn a new python process for your generation code. 
> Pierre

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://buildbot.net/pipermail/devel/attachments/20150124/2db0e1a9/attachment.html>

More information about the devel mailing list