New Relixir v0.4.3 NewRelixir.Instrumenters.Plug View Source

New Relic instrumenter for raw Plug endpoints.

To start recording, attach plug NewRelixir.Instrumenters.Plug at the beginning of your pipeline:

defmodule MyApp.PlugRouter do
  use Plug.Router

  plug NewRelixir.Instrumenters.Plug

  plug :match
  plug :dispatch

  get "/hello" do
    send_resp(conn, 200, "Hello!")
  end
end

Transaction records are composed of the current request path and method, e.g. /path/to/my-page#GET, /path/to/update#POST.

Link to this section Summary

Functions

Callback implementation for Plug.call/2

Callback implementation for Plug.init/1

Link to this section Functions

Callback implementation for Plug.call/2.

Callback implementation for Plug.init/1.