Allow only 1 thread to send a closure to a given machine at the same time
This prevents a race where multiple threads see that machine X is missing path P, and start sending it concurrently. Nix handles this correctly, but it's still wasteful (especially for the case where P == GHC). A more refined scheme would be to have per machine, per path locks.
This commit is contained in:
@ -32,7 +32,6 @@ bool has(const C & c, const V & v)
|
||||
|
||||
|
||||
State::State()
|
||||
: copyClosureTokenServer{maxParallelCopyClosure}
|
||||
{
|
||||
hydraData = getEnv("HYDRA_DATA");
|
||||
if (hydraData == "") throw Error("$HYDRA_DATA must be set");
|
||||
|
Reference in New Issue
Block a user