How can I get the thread stack trace of a running rust program? With Java I do a kill -QUIT and I can get the thread dump on the console. Thanks in advance.
...or in the meanwhile, the current implementation is based on the
backtrace crate, so you could use that instead.
Rust doesn't have a runtime per se, so I think you'll have to handle signals yourself if you want that functionality. I imagine you'd have to "manually" poll for a signal flag in choice locations given the limitations of signal handlers (but I didn't look into it in depth).
rstack-self crate provides infrastructure to do a full process thread dump: rstack_self - Rust
This topic was automatically closed 90 days after the last reply. We invite you to open a new topic if you have further questions or comments.