Struct redis_driver::ClientTrackingOptions
source · [−]pub struct ClientTrackingOptions { /* private fields */ }
Expand description
Options for the client_tracking
command.
Implementations
sourceimpl ClientTrackingOptions
impl ClientTrackingOptions
sourcepub fn redirect(self, client_id: i64) -> Self
pub fn redirect(self, client_id: i64) -> Self
send invalidation messages to the connection with the specified ID.
sourcepub fn broadcasting(self) -> Self
pub fn broadcasting(self) -> Self
enable tracking in broadcasting mode.
sourcepub fn prefix<P: Into<BulkString>>(self, prefix: P) -> Self
pub fn prefix<P: Into<BulkString>>(self, prefix: P) -> Self
for broadcasting, register a given key prefix, so that notifications will be provided only for keys starting with this string.
This option can be given multiple times to register multiple prefixes.
sourcepub fn optin(self) -> Self
pub fn optin(self) -> Self
when broadcasting is NOT active, normally don’t track keys in read only commands,
unless they are called immediately after a CLIENT CACHING yes
command.
Trait Implementations
sourceimpl Default for ClientTrackingOptions
impl Default for ClientTrackingOptions
sourcefn default() -> ClientTrackingOptions
fn default() -> ClientTrackingOptions
Returns the “default value” for a type. Read more
sourceimpl IntoArgs for ClientTrackingOptions
impl IntoArgs for ClientTrackingOptions
fn into_args(self, args: CommandArgs) -> CommandArgs
fn num_args(&self) -> usize
Auto Trait Implementations
impl RefUnwindSafe for ClientTrackingOptions
impl Send for ClientTrackingOptions
impl Sync for ClientTrackingOptions
impl Unpin for ClientTrackingOptions
impl UnwindSafe for ClientTrackingOptions
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more