Function executor::db_bootstrapper::maybe_bootstrap
source · pub fn maybe_bootstrap<V: VMExecutor>(
db: &DbReaderWriter,
genesis_txn: &Transaction,
waypoint: Waypoint
) -> Result<bool>
Expand description
If current version + 1 != waypoint.version(), return Ok(false) indicating skipping the txn. otherwise apply the txn and commit it if the result matches the waypoint. Returns Ok(true) if committed otherwise Err.