hanzo_client/models/applied_resource.rs
1/*
2 * Hanzo Cloud API
3 *
4 * The Hanzo Cloud API as a customer calls it: every operation under /v1/ except the operator's admin product, relay routes, legacy spellings and capabilities still reached by flag. Tagged by product: the first path segment after /v1/.
5 *
6 * The version of the OpenAPI document: v1
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 AppliedResource {
16 /// Message is the engine's own sentence about this object — the apiserver's refusal on a failure, and typically empty on success. It is for a human reading a failed run, not a value to branch on.
17 #[serde(rename = "message", skip_serializing_if = "Option::is_none")]
18 pub message: Option<String>,
19 /// Resource identifies the object as group/version/kind/namespace/name, the engine's own key. It is stable across runs, so two reports can be diffed on it.
20 #[serde(rename = "resource", skip_serializing_if = "Option::is_none")]
21 pub resource: Option<String>,
22 /// Status is what happened to this object, from the engine's closed vocabulary: `Synced` (applied), `Pruned` (deleted because the source no longer declares it), `SyncFailed` (refused — read Message) and `PruneSkipped` (deletion was declined). It is the per-object detail behind the report's counts.
23 #[serde(rename = "status", skip_serializing_if = "Option::is_none")]
24 pub status: Option<String>,
25}
26
27impl AppliedResource {
28 pub fn new() -> AppliedResource {
29 AppliedResource {
30 message: None,
31 resource: None,
32 status: None,
33 }
34 }
35}
36