Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

src/encoding/text.rs: Expose Encoder methods #41

Merged
merged 3 commits into from
Feb 2, 2022

Conversation

mxinden
Copy link
Member

@mxinden mxinden commented Jan 24, 2022

By exposing the various Encoder builder methods, downstream users can
implement their custom metrics using EncodeMetric.

See #36 for additional context.

//CC @phyber

By exposing the various `Encoder` builder methods, downstream users can
implement their custom metrics using `EncodeMetric`.

Signed-off-by: Max Inden <mail@max-inden.de>
Signed-off-by: Max Inden <mail@max-inden.de>
Signed-off-by: Max Inden <mail@max-inden.de>
@phyber
Copy link
Contributor

phyber commented Feb 2, 2022

Sorry, I forgot about this. I'll give it a look soon :)

@phyber
Copy link
Contributor

phyber commented Feb 2, 2022

This seems perfect, I was able to quickly get my test working with this (which was almost 1:1 with the example you added) :)

@mxinden mxinden merged commit 16aa166 into prometheus:master Feb 2, 2022
ackintosh pushed a commit to ackintosh/client_rust that referenced this pull request Aug 27, 2022
By exposing the various `Encoder` builder methods, downstream users can
implement their custom metrics using `EncodeMetric`.

Showcase how to implement custom metric with example.

Signed-off-by: Max Inden <mail@max-inden.de>
Signed-off-by: ackintosh <sora.akatsuki@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants