1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
/*
* Proxmox Virtual Environment API
*
* Generated from apidoc.js. NOT an official Proxmox specification. See https://pve.proxmox.com/pve-docs/api-viewer/ for the upstream documentation.
*
* The version of the OpenAPI document: 9.x
*
* Generated by: https://openapi-generator.tech
*/
use crate::models;
use serde::{Deserialize, Serialize};
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct ClusterReplicationReadGetReplicationResponseData {
/// Description.
#[serde(rename = "comment", skip_serializing_if = "Option::is_none")]
pub comment: Option<String>,
/// Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications.
#[serde(rename = "digest", skip_serializing_if = "Option::is_none")]
pub digest: Option<String>,
/// Flag to disable/deactivate the entry.
#[serde(rename = "disable", skip_serializing_if = "Option::is_none")]
pub disable: Option<models::PveBoolean>,
/// Guest ID.
#[serde(rename = "guest")]
pub guest: i64,
/// Replication Job ID. The ID is composed of a Guest ID and a job number, separated by a hyphen, i.e. '<GUEST>-<JOBNUM>'.
#[serde(rename = "id")]
pub id: String,
/// Unique, sequential ID assigned to each job.
#[serde(rename = "jobnum")]
pub jobnum: i64,
/// Rate limit in mbps (megabytes per second) as floating point number.
#[serde(rename = "rate", skip_serializing_if = "Option::is_none")]
pub rate: Option<f64>,
/// Mark the replication job for removal. The job will remove all local replication snapshots. When set to 'full', it also tries to remove replicated volumes on the target. The job then removes itself from the configuration file.
#[serde(rename = "remove_job", skip_serializing_if = "Option::is_none")]
pub remove_job: Option<models::PveRemoveJobEnum>,
/// Storage replication schedule. The format is a subset of `systemd` calendar events.
#[serde(rename = "schedule", skip_serializing_if = "Option::is_none")]
pub schedule: Option<String>,
/// For internal use, to detect if the guest was stolen.
#[serde(rename = "source", skip_serializing_if = "Option::is_none")]
pub source: Option<String>,
/// Target node.
#[serde(rename = "target")]
pub target: String,
/// Section type.
#[serde(rename = "type")]
pub r#type: models::PveClusterReplicationTypeEnum,
}
impl ClusterReplicationReadGetReplicationResponseData {
pub fn new(guest: i64, id: String, jobnum: i64, target: String, r#type: models::PveClusterReplicationTypeEnum) -> ClusterReplicationReadGetReplicationResponseData {
ClusterReplicationReadGetReplicationResponseData {
comment: None,
digest: None,
disable: None,
guest,
id,
jobnum,
rate: None,
remove_job: None,
schedule: None,
source: None,
target,
r#type,
}
}
}