ZcashFoundation / zebra

Zcash - Financial Privacy in Rust 🦓
https://zfnd.org/zebra/
Apache License 2.0
407 stars 98 forks source link

fix(rpc): modify shutdown used in `stop()` #8863

Closed oxarbitrage closed 1 week ago

oxarbitrage commented 2 weeks ago

Motivation

The std::process::exit I introduced for the stop RPC method is not a good idea for the rpc testing because (among other issues) it terminates immediately and the tests require for the method to return before actually finishing with the current process.

Additionally this is a more graceful shutdown and will close https://github.com/ZcashFoundation/zebra/issues/8850

Solution

Terminate the process by sending a SIGINT signal.

PR Author's Checklist

PR Reviewer's Checklist