ConfigInterface

Trait ConfigInterface 

Source
pub trait ConfigInterface: ClientLike + Sized {
    // Provided methods
    fn config_resetstat(&self) -> impl Future<Output = FredResult<()>> + Send { ... }
    fn config_rewrite(&self) -> impl Future<Output = FredResult<()>> + Send { ... }
    fn config_get<R, S>(
        &self,
        parameter: S,
    ) -> impl Future<Output = FredResult<R>> + Send
       where R: FromValue,
             S: Into<Str> + Send { ... }
    fn config_set<P, V>(
        &self,
        parameter: P,
        value: V,
    ) -> impl Future<Output = FredResult<()>> + Send
       where P: Into<Str> + Send,
             V: TryInto<Value> + Send,
             V::Error: Into<Error> + Send { ... }
}
Available on crate feature i-config only.
Expand description

Functions that implement the config interface.

Provided Methods§

Source

fn config_resetstat(&self) -> impl Future<Output = FredResult<()>> + Send

Resets the statistics reported by Redis using the INFO command.

https://redis.io/commands/config-resetstat

Source

fn config_rewrite(&self) -> impl Future<Output = FredResult<()>> + Send

The CONFIG REWRITE command rewrites the redis.conf file the server was started with, applying the minimal changes needed to make it reflect the configuration currently used by the server, which may be different compared to the original one because of the use of the CONFIG SET command.

https://redis.io/commands/config-rewrite

Source

fn config_get<R, S>( &self, parameter: S, ) -> impl Future<Output = FredResult<R>> + Send
where R: FromValue, S: Into<Str> + Send,

The CONFIG GET command is used to read the configuration parameters of a running Redis server.

https://redis.io/commands/config-get

Source

fn config_set<P, V>( &self, parameter: P, value: V, ) -> impl Future<Output = FredResult<()>> + Send
where P: Into<Str> + Send, V: TryInto<Value> + Send, V::Error: Into<Error> + Send,

The CONFIG SET command is used in order to reconfigure the server at run time without the need to restart Redis.

https://redis.io/commands/config-set

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§