Skip to main content

MemoryDbState

Struct MemoryDbState 

Source
pub struct MemoryDbState {
    pub clusters: HashMap<String, Cluster>,
    pub snapshots: HashMap<String, SnapshotData>,
    pub subnet_groups: HashMap<String, SubnetGroupData>,
    pub acls: HashMap<String, AclData>,
    pub tags: TagsMap,
}
Expand description

In-memory state for the MemoryDB service.

Fields§

§clusters: HashMap<String, Cluster>

Clusters keyed by cluster name.

§snapshots: HashMap<String, SnapshotData>

Snapshots keyed by snapshot name.

§subnet_groups: HashMap<String, SubnetGroupData>

Subnet groups keyed by subnet group name.

§acls: HashMap<String, AclData>

ACLs keyed by ACL name.

§tags: TagsMap

Tags keyed by resource ARN.

Implementations§

Source§

impl MemoryDbState

Source

pub fn create_cluster( &mut self, account_id: &str, region: &str, name: &str, node_type: &str, acl_name: &str, description: Option<&str>, num_shards: Option<i32>, num_replicas_per_shard: Option<i32>, subnet_group_name: Option<&str>, security_group_ids: Vec<String>, engine_version: Option<&str>, maintenance_window: Option<&str>, snapshot_retention_limit: Option<i32>, snapshot_window: Option<&str>, parameter_group_name: Option<&str>, tls_enabled: Option<bool>, auto_minor_version_upgrade: Option<bool>, tags: Vec<TagData>, ) -> Result<&Cluster, MemoryDbError>

Source

pub fn describe_clusters( &self, cluster_name: Option<&str>, ) -> Result<Vec<&Cluster>, MemoryDbError>

Source

pub fn delete_cluster( &mut self, name: &str, final_snapshot_name: Option<&str>, account_id: &str, region: &str, ) -> Result<Cluster, MemoryDbError>

Source

pub fn update_cluster( &mut self, name: &str, description: Option<&str>, security_group_ids: Option<Vec<String>>, maintenance_window: Option<&str>, snapshot_retention_limit: Option<i32>, snapshot_window: Option<&str>, parameter_group_name: Option<&str>, engine_version: Option<&str>, num_shards: Option<i32>, num_replicas_per_shard: Option<i32>, node_type: Option<&str>, acl_name: Option<&str>, ) -> Result<&Cluster, MemoryDbError>

Source

pub fn create_snapshot( &mut self, account_id: &str, region: &str, snapshot_name: &str, cluster_name: &str, kms_key_id: Option<&str>, tags: Vec<TagData>, ) -> Result<&SnapshotData, MemoryDbError>

Source

pub fn delete_snapshot( &mut self, snapshot_name: &str, ) -> Result<SnapshotData, MemoryDbError>

Source

pub fn describe_snapshots( &self, cluster_name: Option<&str>, snapshot_name: Option<&str>, source: Option<&str>, ) -> Result<Vec<&SnapshotData>, MemoryDbError>

Source

pub fn create_subnet_group( &mut self, account_id: &str, region: &str, name: &str, description: Option<&str>, subnet_ids: Vec<String>, tags: Vec<TagData>, ) -> Result<&SubnetGroupData, MemoryDbError>

Source

pub fn delete_subnet_group( &mut self, name: &str, ) -> Result<SubnetGroupData, MemoryDbError>

Source

pub fn describe_subnet_groups( &self, name: Option<&str>, ) -> Result<Vec<&SubnetGroupData>, MemoryDbError>

Source

pub fn tag_resource( &mut self, resource_arn: &str, tags: Vec<TagData>, ) -> Result<Vec<TagData>, MemoryDbError>

Source

pub fn untag_resource( &mut self, resource_arn: &str, tag_keys: &[String], ) -> Result<Vec<TagData>, MemoryDbError>

Source

pub fn list_tags( &self, resource_arn: &str, ) -> Result<Vec<TagData>, MemoryDbError>

Trait Implementations§

Source§

impl Debug for MemoryDbState

Source§

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

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

impl Default for MemoryDbState

Source§

fn default() -> Self

Returns the “default value” for a type. Read more

Auto Trait Implementations§

§

impl Forget for MemoryDbState

§

impl Freeze for MemoryDbState

§

impl Move for MemoryDbState

§

impl RefUnwindSafe for MemoryDbState

§

impl Send for MemoryDbState
where RawTable<(String, Cluster)>: Send, RawTable<(String, SnapshotData)>: Send, RawTable<(String, SubnetGroupData)>: Send, RawTable<(String, AclData)>: Send, RawTable<(String, Vec<TagData>)>: Send,

§

impl Sync for MemoryDbState
where RawTable<(String, Cluster)>: Sync, RawTable<(String, SnapshotData)>: Sync, RawTable<(String, SubnetGroupData)>: Sync, RawTable<(String, AclData)>: Sync, RawTable<(String, Vec<TagData>)>: Sync,

§

impl Unpin for MemoryDbState
where *const u8 is !null: Unpin, NonZero<i32>: Unpin, Utc: Unpin,

§

impl UnsafeUnpin for MemoryDbState

§

impl UnwindSafe for MemoryDbState

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> 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> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

impl<Unshared, Shared> IntoShared<Shared> for Unshared
where Shared: FromUnshared<Unshared>,

Source§

fn into_shared(self) -> Shared

Creates a shared type from an unshared type.
Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

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

Source§

type Error = !

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

fn try_from(value: U) -> Result<T, !>

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