pub fn parquet_file_snapshot(chunk: &super::catalog::chunk::Chunk) -> Arc<Self> {
        use super::catalog::chunk::ChunkStage;

        let (state, meta) = match chunk.stage() {
            ChunkStage::Persisted { parquet, meta, .. } => {
                let chunk = Arc::clone(&parquet);
                let state = State::ParquetFile { chunk };
                (state, Arc::clone(&meta))
            }
            _ => {
                panic!("Internal error: This chunk's stage is not Persisted");
            }
        };
        Arc::new(Self {
            id: chunk.id(),
            table_name: chunk.table_name(),
            meta,
            state,
        })
    }
/// Return the snapshot of the chunk with type ParquetFile
/// This function should be only invoked when you know your chunk
/// is ParquetFile type whose state is  WrittenToObjectStore. The
/// reason we have this function is because the above snapshot
/// function always returns the read buffer one for the same state
Return the snapshot of the chunk with type ParquetFile
This function should be only invoked when you know your chunk
is ParquetFile type whose state is  WrittenToObjectStore. The
reason we have this function is because the above snapshot
function always returns the read buffer one for the same state
Return the snapshot of the chunk with type ParquetFile This function should be only invoked when you know your chunk is ParquetFile type whose state is WrittenToObjectStore . The reason we have this function is because the above snapshot function always returns the read buffer one for the same state
pub fn parquet_file_snapshot(chunk: &super::catalog::chunk::Chunk) -> Arc<Self> {
        use super::catalog::chunk::ChunkStage;
        let (state, meta) = match chunk.stage() {
            ChunkStage::Persisted { parquet, meta, .. } => {
                let chunk = Arc::clone(&parquet);
                let state = State::ParquetFile { chunk };
                (state, Arc::clone(&meta))
            }
            _ => {
                panic!("Internal error: This chunk's stage is not Persisted");
            }
        };
        Arc::new(Self {
            id: chunk.id(),
            table_name: chunk.table_name(),
            meta,
            state,
        })
    }
pub fn parquet_file_snapshot ( chunk : & super :: catalog :: chunk :: Chunk ) -> Arc < Self > { use super :: catalog :: chunk :: ChunkStage ; let ( state , meta ) = match chunk . stage ( ) { ChunkStage :: Persisted { parquet , meta , .. } => { let chunk = Arc :: clone ( & parquet ) ; let state = State :: ParquetFile { chunk } ; ( state , Arc :: clone ( & meta ) ) } _ => { panic ! ( " " ) ; } } ; Arc :: new ( Self { id : chunk . id ( ) , table_name : chunk . table_name ( ) , meta , state , } ) }
Return the snapshot of the chunk with type ParquetFile
This function should be only invoked when you know your chunk
is ParquetFile type whose state is  WrittenToObjectStore.
Return the snapshot of the chunk with type ParquetFile This function should be only invoked when you know your chunk is ParquetFile type whose state is WrittenToObjectStore .
chunk
&super::catalog::chunk::Chunk
chunk
&super::catalog::chunk::Chunk