Divisor
resource.Quantity
omitempty
doesn't make sense
#75
Labels
lifecycle/rotten
Denotes an issue or PR that has aged beyond stale and will be auto-closed.
https://github.com/kubernetes/api/blob/master/core/v1/types.go#L2309
When you
json.Marshal()
aResourceFieldSelector
with undefinedDivisor
, you getdivisor: "0"
This is bad for 2 reasons:
omitempty
is meaningless hereDivisor
should default to1
. Since it actually defaults to0
, you get unintended behavior and incorrect resultsDivisor
instead should be a pointer*resource.Quantity
instead of justresource.Quantity
The text was updated successfully, but these errors were encountered: