Struct test_storage::sync_storage::SyncTestStorage [−][src]
A Storage
like structure with sync API.
Only used for test purpose.
Fields
gc_worker: GcWorker<E, RaftStoreBlackHole>
store: Storage<E, DummyLockManager>
Implementations
impl<E: Engine> SyncTestStorage<E>
[src]
pub fn start_auto_gc<S: GcSafePointProvider, R: RegionInfoProvider + Clone + 'static>(
&mut self,
cfg: AutoGcConfig<S, R>
)
[src]
&mut self,
cfg: AutoGcConfig<S, R>
)
pub fn get_storage(&self) -> Storage<E, DummyLockManager>
[src]
pub fn get_engine(&self) -> E
[src]
pub fn get(
&self,
ctx: Context,
key: &Key,
start_ts: impl Into<TimeStamp>
) -> Result<(Option<Value>, Statistics, PerfStatisticsDelta)>
[src]
&self,
ctx: Context,
key: &Key,
start_ts: impl Into<TimeStamp>
) -> Result<(Option<Value>, Statistics, PerfStatisticsDelta)>
pub fn batch_get(
&self,
ctx: Context,
keys: &[Key],
start_ts: impl Into<TimeStamp>
) -> Result<(Vec<Result<KvPair>>, Statistics, PerfStatisticsDelta)>
[src]
&self,
ctx: Context,
keys: &[Key],
start_ts: impl Into<TimeStamp>
) -> Result<(Vec<Result<KvPair>>, Statistics, PerfStatisticsDelta)>
pub fn batch_get_command(
&self,
ctx: Context,
keys: &[&[u8]],
start_ts: u64
) -> Result<Vec<Option<Vec<u8>>>>
[src]
&self,
ctx: Context,
keys: &[&[u8]],
start_ts: u64
) -> Result<Vec<Option<Vec<u8>>>>
pub fn scan(
&self,
ctx: Context,
start_key: Key,
end_key: Option<Key>,
limit: usize,
key_only: bool,
start_ts: impl Into<TimeStamp>
) -> Result<Vec<Result<KvPair>>>
[src]
&self,
ctx: Context,
start_key: Key,
end_key: Option<Key>,
limit: usize,
key_only: bool,
start_ts: impl Into<TimeStamp>
) -> Result<Vec<Result<KvPair>>>
pub fn reverse_scan(
&self,
ctx: Context,
start_key: Key,
end_key: Option<Key>,
limit: usize,
key_only: bool,
start_ts: impl Into<TimeStamp>
) -> Result<Vec<Result<KvPair>>>
[src]
&self,
ctx: Context,
start_key: Key,
end_key: Option<Key>,
limit: usize,
key_only: bool,
start_ts: impl Into<TimeStamp>
) -> Result<Vec<Result<KvPair>>>
pub fn prewrite(
&self,
ctx: Context,
mutations: Vec<Mutation>,
primary: Vec<u8>,
start_ts: impl Into<TimeStamp>
) -> Result<PrewriteResult>
[src]
&self,
ctx: Context,
mutations: Vec<Mutation>,
primary: Vec<u8>,
start_ts: impl Into<TimeStamp>
) -> Result<PrewriteResult>
pub fn commit(
&self,
ctx: Context,
keys: Vec<Key>,
start_ts: impl Into<TimeStamp>,
commit_ts: impl Into<TimeStamp>
) -> Result<TxnStatus>
[src]
&self,
ctx: Context,
keys: Vec<Key>,
start_ts: impl Into<TimeStamp>,
commit_ts: impl Into<TimeStamp>
) -> Result<TxnStatus>
pub fn cleanup(
&self,
ctx: Context,
key: Key,
start_ts: impl Into<TimeStamp>,
current_ts: impl Into<TimeStamp>
) -> Result<()>
[src]
&self,
ctx: Context,
key: Key,
start_ts: impl Into<TimeStamp>,
current_ts: impl Into<TimeStamp>
) -> Result<()>
pub fn rollback(
&self,
ctx: Context,
keys: Vec<Key>,
start_ts: impl Into<TimeStamp>
) -> Result<()>
[src]
&self,
ctx: Context,
keys: Vec<Key>,
start_ts: impl Into<TimeStamp>
) -> Result<()>
pub fn scan_locks(
&self,
ctx: Context,
max_ts: impl Into<TimeStamp>,
start_key: Option<Key>,
end_key: Option<Key>,
limit: usize
) -> Result<Vec<LockInfo>>
[src]
&self,
ctx: Context,
max_ts: impl Into<TimeStamp>,
start_key: Option<Key>,
end_key: Option<Key>,
limit: usize
) -> Result<Vec<LockInfo>>
pub fn resolve_lock(
&self,
ctx: Context,
start_ts: impl Into<TimeStamp>,
commit_ts: Option<impl Into<TimeStamp>>
) -> Result<()>
[src]
&self,
ctx: Context,
start_ts: impl Into<TimeStamp>,
commit_ts: Option<impl Into<TimeStamp>>
) -> Result<()>
pub fn resolve_lock_batch(
&self,
ctx: Context,
txns: Vec<(TimeStamp, TimeStamp)>
) -> Result<()>
[src]
&self,
ctx: Context,
txns: Vec<(TimeStamp, TimeStamp)>
) -> Result<()>
pub fn gc(&self, _: Context, safe_point: impl Into<TimeStamp>) -> Result<()>
[src]
pub fn raw_get(
&self,
ctx: Context,
cf: String,
key: Vec<u8>
) -> Result<Option<Vec<u8>>>
[src]
&self,
ctx: Context,
cf: String,
key: Vec<u8>
) -> Result<Option<Vec<u8>>>
pub fn raw_put(
&self,
ctx: Context,
cf: String,
key: Vec<u8>,
value: Vec<u8>
) -> Result<()>
[src]
&self,
ctx: Context,
cf: String,
key: Vec<u8>,
value: Vec<u8>
) -> Result<()>
pub fn raw_delete(&self, ctx: Context, cf: String, key: Vec<u8>) -> Result<()>
[src]
pub fn raw_scan(
&self,
ctx: Context,
cf: String,
start_key: Vec<u8>,
end_key: Option<Vec<u8>>,
limit: usize
) -> Result<Vec<Result<KvPair>>>
[src]
&self,
ctx: Context,
cf: String,
start_key: Vec<u8>,
end_key: Option<Vec<u8>>,
limit: usize
) -> Result<Vec<Result<KvPair>>>
pub fn reverse_raw_scan(
&self,
ctx: Context,
cf: String,
start_key: Vec<u8>,
end_key: Option<Vec<u8>>,
limit: usize
) -> Result<Vec<Result<KvPair>>>
[src]
&self,
ctx: Context,
cf: String,
start_key: Vec<u8>,
end_key: Option<Vec<u8>>,
limit: usize
) -> Result<Vec<Result<KvPair>>>
pub fn raw_compare_and_swap_atomic(
&self,
ctx: Context,
cf: String,
key: Vec<u8>,
previous_value: Option<Vec<u8>>,
value: Vec<u8>,
ttl: u64
) -> Result<(Option<Vec<u8>>, bool)>
[src]
&self,
ctx: Context,
cf: String,
key: Vec<u8>,
previous_value: Option<Vec<u8>>,
value: Vec<u8>,
ttl: u64
) -> Result<(Option<Vec<u8>>, bool)>
pub fn raw_batch_put_atomic(
&self,
ctx: Context,
cf: String,
pairs: Vec<KvPair>,
ttl: u64
) -> Result<()>
[src]
&self,
ctx: Context,
cf: String,
pairs: Vec<KvPair>,
ttl: u64
) -> Result<()>
pub fn raw_batch_delete_atomic(
&self,
ctx: Context,
cf: String,
keys: Vec<Vec<u8>>
) -> Result<()>
[src]
&self,
ctx: Context,
cf: String,
keys: Vec<Vec<u8>>
) -> Result<()>
Trait Implementations
impl<E: Clone + Engine> Clone for SyncTestStorage<E>
[src]
fn clone(&self) -> SyncTestStorage<E>
[src]
pub fn clone_from(&mut self, source: &Self)
1.0.0[src]
Auto Trait Implementations
impl<E> !RefUnwindSafe for SyncTestStorage<E>
impl<E> Send for SyncTestStorage<E>
impl<E> Sync for SyncTestStorage<E> where
E: Sync,
E: Sync,
impl<E> Unpin for SyncTestStorage<E> where
E: Unpin,
E: Unpin,
impl<E> !UnwindSafe for SyncTestStorage<E>
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<V, W> ConvertFrom<W> for V where
W: ConvertTo<V>,
[src]
W: ConvertTo<V>,
pub fn convert_from(ctx: &mut EvalContext, from: W) -> Result<V, Error>
[src]
impl<T> From<T> for T
[src]
impl<T> Instrument for T
[src]
pub fn instrument(self, span: Span) -> Instrumented<Self>
[src]
pub fn in_current_span(self) -> Instrumented<Self>
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Pointable for T
[src]
pub const ALIGN: usize
[src]
type Init = T
The type for initializers.
pub unsafe fn init(init: <T as Pointable>::Init) -> usize
[src]
pub unsafe fn deref<'a>(ptr: usize) -> &'a T
[src]
pub unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T
[src]
pub unsafe fn drop(ptr: usize)
[src]
impl<T> Pointable for T
[src]
pub const ALIGN: usize
[src]
type Init = T
The type for initializers.
pub unsafe fn init(init: <T as Pointable>::Init) -> usize
[src]
pub unsafe fn deref<'a>(ptr: usize) -> &'a T
[src]
pub unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T
[src]
pub unsafe fn drop(ptr: usize)
[src]
impl<T> Same<T> for T
[src]
type Output = T
Should always be Self
impl<T> Sealed<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
[src]
V: MultiLane<T>,