pub async fn replica_state(&mut self) -> DalResult<validator::ReplicaState> {
        sqlx::query!(
            r#"
            SELECT
                state AS "state!"
            FROM
                consensus_replica_state
            WHERE
                fake_key
            "#
        )
        .try_map(|row| {
            zksync_protobuf::serde::Deserialize {
                deny_unknown_fields: true,
            }
            .proto_fmt(row.state)
            .decode_column("state")
        })
        .instrument("replica_state")
        .fetch_one(self.storage)
        .await
    }
Fetches the current BFT replica state.
core/lib/dal/src/consensus_dal/mod.rs