#[repr(i32)]pub enum SizingOptimizationStrategy {
Unspecified = 0,
SameAsSource = 1,
Moderate = 2,
Aggressive = 3,
}
Expand description
The sizing optimization strategy preferences of a virtual machine. This strategy, in addition to actual usage data of the virtual machine, can help determine the recommended shape on the target platform.
Variants§
Unspecified = 0
Unspecified (default value).
SameAsSource = 1
No optimization applied. Virtual machine sizing matches as closely as possible the machine shape on the source site, not considering any actual performance data.
Moderate = 2
Virtual machine sizing will match the reported usage and shape, with some slack. This a good value to start with.
Aggressive = 3
Virtual machine sizing will match the reported usage, with little slack. Using this option can help reduce costs.
Implementations§
source§impl SizingOptimizationStrategy
impl SizingOptimizationStrategy
sourcepub fn is_valid(value: i32) -> bool
pub fn is_valid(value: i32) -> bool
Returns true
if value
is a variant of SizingOptimizationStrategy
.
sourcepub fn from_i32(value: i32) -> Option<SizingOptimizationStrategy>
👎Deprecated: Use the TryFrom<i32> implementation instead
pub fn from_i32(value: i32) -> Option<SizingOptimizationStrategy>
Converts an i32
to a SizingOptimizationStrategy
, or None
if value
is not a valid variant.
source§impl SizingOptimizationStrategy
impl SizingOptimizationStrategy
sourcepub fn as_str_name(&self) -> &'static str
pub fn as_str_name(&self) -> &'static str
String value of the enum field names used in the ProtoBuf definition.
The values are not transformed in any way and thus are considered stable (if the ProtoBuf definition does not change) and safe for programmatic use.
sourcepub fn from_str_name(value: &str) -> Option<Self>
pub fn from_str_name(value: &str) -> Option<Self>
Creates an enum from field names used in the ProtoBuf definition.
Trait Implementations§
source§impl Clone for SizingOptimizationStrategy
impl Clone for SizingOptimizationStrategy
source§fn clone(&self) -> SizingOptimizationStrategy
fn clone(&self) -> SizingOptimizationStrategy
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for SizingOptimizationStrategy
impl Debug for SizingOptimizationStrategy
source§impl Default for SizingOptimizationStrategy
impl Default for SizingOptimizationStrategy
source§fn default() -> SizingOptimizationStrategy
fn default() -> SizingOptimizationStrategy
source§impl From<SizingOptimizationStrategy> for i32
impl From<SizingOptimizationStrategy> for i32
source§fn from(value: SizingOptimizationStrategy) -> i32
fn from(value: SizingOptimizationStrategy) -> i32
source§impl Hash for SizingOptimizationStrategy
impl Hash for SizingOptimizationStrategy
source§impl Ord for SizingOptimizationStrategy
impl Ord for SizingOptimizationStrategy
source§fn cmp(&self, other: &SizingOptimizationStrategy) -> Ordering
fn cmp(&self, other: &SizingOptimizationStrategy) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
source§impl PartialEq for SizingOptimizationStrategy
impl PartialEq for SizingOptimizationStrategy
source§fn eq(&self, other: &SizingOptimizationStrategy) -> bool
fn eq(&self, other: &SizingOptimizationStrategy) -> bool
self
and other
values to be equal, and is used
by ==
.source§impl PartialOrd for SizingOptimizationStrategy
impl PartialOrd for SizingOptimizationStrategy
source§fn partial_cmp(&self, other: &SizingOptimizationStrategy) -> Option<Ordering>
fn partial_cmp(&self, other: &SizingOptimizationStrategy) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
self
and other
) and is used by the <=
operator. Read moresource§impl TryFrom<i32> for SizingOptimizationStrategy
impl TryFrom<i32> for SizingOptimizationStrategy
§type Error = UnknownEnumValue
type Error = UnknownEnumValue
source§fn try_from(value: i32) -> Result<SizingOptimizationStrategy, UnknownEnumValue>
fn try_from(value: i32) -> Result<SizingOptimizationStrategy, UnknownEnumValue>
impl Copy for SizingOptimizationStrategy
impl Eq for SizingOptimizationStrategy
impl StructuralPartialEq for SizingOptimizationStrategy
Auto Trait Implementations§
impl Freeze for SizingOptimizationStrategy
impl RefUnwindSafe for SizingOptimizationStrategy
impl Send for SizingOptimizationStrategy
impl Sync for SizingOptimizationStrategy
impl Unpin for SizingOptimizationStrategy
impl UnwindSafe for SizingOptimizationStrategy
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key
and return true
if they are equal.§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key
and return true
if they are equal.§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T
in a tonic::Request