batch-cluster
Advanced tools
Changelog
v5.6.2
BatchProcess
(which incurred GC
overhead even when disabled)Changelog
v5.6.0
BatchProcess.end()
didn't correctly implement gracefully
(which
resulted in spurious end(): called while not idle
errors), and allowed for
multiple calls to destroy and disconnect from the child process, which may or
may not have been ill-advised.Changelog
v5.5.0
BatchCluster.isIdle
. Updated development dependencies. Deflaked CI by embiggeningBatchClusterOptions.cleanupChildProcs
, in case you want to handle
process cleanup yourself.Changelog
v5.4.0
maxProcs
is respected again. In prior builds, if tasks were enqueued all
at once, prior dispatch code would only spin 1 concurrent task at a time.BatchProcess.end
would result in different promise
resolution targets: the second call to .end()
would resolve before the
first. This was fixed.minDelayBetweenSpawnMillis
was added, to help relieve undue system load on
startup. It defaults to 1.5 seconds and can be disabled by setting it to 0.Changelog
v5.2.0
🐞 BatchProcessOptions.pass
and .fail
had poorly specified and implemented failure semantics. Prior
implementations would capture a "failed" string, but not tell the task that
the service returned a failure status.
Task Parsers already accept stdout and stderr, and are the "final word" in resolving or rejecting Tasks.
v5.2.0
provides a boolean to Parser's callable indicating if the wrapped
service returned pass or fail, and the Parser may return a Promise now, as
well.
There's a new SimpleParser
implementation you can use that fails if stderr
is non-blank or a stream matched the .fail
pattern.
🐞 initial BatchProcess
validation uses the new SimpleParser
to verify the
initial versionCommand
.
✨ child process pids are delivered to event listeners on spawn and close. See BatchClusterEmitter.
🐞 fix "Error: end() called when not idle" by debouncing stdout and stderr
readers. Note that this adds latency to every task. See
BatchProcessOptions's
streamFlushMillis
option, which defaults to 10 milliseconds.
🐞 RegExp for pass and fail tokens handle newline edge cases now.
📦 re-added tslint and delinted code.