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

Drop mean #2

Merged
merged 1 commit into from
Oct 24, 2019
Merged

Drop mean #2

merged 1 commit into from
Oct 24, 2019

Conversation

OndrejSlamecka
Copy link
Owner

This might be a bit controversial but fixes an actual issue without any actual loss.

The issue is that for an empty data set the mean is NaN (see blow) which is wrapped in FieldFloat :: Field n and formatted to NaN which is not a valid float value in InfluxDB.

Prelude System.Metrics.Distribution> new >>= System.Metrics.Distribution.read
Stats {mean = NaN, variance = 0.0, count = 0, sum = 0.0, min = 0.0, max = 0.0}

However, mean is just sum / count so it's not that important to have and we could perhaps just drop it.

@angerman
Copy link
Collaborator

@OndrejSlamecka I'm not using this package anymore. Let me know if you want to take it over!

@OndrejSlamecka
Copy link
Owner Author

Thank you, I can give it a try @angerman !

@angerman
Copy link
Collaborator

Thank you, I can give it a try @angerman !

For me to transfer this repo to you, you'll have to rename your existing fork of the ekg-infludb I believe. I can't transfer it to you as it is right now.

@OndrejSlamecka
Copy link
Owner Author

Done.

@OndrejSlamecka
Copy link
Owner Author

Could you also please transfer the Hackage package https://hackage.haskell.org/package/ekg-influxdb so that I can upload new versions?

@angerman
Copy link
Collaborator

Could you also please transfer the Hackage package https://hackage.haskell.org/package/ekg-influxdb so that I can upload new versions?

Please let me know your package handle; I'll just add you as a maintainer, that's the easiest solution I believe.

@OndrejSlamecka
Copy link
Owner Author

Mea culpa, I forgot to write my handle -- it's ondrej.

@angerman
Copy link
Collaborator

Mea culpa, I forgot to write my handle -- it's ondrej.

Alright! Let me know if you need anything else.

@OndrejSlamecka
Copy link
Owner Author

Sorry, I didn't manage to click the transfer link on time. Can you please do it once again?

@angerman
Copy link
Collaborator

Sorry, I didn't manage to click the transfer link on time. Can you please do it once again?

done.

@OndrejSlamecka
Copy link
Owner Author

Excellent, thank you!

@OndrejSlamecka OndrejSlamecka merged commit dbaca97 into OndrejSlamecka:master Oct 24, 2019
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