#[non_exhaustive]pub struct EncryptionConfig {
pub kms_key_name: String,
pub kms_key_names: Vec<String>,
}
Expand description
Encryption configuration for a Cloud Spanner database.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. }
syntax; cannot be matched against without a wildcard ..
; and struct update syntax will not work.kms_key_name: String
The Cloud KMS key to be used for encrypting and decrypting
the database. Values are of the form
projects/<project>/locations/<location>/keyRings/<key_ring>/cryptoKeys/<kms_key_name>
.
kms_key_names: Vec<String>
Specifies the KMS configuration for the one or more keys used to encrypt
the database. Values are of the form
projects/<project>/locations/<location>/keyRings/<key_ring>/cryptoKeys/<kms_key_name>
.
The keys referenced by kms_key_names must fully cover all regions of the database instance configuration. Some examples:
- For single region database instance configs, specify a single regional location KMS key.
- For multi-regional database instance configs of type GOOGLE_MANAGED, either specify a multi-regional location KMS key or multiple regional location KMS keys that cover all regions in the instance config.
- For a database instance config of type USER_MANAGED, please specify only regional location KMS keys to cover each region in the instance config. Multi-regional location KMS keys are not supported for USER_MANAGED instance configs.
Implementations§
Source§impl EncryptionConfig
impl EncryptionConfig
pub fn new() -> Self
Sourcepub fn set_kms_key_name<T: Into<String>>(self, v: T) -> Self
pub fn set_kms_key_name<T: Into<String>>(self, v: T) -> Self
Sets the value of kms_key_name.
Sourcepub fn set_kms_key_names<T, V>(self, v: T) -> Self
pub fn set_kms_key_names<T, V>(self, v: T) -> Self
Sets the value of kms_key_names.
Trait Implementations§
Source§impl Clone for EncryptionConfig
impl Clone for EncryptionConfig
Source§fn clone(&self) -> EncryptionConfig
fn clone(&self) -> EncryptionConfig
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for EncryptionConfig
impl Debug for EncryptionConfig
Source§impl Default for EncryptionConfig
impl Default for EncryptionConfig
Source§fn default() -> EncryptionConfig
fn default() -> EncryptionConfig
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for EncryptionConfigwhere
EncryptionConfig: Default,
impl<'de> Deserialize<'de> for EncryptionConfigwhere
EncryptionConfig: Default,
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>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Message for EncryptionConfig
impl Message for EncryptionConfig
Source§impl PartialEq for EncryptionConfig
impl PartialEq for EncryptionConfig
Source§impl Serialize for EncryptionConfig
impl Serialize for EncryptionConfig
impl StructuralPartialEq for EncryptionConfig
Auto Trait Implementations§
impl Freeze for EncryptionConfig
impl RefUnwindSafe for EncryptionConfig
impl Send for EncryptionConfig
impl Sync for EncryptionConfig
impl Unpin for EncryptionConfig
impl UnwindSafe for EncryptionConfig
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
Mutably borrows from an owned value. Read more