Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Liam reported a problem when trying to restart wasm-wasi-component based applications using the /control/applications/APPLICATION_NAME/restart endpoint. The application would become unresponsive. What was happening was the old application process(es) weren't exit(3)ing and so while we were starting new application processes, the old ones were still hanging around in a non-functioning state. When we are terminating an application it must call exit(3). So that's what we do. We use the return value of nxt_unit_run() as the exit status. Due to exit(3)ing we also need to now explicitly handle the return on error case. Reported-by: Liam Crilly <[email protected]> Fixes: 20ada4b ("Wasm-wc: Core of initial Wasm component model language module support") Closes: nginx#1179 Tested-by: Liam Crilly <[email protected]> Tested-by: Danielle De Leo <[email protected]> Co-developed-by: Dan Callahan <[email protected]> Signed-off-by: Dan Callahan <[email protected]> Signed-off-by: Andrew Clayton <[email protected]>
- Loading branch information