[Buildbot-devel] acquiring multi-step locks/lock until the end of the build

Vitali Lovich vlovich at gmail.com
Fri Feb 13 16:36:26 UTC 2015


Is there a straightforward way to acquire a lock for the remainder of a build?

It looks like we have 2 kinds of locking strategies at the moment:
Up-front locks for each build generated by a builder
Step-level locks acquired only for the duration of a single step
The two that are super-useful but missing:
Acquire a lock for the next N steps or until some later step (worst case is acquire/release steps but probably can be done more elegantly as “lock until build step with name X” or “lock for next Y steps").
Acquire a lock for the remainder of the build.
Does anyone know if the latter is easy to inject?  I haven’t looked into it yet; I’m hoping that it would be possible but maybe someone has looked into this already & has thoughts?
Any pointers on which class owns the locks?

I already have a custom Build class & am OK mucking with the internal state of a build.
I’m looking primarily at option #2 - would I get away with generating a lock & then appending it to some internal state in Build
for it to get unlocked at the end of the build?

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

More information about the devel mailing list