clientapi_pve/models/cluster_ha_update_groups_request.rs
1/*
2 * Proxmox Virtual Environment API
3 *
4 * Generated from apidoc.js. NOT an official Proxmox specification. See https://pve.proxmox.com/pve-docs/api-viewer/ for the upstream documentation.
5 *
6 * The version of the OpenAPI document: 9.x
7 *
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
15pub struct ClusterHaUpdateGroupsRequest {
16
17 /// Description.
18 #[serde(rename = "comment", skip_serializing_if = "Option::is_none")]
19 pub comment: Option<String>,
20
21 /// A list of settings you want to delete.
22 #[serde(rename = "delete", skip_serializing_if = "Option::is_none")]
23 pub delete: Option<String>,
24
25 /// Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications.
26 #[serde(rename = "digest", skip_serializing_if = "Option::is_none")]
27 pub digest: Option<String>,
28
29 /// 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.
30 #[serde(rename = "nodes", skip_serializing_if = "Option::is_none")]
31 pub nodes: Option<String>,
32
33 /// The CRM tries to run services on the node with the highest priority. If a node with higher priority comes online, the CRM migrates the service to that node. Enabling nofailback prevents that behavior.
34 #[serde(rename = "nofailback", skip_serializing_if = "Option::is_none")]
35 pub nofailback: Option<models::PveBoolean>,
36
37 /// Resources bound to restricted groups may only run on nodes defined by the group. The resource will be placed in the stopped state if no group node member is online. Resources on unrestricted groups may run on any cluster node if all group members are offline, but they will migrate back as soon as a group member comes online. One can implement a 'preferred node' behavior using an unrestricted group with only one member.
38 #[serde(rename = "restricted", skip_serializing_if = "Option::is_none")]
39 pub restricted: Option<models::PveBoolean>,
40
41
42}
43
44impl ClusterHaUpdateGroupsRequest {
45 pub fn new() -> ClusterHaUpdateGroupsRequest {
46 ClusterHaUpdateGroupsRequest {
47
48 comment: None,
49
50 delete: None,
51
52 digest: None,
53
54 nodes: None,
55
56 nofailback: None,
57
58 restricted: None,
59
60 }
61 }
62}
63
64