FixedDatabaseHandler

Struct FixedDatabaseHandler 

Source
pub struct FixedDatabaseHandler { /* private fields */ }
Expand description

Handler for Essentials database operations

Manages fixed-capacity databases with simplified configuration and predictable pricing for Redis Cloud Essentials subscriptions.

Implementations§

Source§

impl FixedDatabaseHandler

Source

pub fn new(client: CloudClient) -> Self

Create a new handler

Source

pub async fn list( &self, subscription_id: i32, offset: Option<i32>, limit: Option<i32>, ) -> Result<AccountFixedSubscriptionDatabases>

Get all databases in an Essentials subscription Gets a list of all databases in the specified Essentials subscription.

GET /fixed/subscriptions/{subscriptionId}/databases

Source

pub async fn create( &self, subscription_id: i32, request: &FixedDatabaseCreateRequest, ) -> Result<TaskStateUpdate>

Create Essentials database Creates a new database in the specified Essentials subscription.

POST /fixed/subscriptions/{subscriptionId}/databases

Source

pub async fn delete_by_id( &self, subscription_id: i32, database_id: i32, ) -> Result<TaskStateUpdate>

Delete Essentials database Deletes a database from an Essentials subscription.

DELETE /fixed/subscriptions/{subscriptionId}/databases/{databaseId}

Source

pub async fn get_by_id( &self, subscription_id: i32, database_id: i32, ) -> Result<FixedDatabase>

Get a single Essentials database Gets details and settings of a single database in an Essentials subscription.

GET /fixed/subscriptions/{subscriptionId}/databases/{databaseId}

Source

pub async fn update( &self, subscription_id: i32, database_id: i32, request: &FixedDatabaseUpdateRequest, ) -> Result<TaskStateUpdate>

Update Essentials database Updates the specified Essentials database.

PUT /fixed/subscriptions/{subscriptionId}/databases/{databaseId}

Source

pub async fn get_backup_status( &self, subscription_id: i32, database_id: i32, ) -> Result<TaskStateUpdate>

Backup Essentials database status Information on the latest database backup status identified by Essentials subscription Id and Essentials database Id

GET /fixed/subscriptions/{subscriptionId}/databases/{databaseId}/backup

Source

pub async fn backup( &self, subscription_id: i32, database_id: i32, request: &FixedDatabaseBackupRequest, ) -> Result<TaskStateUpdate>

Back up Essentials database Manually back up the specified Essentials database to a backup path. By default, backups will be stored in the ‘periodicBackupPath’ location for this database.

POST /fixed/subscriptions/{subscriptionId}/databases/{databaseId}/backup

Source

pub async fn get_import_status( &self, subscription_id: i32, database_id: i32, ) -> Result<TaskStateUpdate>

Get Essentials database import status Gets information on the latest import attempt for this Essentials database.

GET /fixed/subscriptions/{subscriptionId}/databases/{databaseId}/import

Source

pub async fn import( &self, subscription_id: i32, database_id: i32, request: &FixedDatabaseImportRequest, ) -> Result<TaskStateUpdate>

Import data to an Essentials database Imports data from an RDB file or from a different Redis database into this Essentials database. WARNING: Importing data into a database removes all existing data from the database.

POST /fixed/subscriptions/{subscriptionId}/databases/{databaseId}/import

Source

pub async fn get_slow_log( &self, subscription_id: i32, database_id: i32, ) -> Result<DatabaseSlowLogEntries>

Get Essentials database slow-log by database id Get slow-log for a specific database identified by Essentials subscription Id and database Id

GET /fixed/subscriptions/{subscriptionId}/databases/{databaseId}/slow-log

Source

pub async fn get_tags( &self, subscription_id: i32, database_id: i32, ) -> Result<CloudTags>

Get database tags Gets a list of all database tags.

GET /fixed/subscriptions/{subscriptionId}/databases/{databaseId}/tags

Source

pub async fn create_tag( &self, subscription_id: i32, database_id: i32, request: &DatabaseTagCreateRequest, ) -> Result<CloudTag>

Add a database tag Adds a single database tag to a database.

POST /fixed/subscriptions/{subscriptionId}/databases/{databaseId}/tags

Source

pub async fn update_tags( &self, subscription_id: i32, database_id: i32, request: &DatabaseTagsUpdateRequest, ) -> Result<CloudTags>

Overwrite database tags Overwrites all tags on the database.

PUT /fixed/subscriptions/{subscriptionId}/databases/{databaseId}/tags

Source

pub async fn delete_tag( &self, subscription_id: i32, database_id: i32, tag_key: String, ) -> Result<HashMap<String, Value>>

Delete database tag Removes the specified tag from the database.

DELETE /fixed/subscriptions/{subscriptionId}/databases/{databaseId}/tags/{tagKey}

Source

pub async fn update_tag( &self, subscription_id: i32, database_id: i32, tag_key: String, request: &DatabaseTagUpdateRequest, ) -> Result<CloudTag>

Update database tag value Updates the value of the specified database tag.

PUT /fixed/subscriptions/{subscriptionId}/databases/{databaseId}/tags/{tagKey}

Source

pub async fn create_fixed_database( &self, subscription_id: i32, request: &FixedDatabaseCreateRequest, ) -> Result<TaskStateUpdate>

👎Deprecated since 0.8.0: Use create instead

Create fixed database (backward compatibility)

Deprecated: Use create instead

Source

pub async fn get_fixed_database( &self, subscription_id: i32, database_id: i32, ) -> Result<TaskStateUpdate>

👎Deprecated since 0.8.0: Use get_by_id instead

Get fixed database (backward compatibility)

Deprecated: Use get_by_id instead

Source

pub async fn update_fixed_database( &self, subscription_id: i32, database_id: i32, request: &FixedDatabaseUpdateRequest, ) -> Result<TaskStateUpdate>

👎Deprecated since 0.8.0: Use update instead

Update fixed database (backward compatibility)

Deprecated: Use update instead

Source

pub async fn delete_fixed_database( &self, subscription_id: i32, database_id: i32, ) -> Result<TaskStateUpdate>

👎Deprecated since 0.8.0: Use delete_by_id instead

Delete fixed database (backward compatibility)

Deprecated: Use delete_by_id instead

Source

pub async fn backup_fixed_database( &self, subscription_id: i32, database_id: i32, request: &FixedDatabaseBackupRequest, ) -> Result<TaskStateUpdate>

👎Deprecated since 0.8.0: Use backup instead

Backup fixed database (backward compatibility)

Deprecated: Use backup instead

Source

pub async fn get_fixed_subscription_databases( &self, subscription_id: i32, offset: Option<i32>, limit: Option<i32>, ) -> Result<AccountFixedSubscriptionDatabases>

👎Deprecated since 0.8.0: Use list instead

Get fixed subscription databases (backward compatibility)

Deprecated: Use list instead

Source

pub async fn fixed_database_by_id( &self, subscription_id: i32, database_id: i32, ) -> Result<FixedDatabase>

👎Deprecated since 0.8.0: Use get_by_id instead

Get fixed database by id (backward compatibility)

Deprecated: Use get_by_id instead

Source

pub async fn get_fixed_subscription_database_by_id( &self, subscription_id: i32, database_id: i32, ) -> Result<FixedDatabase>

👎Deprecated since 0.8.0: Use get_by_id instead

Get fixed subscription database by id (backward compatibility)

Deprecated: Use get_by_id instead

Source

pub async fn delete_fixed_database_by_id( &self, subscription_id: i32, database_id: i32, ) -> Result<TaskStateUpdate>

👎Deprecated since 0.8.0: Use delete_by_id instead

Delete fixed database by id (backward compatibility)

Deprecated: Use delete_by_id instead

Source

pub async fn import_fixed_database( &self, subscription_id: i32, database_id: i32, request: &FixedDatabaseImportRequest, ) -> Result<TaskStateUpdate>

👎Deprecated since 0.8.0: Use import instead

Import fixed database (backward compatibility)

Deprecated: Use import instead

Source

pub async fn create_fixed_database_tag( &self, subscription_id: i32, database_id: i32, request: &DatabaseTagCreateRequest, ) -> Result<CloudTag>

👎Deprecated since 0.8.0: Use create_tag instead

Create fixed database tag (backward compatibility)

Deprecated: Use create_tag instead

Source

pub async fn get_fixed_database_tags( &self, subscription_id: i32, database_id: i32, ) -> Result<CloudTags>

👎Deprecated since 0.8.0: Use get_tags instead

Get fixed database tags (backward compatibility)

Deprecated: Use get_tags instead

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> 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, 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> ErasedDestructor for T
where T: 'static,