FixedDatabaseCreateRequest

Struct FixedDatabaseCreateRequest 

Source
pub struct FixedDatabaseCreateRequest {
Show 27 fields pub subscription_id: Option<i32>, pub name: String, pub protocol: Option<String>, pub memory_limit_in_gb: Option<f64>, pub dataset_size_in_gb: Option<f64>, pub support_oss_cluster_api: Option<bool>, pub redis_version: Option<String>, pub resp_version: Option<String>, pub use_external_endpoint_for_oss_cluster_api: Option<bool>, pub enable_database_clustering: Option<bool>, pub number_of_shards: Option<i32>, pub data_persistence: Option<String>, pub data_eviction_policy: Option<String>, pub replication: Option<bool>, pub periodic_backup_path: Option<String>, pub source_ips: Option<Vec<String>>, pub regex_rules: Option<Vec<String>>, pub replica_of: Option<Vec<String>>, pub replica: Option<ReplicaOfSpec>, pub client_ssl_certificate: Option<String>, pub client_tls_certificates: Option<Vec<DatabaseCertificateSpec>>, pub enable_tls: Option<bool>, pub password: Option<String>, pub alerts: Option<Vec<DatabaseAlertSpec>>, pub modules: Option<Vec<DatabaseModuleSpec>>, pub command_type: Option<String>, pub extra: Value,
}
Expand description

Essentials database definition

Fields§

§subscription_id: Option<i32>§name: String

Name of the database. Database name is limited to 40 characters or less and must include only letters, digits, and hyphens (‘-’). It must start with a letter and end with a letter or digit.

§protocol: Option<String>

Optional. Database protocol. Use ‘stack’ to get all of Redis’ advanced capabilities. Only use ‘redis’ for Pay-as-you-go or Redis Flex subscriptions. Default: ‘stack’ for most subscriptions, ‘redis’ for Redis Flex subscriptions.

§memory_limit_in_gb: Option<f64>

(Pay-as-you-go subscriptions only) Optional. Total memory in GB, including replication and other overhead. You cannot set both datasetSizeInGb and totalMemoryInGb.

§dataset_size_in_gb: Option<f64>

(Pay-as-you-go subscriptions only) Optional. The maximum amount of data in the dataset for this database in GB. You cannot set both datasetSizeInGb and totalMemoryInGb. If ‘replication’ is ‘true’, the database’s total memory will be twice as large as the datasetSizeInGb. If ‘replication’ is false, the database’s total memory will be the datasetSizeInGb value.

§support_oss_cluster_api: Option<bool>

(Pay-as-you-go subscriptions only) Optional. Support Redis OSS Cluster API. Default: ‘false’

§redis_version: Option<String>

Optional. If specified, redisVersion defines the Redis database version. If omitted, the Redis version will be set to the default version. (available in ‘GET /fixed/redis-versions’)

§resp_version: Option<String>

Optional. Redis Serialization Protocol version. Must be compatible with Redis version.

§use_external_endpoint_for_oss_cluster_api: Option<bool>

(Pay-as-you-go subscriptions only) Optional. If set to ‘true’, the database will use the external endpoint for OSS Cluster API. This setting blocks the database’s private endpoint. Can only be set if ‘supportOSSClusterAPI’ is ‘true’. Default: ‘false’

§enable_database_clustering: Option<bool>

(Pay-as-you-go subscriptions only) Optional. Distributes database data to different cloud instances. Default: ‘false’

§number_of_shards: Option<i32>

(Pay-as-you-go subscriptions only) Optional. Specifies the number of master shards.

§data_persistence: Option<String>

Optional. Type and rate of data persistence in persistent storage. Use GET /fixed/plans/{planId} to see if your plan supports data persistence.

§data_eviction_policy: Option<String>

Optional. Data eviction policy.

§replication: Option<bool>

Optional. Sets database replication. Use GET /fixed/plans/{planId} to see if your plan supports database replication.

§periodic_backup_path: Option<String>

Optional. The path to a backup storage location. If specified, the database will back up every 24 hours to this location, and you can manually back up the database to this location at any time. Use GET /fixed/plans/{planId} to see if your plan supports database backups.

§source_ips: Option<Vec<String>>

Optional. List of source IP addresses or subnet masks to allow. If specified, Redis clients will be able to connect to this database only from within the specified source IP addresses ranges. Use GET /fixed/plans/{planId} to see how many CIDR allow rules your plan supports. Example: ’[‘192.168.10.0/32’, ‘192.168.12.0/24’]’

§regex_rules: Option<Vec<String>>

(Pay-as-you-go subscriptions only) Optional. Hashing policy Regex rules. Used only if ‘enableDatabaseClustering’ is set to ‘true’ and .

§replica_of: Option<Vec<String>>

Optional. This database will be a replica of the specified Redis databases provided as one or more URI(s). Example: ‘redis://user:password@host:port’. If the URI provided is a Redis Cloud database, only host and port should be provided. Example: [‘redis://endpoint1:6379’, ‘redis://endpoint2:6380’].

§replica: Option<ReplicaOfSpec>§client_ssl_certificate: Option<String>

Optional. A public key client TLS/SSL certificate with new line characters replaced with ‘\n’. If specified, mTLS authentication will be required to authenticate user connections. Default: ‘null’

§client_tls_certificates: Option<Vec<DatabaseCertificateSpec>>

Optional. A list of client TLS/SSL certificates. If specified, mTLS authentication will be required to authenticate user connections.

§enable_tls: Option<bool>

Optional. When ‘true’, requires TLS authentication for all connections - mTLS with valid clientTlsCertificates, regular TLS when clientTlsCertificates is not provided. Default: ‘false’

§password: Option<String>

Optional. Password to access the database. If not set, a random 32-character alphanumeric password will be automatically generated.

§alerts: Option<Vec<DatabaseAlertSpec>>

Optional. Redis database alert details.

§modules: Option<Vec<DatabaseModuleSpec>>

Optional. Redis advanced capabilities (also known as modules) to be provisioned in the database. Use GET /database-modules to get a list of available advanced capabilities. Can only be set if ‘protocol’ is ‘redis’.

§command_type: Option<String>§extra: Value

Additional fields from the API

Trait Implementations§

Source§

impl Clone for FixedDatabaseCreateRequest

Source§

fn clone(&self) -> FixedDatabaseCreateRequest

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for FixedDatabaseCreateRequest

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'de> Deserialize<'de> for FixedDatabaseCreateRequest

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl Serialize for FixedDatabaseCreateRequest

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> PolicyExt for T
where T: ?Sized,

Source§

fn and<P, B, E>(self, other: P) -> And<T, P>
where T: Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow only if self and other return Action::Follow. Read more
Source§

fn or<P, B, E>(self, other: P) -> Or<T, P>
where T: Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow if either self or other returns Action::Follow. Read more
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,

Source§

impl<T> ErasedDestructor for T
where T: 'static,