PryIn v0.1.0 PryIn.Instrumenter

Collects metrics about view rendering and allows for custom instrumentation

Activate via:

config :my_app, MyApp.Endpoint,
  instrumenters: [PryIn.Instrumenter]

To instrument custom code, wrap it with the instrument macro:

  require MyApp.Endpoint
  MyApp.Endpoint.instrument :pryin, %{key: "expensive_api_call"}, fn ->
    ...
  end

The key ("expensive_api_call") is just a string that you can freely choose to indentify the metric later in the UI.

Summary

Functions

Collects metrics about Phoenix view rendering

Collects metrics about custom functions

Functions

phoenix_controller_render(atom, time_diff, runtime_metadata)

Collects metrics about Phoenix view rendering.

Metrics are only collected inside of tracked interactions.

pryin(arg1, compile_metadata, data)

Collects metrics about custom functions.

Wrap any code in an instrumented function to have it’s runtime reported to PryIn. The key parameter will be present in the web ui, so you can identify the measurement.

Note that you need to require your endpoint before calling the instrument macro.

Metrics are only collected inside of tracked interactions.