#[non_exhaustive]pub struct MongodbProfile {
pub host_addresses: Vec<HostAddress>,
pub replica_set: String,
pub username: String,
pub password: String,
pub secret_manager_stored_password: String,
pub ssl_config: Option<MongodbSslConfig>,
pub mongodb_connection_format: Option<MongodbConnectionFormat>,
/* private fields */
}
Expand description
MongoDB profile.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. }
syntax; cannot be matched against without a wildcard ..
; and struct update syntax will not work.host_addresses: Vec<HostAddress>
Required. List of host addresses for a MongoDB cluster. For SRV connection format, this list must contain exactly one DNS host without a port. For Standard connection format, this list must contain all the required hosts in the cluster with their respective ports.
replica_set: String
Optional. Name of the replica set. Only needed for self hosted replica set type MongoDB cluster. For SRV connection format, this field must be empty. For Standard connection format, this field must be specified.
username: String
Required. Username for the MongoDB connection.
password: String
Optional. Password for the MongoDB connection. Mutually exclusive with the
secret_manager_stored_password
field.
secret_manager_stored_password: String
Optional. A reference to a Secret Manager resource name storing the
SQLServer connection password. Mutually exclusive with the password
field.
ssl_config: Option<MongodbSslConfig>
Optional. SSL configuration for the MongoDB connection.
mongodb_connection_format: Option<MongodbConnectionFormat>
MongoDB connection format. Must specify either srv_connection_format or standard_connection_format.
Implementations§
Source§impl MongodbProfile
impl MongodbProfile
pub fn new() -> Self
Sourcepub fn set_host_addresses<T, V>(self, v: T) -> Self
pub fn set_host_addresses<T, V>(self, v: T) -> Self
Sets the value of host_addresses.
Sourcepub fn set_replica_set<T: Into<String>>(self, v: T) -> Self
pub fn set_replica_set<T: Into<String>>(self, v: T) -> Self
Sets the value of replica_set.
Sourcepub fn set_username<T: Into<String>>(self, v: T) -> Self
pub fn set_username<T: Into<String>>(self, v: T) -> Self
Sets the value of username.
Sourcepub fn set_password<T: Into<String>>(self, v: T) -> Self
pub fn set_password<T: Into<String>>(self, v: T) -> Self
Sets the value of password.
Sourcepub fn set_secret_manager_stored_password<T: Into<String>>(self, v: T) -> Self
pub fn set_secret_manager_stored_password<T: Into<String>>(self, v: T) -> Self
Sets the value of secret_manager_stored_password.
Sourcepub fn set_ssl_config<T>(self, v: T) -> Selfwhere
T: Into<MongodbSslConfig>,
pub fn set_ssl_config<T>(self, v: T) -> Selfwhere
T: Into<MongodbSslConfig>,
Sets the value of ssl_config.
Sourcepub fn set_or_clear_ssl_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<MongodbSslConfig>,
pub fn set_or_clear_ssl_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<MongodbSslConfig>,
Sets or clears the value of ssl_config.
Sourcepub fn set_mongodb_connection_format<T: Into<Option<MongodbConnectionFormat>>>(
self,
v: T,
) -> Self
pub fn set_mongodb_connection_format<T: Into<Option<MongodbConnectionFormat>>>( self, v: T, ) -> Self
Sets the value of mongodb_connection_format.
Note that all the setters affecting mongodb_connection_format
are mutually
exclusive.
Sourcepub fn srv_connection_format(&self) -> Option<&Box<SrvConnectionFormat>>
pub fn srv_connection_format(&self) -> Option<&Box<SrvConnectionFormat>>
The value of mongodb_connection_format
if it holds a SrvConnectionFormat
, None
if the field is not set or
holds a different branch.
Sourcepub fn set_srv_connection_format<T: Into<Box<SrvConnectionFormat>>>(
self,
v: T,
) -> Self
pub fn set_srv_connection_format<T: Into<Box<SrvConnectionFormat>>>( self, v: T, ) -> Self
Sets the value of mongodb_connection_format
to hold a SrvConnectionFormat
.
Note that all the setters affecting mongodb_connection_format
are
mutually exclusive.
Sourcepub fn standard_connection_format(
&self,
) -> Option<&Box<StandardConnectionFormat>>
pub fn standard_connection_format( &self, ) -> Option<&Box<StandardConnectionFormat>>
The value of mongodb_connection_format
if it holds a StandardConnectionFormat
, None
if the field is not set or
holds a different branch.
Sourcepub fn set_standard_connection_format<T: Into<Box<StandardConnectionFormat>>>(
self,
v: T,
) -> Self
pub fn set_standard_connection_format<T: Into<Box<StandardConnectionFormat>>>( self, v: T, ) -> Self
Sets the value of mongodb_connection_format
to hold a StandardConnectionFormat
.
Note that all the setters affecting mongodb_connection_format
are
mutually exclusive.
Trait Implementations§
Source§impl Clone for MongodbProfile
impl Clone for MongodbProfile
Source§fn clone(&self) -> MongodbProfile
fn clone(&self) -> MongodbProfile
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more