pub fn register_prover(&self, worker_: &str, block_size_: usize) -> QueryResult<i32> {
        use crate::schema::active_provers::dsl::*;
        let inserted: ActiveProver = insert_into(active_provers)
            .values(&vec![(
                worker.eq(worker_.to_string()),
                block_size.eq(block_size_ as i64),
            )])
            .get_result(self.0.conn())?;
        Ok(inserted.id)
    }
/// Adds a prover to the database.
Adds a prover to the database.
Adds a prover to the database .
pub fn register_prover(&self, worker_: &str, block_size_: usize) -> QueryResult<i32> {
        use crate::schema::active_provers::dsl::*;
        let inserted: ActiveProver = insert_into(active_provers)
            .values(&vec![(
                worker.eq(worker_.to_string()),
                block_size.eq(block_size_ as i64),
            )])
            .get_result(self.0.conn())?;
        Ok(inserted.id)
    }
pub fn register_prover ( & self , worker_ : & str , block_size_ : usize ) -> QueryResult < i32 > { use crate :: schema :: active_provers :: dsl :: * ; let inserted : ActiveProver = insert_into ( active_provers ) . values ( & vec ! [ ( worker eq ( worker_ to_string ( ) ) block_size eq ( block_size_ as i64 ) ) ] ) . get_result ( self . 0 . conn ( ) ) ? ; Ok ( inserted . id ) }
Adds a prover to the database.
Adds a prover to the database .
&self
worker_
&str
block_size_
usize