mirror of
https://git.proxmox.com/git/proxmox
synced 2025-05-22 21:48:27 +00:00
remove proxmox-rrd-api-types crate, s/RRDTimeFrameResolution/RRDTimeFrame/
Because the types used inside the RRD have other requirements than the API types: - other serialization format - the API may not support all RRD features Signed-off-by: Dietmar Maurer <dietmar@proxmox.com> Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
This commit is contained in:
parent
d18f79dd4f
commit
6e30f3433f
@ -20,6 +20,5 @@ proxmox-schema = { version = "1.0.0", features = [ "api-macro" ] }
|
||||
proxmox-time = "1.0.0"
|
||||
proxmox-uuid = { version = "1.0.0", features = [ "serde" ] }
|
||||
|
||||
proxmox-rrd-api-types = { path = "../proxmox-rrd-api-types" }
|
||||
proxmox-systemd = { path = "../proxmox-systemd" }
|
||||
pbs-tools = { path = "../pbs-tools" }
|
||||
|
@ -424,4 +424,32 @@ pub const NODE_TASKS_LIST_TASKS_RETURN_TYPE: ReturnType = ReturnType {
|
||||
).schema(),
|
||||
};
|
||||
|
||||
pub use proxmox_rrd_api_types::{RRDMode, RRDTimeFrameResolution};
|
||||
#[api()]
|
||||
#[derive(Copy, Clone, Serialize, Deserialize)]
|
||||
#[serde(rename_all = "UPPERCASE")]
|
||||
/// RRD consolidation mode
|
||||
pub enum RRDMode {
|
||||
/// Maximum
|
||||
Max,
|
||||
/// Average
|
||||
Average,
|
||||
}
|
||||
|
||||
#[api()]
|
||||
#[derive(Copy, Clone, Serialize, Deserialize)]
|
||||
#[serde(rename_all = "lowercase")]
|
||||
/// RRD time frame
|
||||
pub enum RRDTimeFrame {
|
||||
/// Hour
|
||||
Hour,
|
||||
/// Day
|
||||
Day,
|
||||
/// Week
|
||||
Week,
|
||||
/// Month
|
||||
Month,
|
||||
/// Year
|
||||
Year,
|
||||
/// Decade (10 years)
|
||||
Decade,
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user