[Buildbot-devel] Hooking a new TCP-listening service into the BuildMaster
Dustin J. Mitchell
dustin at zmanda.com
Thu Jan 31 20:34:35 UTC 2008
On Jan 31, 2008 3:14 PM, Greg Ward <gerg.ward+buildbot at gmail.com> wrote:
> But I'm stuck on that "check if a builder is available". Clearly I need
> to get my hands on the BuildMaster object. But my BuildTrigger class is
> outside the charmed inner circle of Buildbot's own code, even though
> it'll be running in the same process. So how do I find my way to the
> BuildMaster? I've read enough code that I strongly suspect the answer
> will involve Twisted services... but I don't quite see how to make it
> all work. Hints? Tips? Advice?
I've been tossing around the idea of adding a c['extra_services']
variable to master_cfg.py, which the buildmaster would start at
application startup. I don't have the patch handy, but it sounds like
your question would fit easily into that.
In the interim, it's probably easiest to just set up your class as a
service and instantiate it directly from the BuildMaster's
constructor, similar to the way self.botmaster is set up.
I'll try to get that patch in a bit. I've made a terrible mess of my
darcs repos at the moment :(
Storage Software Engineer
More information about the devel