Skip to main content

SourceSession

Trait SourceSession 

Source
pub trait SourceSession: Send {
    // Required methods
    fn info(&self) -> &ServerInfo;
    fn load_tables(&mut self, config: &Config) -> Result<Vec<TableMeta>>;
    fn initialize(&mut self, source_id: &str, config: &Config) -> Result<State>;
    fn start(
        self: Box<Self>,
        config: &Config,
        state: &State,
        once: bool,
    ) -> Result<Box<dyn EventStream>>;
}

Required Methods§

Source

fn info(&self) -> &ServerInfo

Source

fn load_tables(&mut self, config: &Config) -> Result<Vec<TableMeta>>

Source

fn initialize(&mut self, source_id: &str, config: &Config) -> Result<State>

Capture a checkpoint with this ID, the configured plugin and the server UUID.

Source

fn start( self: Box<Self>, config: &Config, state: &State, once: bool, ) -> Result<Box<dyn EventStream>>

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§