fuel_core_txpool::ports

Trait NotifyP2P

source
pub trait NotifyP2P {
    // Required methods
    fn broadcast_transaction(&self, transaction: Arc<Transaction>) -> Result<()>;
    fn notify_gossip_transaction_validity(
        &self,
        message_info: GossipsubMessageInfo,
        validity: GossipsubMessageAcceptance,
    ) -> Result<()>;
}

Required Methods§

source

fn broadcast_transaction(&self, transaction: Arc<Transaction>) -> Result<()>

Gossip broadcast a transaction inserted via API.

source

fn notify_gossip_transaction_validity( &self, message_info: GossipsubMessageInfo, validity: GossipsubMessageAcceptance, ) -> Result<()>

Report the validity of a transaction received from the network.

Implementors§