Revert "embedding: make Stop() stop Workers"
Revert "embedding: make Stop() stop Workers"
This reverts commit 037ac99e.
As flaky CI failures have revealed, this feature was implemented
incorrectly. stop_sub_worker_contexts()
needs to be called on the
thread on which the Environment
is currently running, it’s not
thread-safe. The current API requires Stop()
to be thread-safe,
though.
We could add a new API for this, but unless there’s demand, that’s
probably not necessary as FreeEnvironment()
will also stop Workers,
which is commonly the next action on an Environment
instance after
having Stop()
called on it.
Refs: https://github.com/nodejs/node/pull/32531
src,test: add regression test for nested Worker termination
This adds a regression test for terminating a Worker inside which another Worker is running.
Checklist
-
make -j4 test
(UNIX), orvcbuild test
(Windows) passes -
tests and/or benchmarks are included -
commit message follows commit guidelines