pub struct ClusterHaCreateRuleRequest {
pub affinity: Option<PveAffinityEnum>,
pub comment: Option<String>,
pub disable: Option<PveBoolean>,
pub nodes: Option<String>,
pub resources: String,
pub rule: String,
pub strict: Option<PveBoolean>,
pub type: PveCauseEnum,
}Fields§
§affinity: Option<PveAffinityEnum>Describes whether the HA resources are supposed to be kept on the same node (‘positive’), or are supposed to be kept on separate nodes (‘negative’).
comment: Option<String>HA rule description.
disable: Option<PveBoolean>Whether the HA rule is disabled.
nodes: Option<String>List of cluster node members, where a priority can be given to each node. A resource will run on the available nodes with the highest priority. If there are more nodes in the highest priority class, the resources will get distributed to those nodes. The priorities have a relative meaning only. The higher the number, the higher the priority.
resources: StringList of HA resource IDs. This consists of a list of resource types followed by a resource specific name separated with a colon (example: vm:100,ct:101).
rule: StringHA rule identifier.
strict: Option<PveBoolean>Describes whether the node affinity rule is strict or non-strict. A non-strict node affinity rule makes resources prefer to be on the defined nodes. If none of the defined nodes are available, the resource may run on any other node. A strict node affinity rule makes resources be restricted to the defined nodes. If none of the defined nodes are available, the resource will be stopped.
type: PveCauseEnumHA rule type.
Implementations§
Source§impl ClusterHaCreateRuleRequest
impl ClusterHaCreateRuleRequest
pub fn new( resources: String, rule: String, type: PveCauseEnum, ) -> ClusterHaCreateRuleRequest
Trait Implementations§
Source§impl Clone for ClusterHaCreateRuleRequest
impl Clone for ClusterHaCreateRuleRequest
Source§fn clone(&self) -> ClusterHaCreateRuleRequest
fn clone(&self) -> ClusterHaCreateRuleRequest
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for ClusterHaCreateRuleRequest
impl Debug for ClusterHaCreateRuleRequest
Source§impl Default for ClusterHaCreateRuleRequest
impl Default for ClusterHaCreateRuleRequest
Source§fn default() -> ClusterHaCreateRuleRequest
fn default() -> ClusterHaCreateRuleRequest
Source§impl<'de> Deserialize<'de> for ClusterHaCreateRuleRequest
impl<'de> Deserialize<'de> for ClusterHaCreateRuleRequest
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>,
Source§impl PartialEq for ClusterHaCreateRuleRequest
impl PartialEq for ClusterHaCreateRuleRequest
Source§fn eq(&self, other: &ClusterHaCreateRuleRequest) -> bool
fn eq(&self, other: &ClusterHaCreateRuleRequest) -> bool
self and other values to be equal, and is used by ==.