spec icon indicating copy to clipboard operation
spec copied to clipboard

Revert to string based resource quantities

Open negz opened this issue 5 years ago • 1 comments

Per https://github.com/oam-dev/spec/issues/26 it appears the OAM spec initially called for float-ey resource quantities to be specified as a string, then switched to recommending floats. Per API conventions Kubernetes discourages floats, and perr https://github.com/kubernetes-sigs/controller-tools/issues/245 controller-tools explicitly disallows it. This makes it difficult to describe the current OAM spec using Kubernetes CRDs.

How would we feel about returning to string based resource quantities? There seem to be compelling technical reasons (round trippable serialisation) to do so.

negz avatar Feb 19 '20 01:02 negz

I agree. Besides this reason, in the current model type of memory and volume is string while type of extend resource and CPU/GPU is float. We'd better make them unified.

wonderflow avatar Mar 05 '20 11:03 wonderflow