WIP
This commit is contained in:
@@ -304,6 +304,10 @@ pub struct EventsDynStream {
|
||||
}
|
||||
|
||||
impl EventsDynStream {
|
||||
pub fn type_name() -> &'static str {
|
||||
std::any::type_name::<Self>()
|
||||
}
|
||||
|
||||
pub fn new(
|
||||
scalar_type: ScalarType,
|
||||
shape: Shape,
|
||||
@@ -405,7 +409,7 @@ impl Stream for EventsDynStream {
|
||||
use Poll::*;
|
||||
loop {
|
||||
break if self.complete {
|
||||
panic!("poll_next on complete")
|
||||
panic!("{} poll_next on complete", Self::type_name())
|
||||
} else if self.done {
|
||||
self.complete = true;
|
||||
Ready(None)
|
||||
|
||||
@@ -202,6 +202,10 @@ pub struct FileContentStream {
|
||||
}
|
||||
|
||||
impl FileContentStream {
|
||||
pub fn type_name() -> &'static str {
|
||||
std::any::type_name::<Self>()
|
||||
}
|
||||
|
||||
pub fn new(file: File, disk_io_tune: DiskIoTune) -> Self {
|
||||
Self {
|
||||
file,
|
||||
@@ -223,7 +227,7 @@ impl Stream for FileContentStream {
|
||||
use Poll::*;
|
||||
loop {
|
||||
break if self.complete {
|
||||
panic!("poll_next on complete")
|
||||
panic!("{} poll_next on complete", Self::type_name())
|
||||
} else if self.done {
|
||||
self.complete = true;
|
||||
Ready(None)
|
||||
@@ -385,6 +389,10 @@ pub struct FileContentStream2 {
|
||||
}
|
||||
|
||||
impl FileContentStream2 {
|
||||
pub fn type_name() -> &'static str {
|
||||
std::any::type_name::<Self>()
|
||||
}
|
||||
|
||||
pub fn new(file: File, disk_io_tune: DiskIoTune) -> Self {
|
||||
let file = Box::pin(file);
|
||||
Self {
|
||||
@@ -412,7 +420,7 @@ impl Stream for FileContentStream2 {
|
||||
use Poll::*;
|
||||
loop {
|
||||
break if self.complete {
|
||||
panic!("poll_next on complete")
|
||||
panic!("{} poll_next on complete", Self::type_name())
|
||||
} else if self.done {
|
||||
self.complete = true;
|
||||
Ready(None)
|
||||
|
||||
@@ -52,6 +52,10 @@ pub struct EventChunkerMultifile {
|
||||
}
|
||||
|
||||
impl EventChunkerMultifile {
|
||||
pub fn type_name() -> &'static str {
|
||||
std::any::type_name::<Self>()
|
||||
}
|
||||
|
||||
pub fn new(
|
||||
range: NanoRange,
|
||||
channel_config: SfDbChConf,
|
||||
@@ -104,7 +108,7 @@ impl Stream for EventChunkerMultifile {
|
||||
break if let Some(item) = self.log_queue.pop_front() {
|
||||
Ready(Some(Ok(StreamItem::Log(item))))
|
||||
} else if self.complete {
|
||||
panic!("EventChunkerMultifile poll_next on complete");
|
||||
panic!("{} poll_next on complete", Self::type_name());
|
||||
} else if self.done_emit_range_final {
|
||||
self.complete = true;
|
||||
Ready(None)
|
||||
|
||||
Reference in New Issue
Block a user