Using the pprof tool

The pprof tool allows Go applications to collect and export runtime profiling data. It also provides webhooks to access the tool from a web interface. This recipe will create a basic application that verifies a bcrypt-hashed password against a plaintext one, then it will profile the application.

You might have expected the pprof tool to be covered in Chapter 11, Distributed Systems, with other metrics and monitoring recipes. It was instead put in this chapter because it will be used to analyze and improve a program much in the same way that benchmarking can be used. As a result, this recipe will largely focus on pprof for analyzing and improving the memory usage of an application.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
52.14.84.29