pub enum AutoscalepoolsCreateResponseAutoscalePoolConfig {
Variant0 {
target_number_instances: NonZeroU64,
},
Variant1 {
cooldown_minutes: Option<i64>,
max_instances: NonZeroU64,
min_instances: NonZeroU64,
target_cpu_utilization: Option<f32>,
target_memory_utilization: Option<f32>,
},
}Expand description
The scaling configuration for an autoscale pool, which is how the pool scales up and down (either by resource utilization or static configuration).
JSON schema
{
"description": "The scaling configuration for an autoscale pool, which is how the pool scales up and down (either by resource utilization or static configuration).",
"type": "object",
"oneOf": [
{
"type": "object",
"required": [
"target_number_instances"
],
"properties": {
"target_number_instances": {
"title": "static config",
"description": "Fixed number of instances in an autoscale pool.",
"examples": [
3
],
"type": "integer",
"maximum": 1000.0,
"minimum": 1.0
}
}
},
{
"type": "object",
"required": [
"max_instances",
"min_instances"
],
"properties": {
"cooldown_minutes": {
"description": "The number of minutes to wait between scaling events in an autoscale pool. Defaults to 10 minutes.",
"examples": [
5
],
"type": "integer",
"maximum": 20.0,
"minimum": 5.0
},
"max_instances": {
"description": "The maximum number of Droplets in an autoscale pool.",
"examples": [
10
],
"type": "integer",
"maximum": 1000.0,
"minimum": 1.0
},
"min_instances": {
"description": "The minimum number of Droplets in an autoscale pool.",
"examples": [
5
],
"type": "integer",
"maximum": 500.0,
"minimum": 1.0
},
"target_cpu_utilization": {
"description": "Target CPU utilization as a decimal.",
"examples": [
0.6
],
"type": "number",
"format": "float",
"maximum": 1.0,
"minimum": 0.05
},
"target_memory_utilization": {
"description": "Target memory utilization as a decimal.",
"examples": [
0.6
],
"type": "number",
"format": "float",
"maximum": 1.0,
"minimum": 0.05
}
}
}
]
}Variants§
Variant0
Fields
§
target_number_instances: NonZeroU64Fixed number of instances in an autoscale pool.
Variant1
Fields
§
cooldown_minutes: Option<i64>The number of minutes to wait between scaling events in an autoscale pool. Defaults to 10 minutes.
§
max_instances: NonZeroU64The maximum number of Droplets in an autoscale pool.
§
min_instances: NonZeroU64The minimum number of Droplets in an autoscale pool.
Trait Implementations§
Source§impl Clone for AutoscalepoolsCreateResponseAutoscalePoolConfig
impl Clone for AutoscalepoolsCreateResponseAutoscalePoolConfig
Source§fn clone(&self) -> AutoscalepoolsCreateResponseAutoscalePoolConfig
fn clone(&self) -> AutoscalepoolsCreateResponseAutoscalePoolConfig
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<'de> Deserialize<'de> for AutoscalepoolsCreateResponseAutoscalePoolConfig
impl<'de> Deserialize<'de> for AutoscalepoolsCreateResponseAutoscalePoolConfig
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl From<&AutoscalepoolsCreateResponseAutoscalePoolConfig> for AutoscalepoolsCreateResponseAutoscalePoolConfig
impl From<&AutoscalepoolsCreateResponseAutoscalePoolConfig> for AutoscalepoolsCreateResponseAutoscalePoolConfig
Source§fn from(value: &AutoscalepoolsCreateResponseAutoscalePoolConfig) -> Self
fn from(value: &AutoscalepoolsCreateResponseAutoscalePoolConfig) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for AutoscalepoolsCreateResponseAutoscalePoolConfig
impl RefUnwindSafe for AutoscalepoolsCreateResponseAutoscalePoolConfig
impl Send for AutoscalepoolsCreateResponseAutoscalePoolConfig
impl Sync for AutoscalepoolsCreateResponseAutoscalePoolConfig
impl Unpin for AutoscalepoolsCreateResponseAutoscalePoolConfig
impl UnsafeUnpin for AutoscalepoolsCreateResponseAutoscalePoolConfig
impl UnwindSafe for AutoscalepoolsCreateResponseAutoscalePoolConfig
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
Mutably borrows from an owned value. Read more