pub struct CallOptionsBuilder { /* private fields */ }
Implementations§
Source§impl CallOptionsBuilder
impl CallOptionsBuilder
pub fn new() -> CallOptionsBuilder
Sourcepub fn no_writes(self) -> CallOptionsBuilder
pub fn no_writes(self) -> CallOptionsBuilder
Enable this option will not allow RM_Call to perform write commands
Sourcepub fn script_mode(self) -> CallOptionsBuilder
pub fn script_mode(self) -> CallOptionsBuilder
Enable this option will run RM_Call is script mode. This mean that Redis will enable the following protections:
- Not allow running dangerous commands like ‘shutdown’
- Not allow running write commands on OOM or if there are not enough good replica’s connected
Sourcepub fn verify_acl(self) -> CallOptionsBuilder
pub fn verify_acl(self) -> CallOptionsBuilder
Enable this option will perform ACL validation on the user attached to the context that is used to invoke the call.
Sourcepub fn verify_oom(self) -> CallOptionsBuilder
pub fn verify_oom(self) -> CallOptionsBuilder
Enable this option will OOM validation before running the command
Sourcepub fn errors_as_replies(self) -> CallOptionsBuilder
pub fn errors_as_replies(self) -> CallOptionsBuilder
Enable this option will return error as CallReply object instead of setting errno (it is usually recommend to enable it)
Sourcepub fn replicate(self) -> CallOptionsBuilder
pub fn replicate(self) -> CallOptionsBuilder
Enable this option will cause the command to be replicaed to the replica and AOF
Sourcepub fn resp(self, resp: CallOptionResp) -> CallOptionsBuilder
pub fn resp(self, resp: CallOptionResp) -> CallOptionsBuilder
Allow control the protocol version in which the replies will be returned.
Sourcepub fn build(self) -> CallOptions
pub fn build(self) -> CallOptions
Construct a CallOption object that can be used to run commands using call_ext
Trait Implementations§
Auto Trait Implementations§
impl Freeze for CallOptionsBuilder
impl RefUnwindSafe for CallOptionsBuilder
impl Send for CallOptionsBuilder
impl Sync for CallOptionsBuilder
impl Unpin for CallOptionsBuilder
impl UnwindSafe for CallOptionsBuilder
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