January 2019
Intermediate to advanced
520 pages
14h 32m
English
Rust has good support for two debuggers—GDB and LLDB. We will try the second here. LLDB is a modern command-line debugger. It's a part of the LLVM project.
Let's try to look inside our working router microservice. Move to the directory with the microservice and compile it with the cargo build command. However, you have to be sure you don't set the --release flag, because it removes all debugging information. If you don't use cargo and want to add debugging information directly using rustc, add the -g -C debuginfo=2 arguments to keep debugging symbols in the output file. After the building is finished, use a command to start a debugger with scripts to support the Rust programming language:
rust-lldb ./target/debug/router-microservice ...
Read now
Unlock full access