1
0
Fork 0
mirror of https://we.phorge.it/source/arcanist.git synced 2024-12-01 19:22:41 +01:00

Limit arc branch to 16 concurrent processes

Summary:
Currently, this spawns 125 concurrent processes on my machine, which overflows some limit and gives me an error:

  PHP Warning:  proc_open(): unable to create pipe Too many open files in /INSECURE/devtools/libphutil/src/future/exec/ExecFuture.php on line 491

Instead, limit parallelism to 16. The runtime is approximately the same for me, and dominated by other concerns (conduit calls).

Test Plan: Ran `arc branch` successfully. Ran `arc branch --trace`, observed behavior.

Reviewers: btrahan

Reviewed By: btrahan

CC: aran

Differential Revision: https://secure.phabricator.com/D4336
This commit is contained in:
epriestley 2013-01-07 08:44:55 -08:00
parent cf8d445c9f
commit 72b2b7b22c

View file

@ -149,7 +149,7 @@ EOTEXT
$branches = ipull($branches, null, 'name'); $branches = ipull($branches, null, 'name');
foreach (Futures($futures) as $name => $future) { foreach (Futures($futures)->limit(16) as $name => $future) {
list($info) = $future->resolvex(); list($info) = $future->resolvex();
list($hash, $epoch, $tree, $desc, $text) = explode("\1", trim($info), 5); list($hash, $epoch, $tree, $desc, $text) = explode("\1", trim($info), 5);