pub async fn write_to_object_store(
        &self,
        partition_key: String,
        chunk_id: u32,
        table_name: String,
        stream: SendableRecordBatchStream,
        metadata: IoxMetadata,
    ) -> Result<(Path, ParquetMetaData)> {
        // Create full path location of this file in object store
        let path = self.location(partition_key, chunk_id, table_name);

        let schema = stream.schema();
        let data = Self::parquet_stream_to_bytes(stream, schema, metadata).await?;
        // TODO: make this work w/o cloning the byte vector (https://github.com/influxdata/influxdb_iox/issues/1504)
        let md =
            read_parquet_metadata_from_file(data.clone()).context(ExtractingMetadataFailure)?;
        self.to_object_store(data, &path).await?;

        Ok((path.clone(), md))
    }
/// Write the given stream of data of a specified table of
/// a specified partitioned chunk to a parquet file of this storage
Write the given stream of data of a specified table of
a specified partitioned chunk to a parquet file of this storage
Write the given stream of data of a specified table of a specified partitioned chunk to a parquet file of this storage
pub async fn write_to_object_store(
        &self,
        partition_key: String,
        chunk_id: u32,
        table_name: String,
        stream: SendableRecordBatchStream,
        metadata: IoxMetadata,
    ) -> Result<(Path, ParquetMetaData)> {
        // Create full path location of this file in object store
        let path = self.location(partition_key, chunk_id, table_name);
        let schema = stream.schema();
        let data = Self::parquet_stream_to_bytes(stream, schema, metadata).await?;
        // TODO: make this work w/o cloning the byte vector (https://github.com/influxdata/influxdb_iox/issues/1504)
        let md =
            read_parquet_metadata_from_file(data.clone()).context(ExtractingMetadataFailure)?;
        self.to_object_store(data, &path).await?;
        Ok((path.clone(), md))
    }
pub async fn write_to_object_store ( & self , partition_key : String , chunk_id : u32 , table_name : String , stream : SendableRecordBatchStream , metadata : IoxMetadata , ) -> Result < ( Path , ParquetMetaData ) > { // Create full path location of this file in object store let path = self . location ( partition_key , chunk_id , table_name ) ; let schema = stream . schema ( ) ; let data = Self :: parquet_stream_to_bytes ( stream , schema , metadata ) . await ? ; // TODO: make this work w/o cloning the byte vector (https://github.com/influxdata/influxdb_iox/issues/1504) let md = read_parquet_metadata_from_file ( data . clone ( ) ) . context ( ExtractingMetadataFailure ) ? ; self . to_object_store ( data , & path ) . await ? ; Ok ( ( path . clone ( ) , md ) ) }
Write the given stream of data of a specified table of
a specified partitioned chunk to a parquet file of this storage
Write the given stream of data of a specified table of a specified partitioned chunk to a parquet file of this storage
&self
partition_key
String
chunk_id
u32
table_name
String
stream
SendableRecordBatchStream
metadata
IoxMetadata
&self
partition_key
String
chunk_id
u32
table_name
String
stream
SendableRecordBatchStream
metadata
IoxMetadata