Skip to content

Profiling deployed binaries in real-time with flame graphs and plots.

License

MIT, BSD-3-Clause licenses found

Licenses found

MIT
LICENSE
BSD-3-Clause
LICENSE_internal_pkg
Notifications You must be signed in to change notification settings

wirelessregistry/goprofui

Repository files navigation

goprofui

A simple package for profiling deployed binaries.

Key features:

  • Does not require running any other scripts/tools, only the binary under monitoring.
  • Flame graphs for stack trace profiling.
  • Memory, GC pauses and goroutines line charts.

Related Work

Installation

go get github.com/wirelessregistry/goprofui

Dependencies

  1. Requires the net web-socket library https://godoc.org/golang.org/x/net/websocket.

  2. The flame graph JS library is https://github.com/spiermar/d3-flame-graph.

  3. The line chart JS library is D3's.

  4. goprofui's internal package is forked from pprof's internal package. It is covered by the BSD-license in LICENSE_internal_pkg.

Usage and Code Structure

The quickest way to get started is to copy the handlers' setup from examples/web/web.go. Build the web.go application, and then serve the index.html file using a web server (https://github.com/indexzero/http-server for example).

When you visit the example using your web browser, you will see some graphs:

  • Alt text
  • Alt text
  • Alt text

The cpu profiling code is in cpu.go. The memory, GC latency and goroutines stats are obtained in tickerHandlers.go.

About

Profiling deployed binaries in real-time with flame graphs and plots.

Resources

License

MIT, BSD-3-Clause licenses found

Licenses found

MIT
LICENSE
BSD-3-Clause
LICENSE_internal_pkg

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published