pub struct AvroObjectReader { /* private fields */ }Implement AsyncFileReader directly instead; see the example on the AsyncFileReader trait documentation and arrow-avro/examples/object_store.rs. Use SpawnedReader to perform I/O on a dedicated runtime. See also https://github.com/apache/arrow-rs/issues/10308
async and object_store only.Expand description
An implementation of an AsyncFileReader using the ObjectStore API.
Implementationsยง
Sourceยงimpl AvroObjectReader
impl AvroObjectReader
Sourcepub fn new(store: Arc<dyn ObjectStore>, path: Path) -> Self
pub fn new(store: Arc<dyn ObjectStore>, path: Path) -> Self
Creates a new Self from a store implementation and file location.
Sourcepub fn with_runtime(self, handle: Handle) -> Self
๐Deprecated since 59.2.0: Wrap the reader in a SpawnedReader instead, e.g. SpawnedReader::new(reader, handle). See also https://github.com/apache/arrow-rs/issues/10308
pub fn with_runtime(self, handle: Handle) -> Self
Wrap the reader in a SpawnedReader instead, e.g. SpawnedReader::new(reader, handle). See also https://github.com/apache/arrow-rs/issues/10308
Perform IO on the provided tokio runtime
Tokio is a cooperative scheduler, and relies on tasks yielding in a timely manner to service IO. Therefore, running IO and CPU-bound tasks, such as avro decoding, on the same tokio runtime can lead to degraded throughput, dropped connections and other issues. For more information see here.
Trait Implementationsยง
Sourceยงimpl AsyncFileReader for AvroObjectReader
impl AsyncFileReader for AvroObjectReader
Sourceยงimpl Clone for AvroObjectReader
impl Clone for AvroObjectReader
Sourceยงfn clone(&self) -> AvroObjectReader
fn clone(&self) -> AvroObjectReader
1.0.0 (const: unstable) ยท Sourceยงfn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more