Concurrent builds with common sub project

Hi all,

our build currently fails from time to time and my guess is that it is due to two concurrent gradle builds. These two builds are from the same root project, but started from different sub-projects. At some point they have a common project dependency (some codegen and java compile project). Is this allowed by gradle’s design ? If yes, how can I enforce a critical section around two or three tasks or the whole project ? It looks like the two builds are running in two daemons. Version is 1.6