pub struct StreamProcessor { /* private fields */ }Expand description
Stream processor for handling streaming execution
Implementations§
Source§impl StreamProcessor
impl StreamProcessor
pub fn new(config: StreamingConfig) -> Self
Sourcepub fn split_batch<T: Clone>(
&self,
batch: &BatchResult<T>,
) -> Vec<(ChunkMetadata, Vec<T>)>
pub fn split_batch<T: Clone>( &self, batch: &BatchResult<T>, ) -> Vec<(ChunkMetadata, Vec<T>)>
Split batch result into chunks based on configuration
Sourcepub fn merge_results<T>(results: Vec<StreamResult<T>>) -> BatchResult<T>
pub fn merge_results<T>(results: Vec<StreamResult<T>>) -> BatchResult<T>
Merge stream results back into a single batch
Sourcepub fn adaptive_chunk_size(&self, results: &[StreamResult<impl Clone>]) -> usize
pub fn adaptive_chunk_size(&self, results: &[StreamResult<impl Clone>]) -> usize
Calculate adaptive chunk size based on performance metrics
pub fn config(&self) -> &StreamingConfig
Trait Implementations§
Auto Trait Implementations§
impl Freeze for StreamProcessor
impl RefUnwindSafe for StreamProcessor
impl Send for StreamProcessor
impl Sync for StreamProcessor
impl Unpin for StreamProcessor
impl UnwindSafe for StreamProcessor
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