pub async fn break_catalog_with_weird_version<S>(catalog: &PreservedCatalog<S>)
    where
        S: CatalogState,
    {
        let guard = catalog.inner.read();
        let tkey = guard
            .previous_tkey
            .as_ref()
            .expect("should have at least a single transaction");
        let path = transaction_path(
            &catalog.object_store,
            catalog.server_id,
            &catalog.db_name,
            tkey,
        );
        let mut proto = load_transaction_proto(&catalog.object_store, &path)
            .await
            .unwrap();
        proto.version = 42;
        store_transaction_proto(&catalog.object_store, &path, &proto)
            .await
            .unwrap();
    }
/// Break preserved catalog by moving one of the transaction files into a weird unknown version.
Break preserved catalog by moving one of the transaction files into a weird unknown version.
Break preserved catalog by moving one of the transaction files into a weird unknown version .
pub async fn break_catalog_with_weird_version<S>(catalog: &PreservedCatalog<S>)
    where
        S: CatalogState,
    {
        let guard = catalog.inner.read();
        let tkey = guard
            .previous_tkey
            .as_ref()
            .expect("should have at least a single transaction");
        let path = transaction_path(
            &catalog.object_store,
            catalog.server_id,
            &catalog.db_name,
            tkey,
        );
        let mut proto = load_transaction_proto(&catalog.object_store, &path)
            .await
            .unwrap();
        proto.version = 42;
        store_transaction_proto(&catalog.object_store, &path, &proto)
            .await
            .unwrap();
    }
pub async fn break_catalog_with_weird_version < S > ( catalog : & PreservedCatalog < S > ) where S : CatalogState , { let guard = catalog . inner . read ( ) ; let tkey = guard . previous_tkey . as_ref ( ) . expect ( " " ) ; let path = transaction_path ( & catalog . object_store , catalog . server_id , & catalog . db_name , tkey , ) ; let mut proto = load_transaction_proto ( & catalog . object_store , & path ) . await . unwrap ( ) ; proto . version = 42 ; store_transaction_proto ( & catalog . object_store , & path , & proto ) . await . unwrap ( ) ; }
Break preserved catalog by moving one of the transaction files into a weird unknown version.
Break preserved catalog by moving one of the transaction files into a weird unknown version .
catalog
&PreservedCatalog<S>
catalog
&PreservedCatalog<S>