percent.proto

Package: envoy.type

Types:

Source File: envoy/type/percent.proto

Percent

Identifies a percentage, in the range [0.0, 100.0].

"value": float
Field Type Description Default
value float

FractionalPercent

A fractional percentage is used in cases in which for performance reasons performing floating point to integer conversions during randomness calculations is undesirable. The message includes both a numerator and denominator that together determine the final fractional value.

Field Type Description Default
numerator int Specifies the numerator. Defaults to 0.
denominator .envoy.type.FractionalPercent.DenominatorType Specifies the denominator. If the denominator specified is less than the numerator, the final fractional percentage is capped at 1 (100%).

DenominatorType

Fraction percentages support several fixed denominator values.

Name Description
HUNDRED 100. Example: 1100 = 1%.
TEN_THOUSAND 10,000. Example: 110000 = 0.01%.
MILLION 1,000,000. Example: 11000000 = 0.0001%.