async fn list_files(
    object_store: &ObjectStore,
    server_id: ServerId,
    db_name: &str,
) -> Result<Vec<(Path, FileType, u64, Uuid)>> {
    let list_path = catalog_path(object_store, server_id, db_name);
    let paths = object_store
        .list(Some(&list_path))
        .await
        .context(Read {})?
        .map_ok(|paths| {
            paths
                .into_iter()
                .filter_map(|path| {
                    parse_file_path(path.clone()).map(|(revision_counter, uuid, file_type)| {
                        (path.clone(), file_type, revision_counter, uuid)
                    })
                })
                .collect()
        })
        .try_concat()
        .await
        .context(Read {})?;
    Ok(paths)
}
/// Load a list of all transaction file from object store. Also parse revision counter and transaction UUID.
///
/// The files are in no particular order!
Load a list of all transaction file from object store. Also parse revision counter and transaction UUID.
The files are in no particular order!
Load a list of all transaction file from object store . Also parse revision counter and transaction UUID . The files are in no particular order!
async fn list_files(
    object_store: &ObjectStore,
    server_id: ServerId,
    db_name: &str,
) -> Result<Vec<(Path, FileType, u64, Uuid)>> {
    let list_path = catalog_path(object_store, server_id, db_name);
    let paths = object_store
        .list(Some(&list_path))
        .await
        .context(Read {})?
        .map_ok(|paths| {
            paths
                .into_iter()
                .filter_map(|path| {
                    parse_file_path(path.clone()).map(|(revision_counter, uuid, file_type)| {
                        (path.clone(), file_type, revision_counter, uuid)
                    })
                })
                .collect()
        })
        .try_concat()
        .await
        .context(Read {})?;
    Ok(paths)
}
async fn list_files ( object_store : & ObjectStore , server_id : ServerId , db_name : & str , ) -> Result < Vec < ( Path , FileType , u64 , Uuid ) > > { let list_path = catalog_path ( object_store , server_id , db_name ) ; let paths = object_store . list ( Some ( & list_path ) ) . await . context ( Read { } ) ? . map_ok ( | paths | { paths . into_iter ( ) . filter_map ( | path | { parse_file_path ( path . clone ( ) ) . map ( | ( revision_counter , uuid , file_type ) | { ( path . clone ( ) , file_type , revision_counter , uuid ) } ) } ) . collect ( ) } ) . try_concat ( ) . await . context ( Read { } ) ? ; Ok ( paths ) }
Load a list of all transaction file from object store.
Load a list of all transaction file from object store .
object_store
&ObjectStore
server_id
ServerId
db_name
&str
object_store
&ObjectStore
server_id
ServerId
db_name
&str