arkgil

arkgil

Telemetry.Metrics - common interface for defining metrics based on Telemetry events

Hi everyone :wave:

We’ve just pushed Telemetry.Metrics 0.2.0 to Hex. Version 0.1.0 has been published for a while now, but this version finally makes the library compatible with Telemetry 0.4.0 and brings many other improvements.

In short, Telemetry.Metrics allows you to define how you wish the Telemetry events to be aggregated. For example, the following metric definition

sum("http.request.payload_size")

means that you want to sum up :payload_size measurement of the [:http, :request] Telemetry events.

Telemetry.Metrics doesn’t aggregate the metrics itself, rather it relies on reporters to subscribe to relevant events and aggregate the metrics in a way that makes the most sense for the monitoring system they report to.

I recommend checking out the docs since they contain way more information. Since this version we also have a guide for writing reporters :blush:

Big thank you to all the people involved in discussions around the design and ideas for improvement - we wouldn’t have made it without you :yellow_heart:

Most Liked

arkgil

arkgil

Out of interest, why use string specification instead of array of atoms? These would be equivalent in the idea, but would save on the parsing and restricting separators (for example OpenCensus often uses / to separate metric segments).

It’s just a matter of preference, I think that it just looks nicer. But you can use a list of atoms for both the metric and event name as well.

Another thing is whether this will be rewritten in Erlang (with possible Elixir wrapper) for allowing it to be used with rest of the community?

I personally believe that it should, you and other folks have done a lot of awesome work on opencensus stuff, which means we could have really solid integration without much effort, I suppose. Although I really wish we could generate nicer documentation from the Erlang source code :slightly_frowning_face:

Where Next?

Popular in Announcing Top

danschultzer
None of the current solutions worked well for me, so I went ahead and built a user management system from scratch. This project took far...
548 29377 241
New
sorentwo
Hello! tl;dr Announcing Oban, an Ecto based job processing library with a focus on reliability and historical observability. After spen...
985 42920 311
New
msaraiva
Surface is an experimental library built on top of Phoenix LiveView and its new LiveComponent API that aims to provide a more declarative...
564 43622 214
New
mplatts
With HEEX released we decided to start a components library using Tailwind CSS - check it out here: Petal Components. We also have a boi...
New
maltoe
Hello! Came here to announce ChromicPDF, a pet project PDF generator I’ve been working on for the past few months. Why another PDF gener...
New
riverrun
I’ve just released version 3 of Comeonin, a password hashing library. The following small changes have been made: changes to the NIF c...
New
hpopp
After just over two years in development, this latest version of Pigeon is what I finally consider done in regards to my original vision ...
New
marcuslankenau
I feel kind of stuck with the absence of a proper xml library for Elixir. Currently I use SweetXML which was ok for me more or less to pa...
New
handnot2
Samly can be used to enable SAML 2.0 Single Sign On in a Plug/Phoenix application. This library uses Erlang esaml to provide plug enabl...
New
mattludwigs
Grizzly is a library for working with Z-Wave devices. Z-Wave is a low-frequency radio protocol for controlling smart home devices on a me...
New

Other popular topics Top

jay1
Why is it that the mnesia database isn’t the most preferred database for use in Elixir/Phoenix?
New
pmjoe
I have a relationship of love and hate with Elixir. Lots of things are just absolutely right, but there are some things that are kind of ...
New
stefanluptak
Hello everybody, usually, I use a 29" ultra-wide monitor for VSCode which can easily accomodate explorer (files panel) + file with code ...
New
vrod
I am using the Starship cross-shell prompt – it seems pretty nice, but I get some errors: [WARN] - (starship::utils): Executing command ...
New
belgoros
I’m not a pro in using Regex and can’t figure out why the following behaviour happens, especially if we take into account the difference ...
New
freewebwithme
Using vs code and installed ElixirLS: support and debugger. And I got an error popped up on start up says Failed to run ‘elixir’ comma...
New
RisingFromAshes
I’ve read in another post that it may be possible with a router helper - but I couldn’t find an appropriate one, and tbh, I’m still just ...
New
WestKeys
Currently suffering from paralysis by [HTTP client] analysis. This is rather unusual in Elixirland as there tends to be consensus on the ...
New
openscript
Hello! Sorry for this astonishing simple question, but I’m really stuck. I try to set up the intellij-elixir plugin, but I don’t know ho...
New
Qqwy
Update: How to use the Blogs & Podcasts section You can post links to your blog posts or podcasts either in one of the Official Blog...
3271 126479 1222
New

Latest on Elixir Forum

We're in Beta

About us Mission Statement