Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F7687726
README.md
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Award Token
Flag For Later
Size
884 B
Referenced Files
None
Subscribers
None
README.md
View Options
#
PrometheusPhx
A
Phoenix
1.5
+
telemetry
handler
for
Prometheus
##
Getting
Started
You
can
add
PrometheusPhx
as
a
dependency
in
your
`
mix
.
exs
`
file
.
In
Phoenix
1.5
the
telemetry
instrumentation
was
changed
and
events
have
to
be
handled
.
This
prevents
libraries
like
`
prometheus
-
phoenix
`
from
working
with
newer
versions
of
phoenix
.
So
there
are
some
minimum
requirements
.
PrometheusPhx
does
require
Elixir
1.7
or
greater
and
Phoenix
1.5
or
greater
.
```
elixir
def
deps
do
[
{
:
prometheus_phx
,
github
:
"theblitzapp/prometheus-phx"
}
]
end
```
After
running
`
mix
deps
.
get
`
you
can
add
the
prometheus
-
phx
setup
call
to
your
application
module
.
```
defmodule
MyPhoenixApp
.
Application
do
use
Application
def
start
(
_type
,
_args
)
do
children
=
[
MyPhoenixApp
.
Endpoint
.
...
]
PrometheusPhx
.
setup
()
Supervisor
.
start_link
(
children
,
[])
end
end
```
File Metadata
Details
Attached
Mime Type
text/x-ruby
Expires
Wed, Sep 3, 11:18 PM (1 d, 19 h)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
439362
Default Alt Text
README.md (884 B)
Attached To
Mode
R25 prometheus-phx
Attached
Detach File
Event Timeline
Log In to Comment