pub struct ClientTrackingOptions { /* private fields */ }
Expand description
Options for the client_tracking
command.
Implementations§
Source§impl 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<CommandArg>>(self, prefix: P) -> Self
pub fn prefix<P: Into<CommandArg>>(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§
Source§impl Default for ClientTrackingOptions
impl Default for ClientTrackingOptions
Source§fn default() -> ClientTrackingOptions
fn default() -> ClientTrackingOptions
Returns the “default value” for a type. Read more
Source§impl IntoArgs for ClientTrackingOptions
impl IntoArgs for ClientTrackingOptions
fn into_args(self, args: CommandArgs) -> CommandArgs
fn num_args(&self) -> usize
Auto Trait Implementations§
impl Freeze for ClientTrackingOptions
impl RefUnwindSafe for ClientTrackingOptions
impl Send for ClientTrackingOptions
impl Sync for ClientTrackingOptions
impl Unpin for ClientTrackingOptions
impl UnwindSafe for ClientTrackingOptions
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