-
Notifications
You must be signed in to change notification settings - Fork 85
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 for 'g' as a common suffix for memory #155
Comments
You sure we don't want to make that GB? |
+1 I think "mb" and "gb" (case-insensitive) would be better |
Agreed, although maybe not exactly what https://en.wikipedia.org/wiki/Gigabyte says (ie 1000 instead of 1024). |
Perhaps, but I was thinking of consistency with Spring Boot's http://docs.spring.io/spring-boot/docs/current/reference/htmlsingle/#howto-multipart-file-upload-configuration |
Since there doesn't seem to be a commonly used way of defining this - Kubernetes uses MiB/GiB BTW - maybe we should just drop any suffix and have the parameter specify memory in megabytes, without a suffix. Then implementations can convert the amount to whatever unit used by their platform as they see fit. |
I'd vote for supporting the official (as seen in wikipedia) suffixes. My intent was for deployer-core to expose functionality for implementors to get the amount in the unit that best fits their needs (ie kubernetes could ask for "get the amount in megabytes" and always append MiB). |
Wouldn't "MiB" be the wrong suffix for megabytes? |
Got tricked by the wrong common-day usage. I should have written "get the amount in _mebi_bytes" and happen MiB. |
I do, maybe we should just use getAmountInBytes and let the platform impls figure out how to use it. K8s uses bytes internally BTW. |
Add parse utility method. Fixes spring-cloud#155
No description provided.
The text was updated successfully, but these errors were encountered: