pub struct Postgres {
pub id: String,
pub version: String,
pub cpu: Option<String>,
pub memory: Option<String>,
pub storage: String,
pub high_availability: bool,
pub backend: Option<PostgresBackend>,
}Expand description
A managed PostgreSQL database. The target platform decides the backend (AWS Aurora Serverless v2, GCP Cloud SQL, Azure Flexible Server, or an embedded native process on Local); the database is never publicly reachable.
Fields§
§id: String§version: StringMajor engine version: “15” | “16” | “17”. Default “17”.
cpu: Option<String>Requested vCPUs (e.g. “0.5”, “2”). None = smallest available tier.
memory: Option<String>Requested memory (e.g. “1Gi”, “8Gi”). None = smallest available tier.
storage: StringAllocated storage (e.g. “20Gi”). Default “20Gi”. Grow-only.
high_availability: boolMulti-AZ / regional / zone-redundant high availability. Default false.
backend: Option<PostgresBackend>Cloud backend selector; None resolves to the platform default. The field exists so a single per-cloud controller can dispatch on it without a later schema change — the registry allows only one controller per (resource, cloud).
Implementations§
Source§impl Postgres
impl Postgres
Sourcepub fn new(id: String) -> PostgresBuilder
pub fn new(id: String) -> PostgresBuilder
Create an instance of Postgres using the builder syntax
Source§impl Postgres
impl Postgres
Sourcepub const RESOURCE_TYPE: ResourceType
pub const RESOURCE_TYPE: ResourceType
The resource type identifier for Postgres.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Postgres
impl<'de> Deserialize<'de> for Postgres
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
impl Eq for Postgres
Source§impl ResourceDefinition for Postgres
impl ResourceDefinition for Postgres
Source§fn get_resource_type(&self) -> ResourceType
fn get_resource_type(&self) -> ResourceType
Source§fn get_dependencies(&self) -> Vec<ResourceRef>
fn get_dependencies(&self) -> Vec<ResourceRef>
Source§fn validate_update(&self, new_config: &dyn ResourceDefinition) -> Result<()>
fn validate_update(&self, new_config: &dyn ResourceDefinition) -> Result<()>
Source§fn as_any_mut(&mut self) -> &mut dyn Any
fn as_any_mut(&mut self) -> &mut dyn Any
Source§fn box_clone(&self) -> Box<dyn ResourceDefinition>
fn box_clone(&self) -> Box<dyn ResourceDefinition>
Source§fn resource_eq(&self, other: &dyn ResourceDefinition) -> bool
fn resource_eq(&self, other: &dyn ResourceDefinition) -> bool
Source§fn to_json_value(&self) -> Result<Value>
fn to_json_value(&self) -> Result<Value>
impl StructuralPartialEq for Postgres
Auto Trait Implementations§
impl Freeze for Postgres
impl RefUnwindSafe for Postgres
impl Send for Postgres
impl Sync for Postgres
impl Unpin for Postgres
impl UnsafeUnpin for Postgres
impl UnwindSafe for Postgres
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.