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

Add support of f32 for Gauge and Counter #216

Merged
merged 6 commits into from
Jul 17, 2024

Conversation

navaati
Copy link
Contributor

@navaati navaati commented Jul 17, 2024

No description provided.

@navaati
Copy link
Contributor Author

navaati commented Jul 17, 2024

Still gotta edit the changelog.

@navaati
Copy link
Contributor Author

navaati commented Jul 17, 2024

There ya go, changelog done. I took the liberty to merge the entry with @brocaar's, since this PR kinda completes his.

@mxinden I’m a bit afraid about this PR, since it touches Atomic code, but well, I copied the code and searched/replaced. Please take a look !

Copy link
Member

@mxinden mxinden left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good work. Atomics code looks fine.

Shall we hold off with a release for now?

Comment on lines +9 to +25
### Changed

- `ConstCounter::new` now requires specifying the type of literal arguments, like this: `ConstCounter::new(42u64);`.
See [PR 173].

- Update `prost` dependencies to `v0.12`.
See [PR 198].

[PR 198]: https://github.com/prometheus/client_rust/pull/198

- Add `EncodeGaugeValue` `i32` and `f32`, `EncodeCounterValue` `u32` and `f32` and `EncodeExemplarValue` `f32` and `u32` implementations.
See [PR 173].
### Added

- Support `i32`/`f32` for `Gauge` and `u32`/`f32` for `Counter`/`CounterWithExemplar`.
See [PR 173] and [PR 216].

[PR 173]: https://github.com/prometheus/client_rust/pull/173
[PR 216]: https://github.com/prometheus/client_rust/pull/216
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

src/encoding/text.rs Outdated Show resolved Hide resolved
src/encoding/text.rs Outdated Show resolved Hide resolved
@mxinden mxinden merged commit aeca8d8 into prometheus:master Jul 17, 2024
10 checks passed
@navaati navaati deleted the more_datatypes branch July 17, 2024 19:15
@navaati
Copy link
Contributor Author

navaati commented Jul 17, 2024

Shall we hold off with a release for now?

If you have enough content for a release, go for it: the sooner you get it in the wild, the sooner you’ll have feedback if there is a problem (not that I think there would)… It’s a breaking release anyway so nobody will get broken on a cargo update.

As for myself I’m happy when I can remove this line https://gitlab.com/navaati/licorne/-/blob/f26f4141c357b41aae2f1235f8fe0cb3bc7af638/firmware/Cargo.toml#L42 :D

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