Pprof

Pprof serves via its HTTP server fprof profiling data in the format expected by the pprof visualization tools for Elixir.

Pprof basically uses erlang :fprof and generates meaningful pprof data from noisy data of fprof profile.

Table of Contents

Documentation

Hex documentation: Pprof

Aim

The observation and profiling culture of erlang and elixir is different from other languages. Elixir/Erlang runs on a virtual machine (a.k.a beam) and each block of code represents a process. Erlang provides many tools internally for monitoring abstracted processes and processes dependent functions. This library produces as meaningful pprof output as possible using the built-in Erlang profiling tools. Thus, it tries to spread the Erlang/Elixir observability with pprof-based ad-hoc profiling tools.

# A few important things

# Installation and Usage

## Installation

    def deps do
     [
      {:pprof, "~> 0.1.0"}
     ]
    end

After:

    $ mix deps.get

## Usage

Add pprof config your config file like this:

    config :pprof, :port, 8080

You can use with go pprof:

    $ go tool pprof http://localhost:8080/debug/pprof/profile?seconds=5&type=fprof

Also using with Parca add configure in parca.yaml:

        # params:
        #   type: [ 'fprof' ]

# TODO

# Contributing

If you are an expert in elixir or erlang and want to contribute, please feel free. Who can say no to better written or more performant code? Thanks in advance for helping and teaching me so much.

# License

pprof is released under the MIT License.