Struct tikv::import::ImportSSTService [−][src]
ImportSSTService provides tikv-server with the ability to ingest SST files.
It saves the SST sent from client to a file and then sends a command to raftstore to trigger the ingest process.
Fields
cfg: Config
engine: E
router: Router
threads: ThreadPool
importer: Arc<SSTImporter>
limiter: Limiter
task_slots: Arc<Mutex<HashSet<PathBuf>>>
Implementations
impl<E, Router> ImportSSTService<E, Router> where
E: KvEngine,
Router: 'static + RaftStoreRouter<E>,
[src][−]
E: KvEngine,
Router: 'static + RaftStoreRouter<E>,
pub fn new(
cfg: Config,
router: Router,
engine: E,
importer: Arc<SSTImporter>
) -> ImportSSTService<E, Router>
[src]
cfg: Config,
router: Router,
engine: E,
importer: Arc<SSTImporter>
) -> ImportSSTService<E, Router>
fn acquire_lock(
task_slots: &Arc<Mutex<HashSet<PathBuf>>>,
meta: &SstMeta
) -> Result<bool>
[src]
task_slots: &Arc<Mutex<HashSet<PathBuf>>>,
meta: &SstMeta
) -> Result<bool>
fn release_lock(
task_slots: &Arc<Mutex<HashSet<PathBuf>>>,
meta: &SstMeta
) -> Result<bool>
[src]
task_slots: &Arc<Mutex<HashSet<PathBuf>>>,
meta: &SstMeta
) -> Result<bool>
fn check_write_stall(&self) -> Option<Error>
[src]
fn ingest_files(
&self,
context: Context,
label: &'static str,
ssts: Vec<SstMeta>
) -> impl Future<Output = Result<IngestResponse>>
[src]
&self,
context: Context,
label: &'static str,
ssts: Vec<SstMeta>
) -> impl Future<Output = Result<IngestResponse>>
Trait Implementations
impl<E: Clone, Router: Clone> Clone for ImportSSTService<E, Router> where
E: KvEngine,
[src][+]
E: KvEngine,
impl<E, Router> ImportSst for ImportSSTService<E, Router> where
E: KvEngine,
Router: 'static + RaftStoreRouter<E>,
[src][+]
E: KvEngine,
Router: 'static + RaftStoreRouter<E>,
Auto Trait Implementations
impl<E, Router> !RefUnwindSafe for ImportSSTService<E, Router>
impl<E, Router> Send for ImportSSTService<E, Router> where
Router: Send,
Router: Send,
impl<E, Router> Sync for ImportSSTService<E, Router> where
Router: Sync,
Router: Sync,
impl<E, Router> Unpin for ImportSSTService<E, Router> where
Router: Unpin,
Router: Unpin,
impl<E, Router> !UnwindSafe for ImportSSTService<E, Router>
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,
impl<V, W> ConvertFrom<W> for V where
W: ConvertTo<V>,
[src][+]
W: ConvertTo<V>,
impl<T> From<T> for T
[src][+]
impl<T> Instrument for T
[src][+]
impl<T, U> Into<U> for T where
U: From<T>,
[src][+]
U: From<T>,
impl<T> Pointable for T
[src][+]
impl<T> Pointable for T
[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,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src][+]
U: Into<T>,
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src][+]
U: TryFrom<T>,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
[src][+]
V: MultiLane<T>,