tembo_api_client/models/
auto_stop.rs

1/*
2 * Tembo Cloud
3 *
4 * Platform API for Tembo Cloud             </br>             </br>             To find a Tembo Data API, please find it here:             </br>             </br>             [AWS US East 1](https://api.data-1.use1.tembo.io/swagger-ui/)
5 *
6 * The version of the OpenAPI document: v1.0.0
7 *
8 * Generated by: https://openapi-generator.tech
9 */
10
11use serde::{Deserialize, Serialize};
12
13/// AutoStop : AutoStop configures automatic stopping of idle instances. An instance is considered idle if it is more than two days old, hasn't been connected to in over a day, and has not been resumed within the last day. Idle instances are stopped in the time window 9-9:30 AM ET.
14#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
15pub struct AutoStop {
16    /// Enable automatic stopping of the instance when idle.
17    #[serde(rename = "enabled")]
18    pub enabled: bool,
19}
20
21impl AutoStop {
22    /// AutoStop configures automatic stopping of idle instances. An instance is considered idle if it is more than two days old, hasn't been connected to in over a day, and has not been resumed within the last day. Idle instances are stopped in the time window 9-9:30 AM ET.
23    pub fn new(enabled: bool) -> AutoStop {
24        AutoStop { enabled }
25    }
26}