From ddacd902282f751fca448de9c51f8d133e337472 Mon Sep 17 00:00:00 2001 From: Nitzan Uziely Date: Sun, 7 Feb 2021 01:39:54 +0200 Subject: [PATCH] child_process: add timeout to spawn and fork Add support for timeout to spawn and fork. Fixes: https://github.com/nodejs/node/issues/27639 --- doc/api/child_process.md | 16 +++++- lib/child_process.js | 26 ++++++++-- ...-child-process-fork-timeout-kill-signal.js | 50 +++++++++++++++++++ ...child-process-spawn-timeout-kill-signal.js | 50 +++++++++++++++++++ 4 files changed, 135 insertions(+), 7 deletions(-) create mode 100644 test/parallel/test-child-process-fork-timeout-kill-signal.js create mode 100644 test/parallel/test-child-process-spawn-timeout-kill-signal.js diff --git a/doc/api/child_process.md b/doc/api/child_process.md index b7fce216282012..5c3a8d34f050c9 100644 --- a/doc/api/child_process.md +++ b/doc/api/child_process.md @@ -351,6 +351,9 @@ controller.abort();