new_relic v0.1.2 NewRelic.Plug.Phoenix
A plug that instruments Phoenix controllers and records their response times in New Relic.
Inside an instrumented controller's actions, conn
can be used for further instrumentation with
NewRelic.Plug.Instrumentation
and NewRelic.Plug.Repo
.
defmodule MyApp.UsersController do
use Phoenix.Controller
plug NewRelic.Plug.Phoenix
def index(conn, _params) do
# `conn` is setup for instrumentation
end
end
Link to this section Summary
Link to this section Functions
Link to this function
call(conn, config)
Callback implementation for Plug.call/2
.
Link to this function
init(opts)
Callback implementation for Plug.init/1
.