Skip to main content

NodeApiStateImpl

Struct NodeApiStateImpl 

Source
pub struct NodeApiStateImpl<D> {
    data_source: D,
    env_vars: Arc<Vec<String>>,
    public_node_config: Option<Arc<PublicNodeConfig>>,
    ranges_concurrency: NonZeroUsize,
}
Expand description

Node API state implementation

This struct implements the v1 API traits (internal types) and the v2 tonic service traits (proto types).

Fields§

§data_source: D§env_vars: Arc<Vec<String>>§public_node_config: Option<Arc<PublicNodeConfig>>§ranges_concurrency: NonZeroUsize

Implementations§

Source§

impl<D> NodeApiStateImpl<D>

Source

pub fn new(data_source: D) -> Self

Source

pub fn with_ranges_concurrency(self, concurrency: NonZeroUsize) -> Self

Source

pub fn with_env_vars(self, env_vars: Vec<String>) -> Self

Source

pub fn with_public_node_config(self, config: Option<PublicNodeConfig>) -> Self

Source

fn cloned_public_node_config(&self) -> Result<PublicNodeConfig>

Trait Implementations§

Source§

impl<D> AvailabilityApi for NodeApiStateImpl<D>
where D: Deref + Clone + Send + Sync + 'static, D::Target: AvailabilityDataSource<SeqTypes> + NodeDataSource<SeqTypes> + RequestResponseDataSource<SeqTypes> + StateCertDataSource + StateCertFetchingDataSource<SeqTypes> + Send + Sync,

Source§

fn get_namespace_proof<'life0, 'async_trait>( &'life0 self, block_id: BlockId, namespace: u32, ) -> Pin<Box<dyn Future<Output = Result<NamespaceProofQueryData>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_namespace_proof_range<'life0, 'async_trait>( &'life0 self, from: u64, until: u64, namespace: u32, ) -> Pin<Box<dyn Future<Output = Result<Vec<NamespaceProofQueryData>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn stream_namespace_proofs<'life0, 'async_trait>( &'life0 self, from: usize, namespace: u32, ) -> Pin<Box<dyn Future<Output = Result<BoxStream<'static, NamespaceProofQueryData>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_incorrect_encoding_proof<'life0, 'async_trait>( &'life0 self, block_id: BlockId, namespace: u32, ) -> Pin<Box<dyn Future<Output = Result<AvidMIncorrectEncodingNsProof>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_state_cert<'life0, 'async_trait>( &'life0 self, epoch: u64, ) -> Pin<Box<dyn Future<Output = Result<StateCertQueryDataV1<SeqTypes>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_state_cert_v2<'life0, 'async_trait>( &'life0 self, epoch: u64, ) -> Pin<Box<dyn Future<Output = Result<StateCertQueryDataV2<SeqTypes>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

impl<D> AvailabilityService for NodeApiStateImpl<D>
where D: Deref + Clone + Send + Sync + 'static, D::Target: AvailabilityDataSource<SeqTypes> + VersionedDataSource + NodeDataSource<SeqTypes> + RequestResponseDataSource<SeqTypes> + StateCertDataSource + StateCertFetchingDataSource<SeqTypes> + Send + Sync, for<'a> <D::Target as VersionedDataSource>::ReadOnly<'a>: AvailabilityStorage<SeqTypes>,

Source§

type StreamLeavesStream = Pin<Box<dyn Stream<Item = Result<LeafResponse, Status>> + Send>>

Server streaming response type for the StreamLeaves method.
Source§

type StreamHeadersStream = Pin<Box<dyn Stream<Item = Result<HeaderResponse, Status>> + Send>>

Server streaming response type for the StreamHeaders method.
Source§

type StreamBlocksStream = Pin<Box<dyn Stream<Item = Result<BlockResponse, Status>> + Send>>

Server streaming response type for the StreamBlocks method.
Source§

type StreamPayloadsStream = Pin<Box<dyn Stream<Item = Result<PayloadResponse, Status>> + Send>>

Server streaming response type for the StreamPayloads method.
Source§

type StreamVidCommonStream = Pin<Box<dyn Stream<Item = Result<VidCommonResponse, Status>> + Send>>

Server streaming response type for the StreamVidCommon method.
Source§

type StreamTransactionsStream = Pin<Box<dyn Stream<Item = Result<TransactionResponse, Status>> + Send>>

Server streaming response type for the StreamTransactions method.
Source§

type StreamNamespaceProofsStream = Pin<Box<dyn Stream<Item = Result<NamespaceProofResponse, Status>> + Send>>

Server streaming response type for the StreamNamespaceProofs method.
Source§

fn get_limits<'life0, 'async_trait>( &'life0 self, _request: Request<GetLimitsRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<LimitsResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the most objects one range query may load, per object class
Source§

fn get_header<'life0, 'async_trait>( &'life0 self, request: Request<GetHeaderRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<HeaderResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get one block header. Exactly one of height, hash or payload_hash selects the block. None or several is a 400
Source§

fn get_header_range<'life0, 'async_trait>( &'life0 self, request: Request<GetHeaderRangeRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<HeaderRangeResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the headers of a height range, bounded by the large-object range limit
Source§

fn get_leaf<'life0, 'async_trait>( &'life0 self, request: Request<GetLeafRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<LeafResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get one leaf with the QC certifying it. Exactly one of height or hash selects it. None or both is a 400
Source§

fn get_leaf_range<'life0, 'async_trait>( &'life0 self, request: Request<GetLeafRangeRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<LeafRangeResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the leaves of a height range, bounded by the small-object range limit
Source§

fn get_leaf_ranges<'life0, 'async_trait>( &'life0 self, request: Request<GetLeafRangesRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<LeafRangeResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the leaves of several height ranges in one request, for peers catching up. The whole set is served or none of it, in the order the ranges were given
Source§

fn get_cert2<'life0, 'async_trait>( &'life0 self, request: Request<GetCert2Request>, ) -> Pin<Box<dyn Future<Output = Result<Response<Cert2Response>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the new protocol’s phase-2 certificate for a height. Not found before the new protocol took over, or while the node is still fetching it
Source§

fn get_block<'life0, 'async_trait>( &'life0 self, request: Request<GetBlockRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<BlockResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get one block, header and payload together. Exactly one of height, hash or payload_hash selects it. None or several is a 400
Source§

fn get_block_range<'life0, 'async_trait>( &'life0 self, request: Request<GetBlockRangeRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<BlockRangeResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the blocks of a height range, bounded by the large-object range limit
Source§

fn get_block_ranges<'life0, 'async_trait>( &'life0 self, request: Request<GetBlockRangesRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<BlockRangeResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the blocks of several height ranges in one request, for peers catching up. The whole set is served or none of it, in the order the ranges were given
Source§

fn get_payload<'life0, 'async_trait>( &'life0 self, request: Request<GetPayloadRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<PayloadResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get one payload. Exactly one of height, hash or block_hash selects it. None or several is a 400
Source§

fn get_payload_range<'life0, 'async_trait>( &'life0 self, request: Request<GetPayloadRangeRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<PayloadRangeResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the payloads of a height range, bounded by the large-object range limit
Source§

fn get_vid_common<'life0, 'async_trait>( &'life0 self, request: Request<GetVidCommonRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<VidCommonResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the VID common data of one block. Exactly one of height, hash or payload_hash selects the block. None or several is a 400
Source§

fn get_vid_common_range<'life0, 'async_trait>( &'life0 self, request: Request<GetVidCommonRangeRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<VidCommonRangeResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the VID common data of a height range, bounded by the small-object range limit
Source§

fn get_vid_common_ranges<'life0, 'async_trait>( &'life0 self, request: Request<GetVidCommonRangesRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<VidCommonRangeResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the VID common data of several height ranges in one request, for peers catching up. The whole set is served or none of it, in the order the ranges were given
Source§

fn get_transaction<'life0, 'async_trait>( &'life0 self, request: Request<GetTransactionRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<TransactionResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get one transaction. Either height and index together, or hash, selects it. Anything else is a 400
Source§

fn get_transaction_proof<'life0, 'async_trait>( &'life0 self, request: Request<GetTransactionProofRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<TransactionWithProofResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get one transaction with its inclusion proof. Either height and index together, or hash, selects it. Anything else is a 400
Source§

fn get_block_summary<'life0, 'async_trait>( &'life0 self, request: Request<GetBlockSummaryRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<BlockSummaryResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get a block’s header with its hash, size and transaction count, without the payload
Source§

fn get_block_summary_range<'life0, 'async_trait>( &'life0 self, request: Request<GetBlockSummaryRangeRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<BlockSummaryRangeResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the block summaries of a height range, bounded by the large-object range limit
Source§

fn get_namespace_proof<'life0, 'async_trait>( &'life0 self, request: Request<GetNamespaceProofRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<NamespaceProofResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get a namespace’s transactions and its proof against one block’s payload commitment. Exactly one of height, hash or payload_hash selects the block. None or several is a 400
Source§

fn get_namespace_proof_range<'life0, 'async_trait>( &'life0 self, request: Request<GetNamespaceProofRangeRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<NamespaceProofRangeResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get a namespace’s proofs over a height range, bounded by the namespace-proof range limit
Source§

fn get_incorrect_encoding_proof<'life0, 'async_trait>( &'life0 self, request: Request<GetIncorrectEncodingProofRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<IncorrectEncodingProofResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the proof that an AvidM block’s disperser encoded a namespace incorrectly
Source§

fn get_state_cert<'life0, 'async_trait>( &'life0 self, request: Request<GetStateCertRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<StateCertV1Response>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the light-client state certificate finalizing an epoch, in its first form
Source§

fn get_state_cert_v2<'life0, 'async_trait>( &'life0 self, request: Request<GetStateCertV2Request>, ) -> Pin<Box<dyn Future<Output = Result<Response<StateCertV2Response>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the light-client state certificate finalizing an epoch, with both contract signatures
Source§

fn stream_leaves<'life0, 'async_trait>( &'life0 self, request: Request<StreamLeavesRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<Self::StreamLeavesStream>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Subscribe to leaves from a height onward. Over REST this is server-sent events, one JSON data: frame per leaf. A stream follows the chain head and never ends on its own
Source§

fn stream_headers<'life0, 'async_trait>( &'life0 self, request: Request<StreamHeadersRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<Self::StreamHeadersStream>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Subscribe to headers from a height onward, as server-sent events
Source§

fn stream_blocks<'life0, 'async_trait>( &'life0 self, request: Request<StreamBlocksRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<Self::StreamBlocksStream>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Subscribe to blocks from a height onward, as server-sent events
Source§

fn stream_payloads<'life0, 'async_trait>( &'life0 self, request: Request<StreamPayloadsRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<Self::StreamPayloadsStream>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Subscribe to payloads from a height onward, as server-sent events
Source§

fn stream_vid_common<'life0, 'async_trait>( &'life0 self, request: Request<StreamVidCommonRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<Self::StreamVidCommonStream>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Subscribe to VID common data from a height onward, as server-sent events
Source§

fn stream_transactions<'life0, 'async_trait>( &'life0 self, request: Request<StreamTransactionsRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<Self::StreamTransactionsStream>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Subscribe to transactions from a height onward, optionally of one namespace, as server-sent events
Source§

fn stream_namespace_proofs<'life0, 'async_trait>( &'life0 self, request: Request<StreamNamespaceProofsRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<Self::StreamNamespaceProofsStream>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Subscribe to one namespace’s proofs from a height onward, as server-sent events
Source§

impl<D> BlockStateApi for NodeApiStateImpl<D>
where D: Deref + Clone + Send + Sync + 'static, D::Target: MerklizedStateDataSource<SeqTypes, BlockMerkleTree, { <espresso_types::BlockMerkleTree as jf_merkle_tree_compat::MerkleTreeScheme>::ARITY }> + MerklizedStateHeightPersistence + Send + Sync,

Source§

fn get_block_state_path<'life0, 'async_trait>( &'life0 self, snapshot: Snapshot, key: String, ) -> Pin<Box<dyn Future<Output = Result<BlockStatePath>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_block_state_height<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<u64>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

impl<D> CatchupApi for NodeApiStateImpl<D>

Source§

fn get_account<'life0, 'async_trait>( &'life0 self, height: u64, view: u64, address: String, ) -> Pin<Box<dyn Future<Output = Result<AccountQueryData>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_accounts<'life0, 'async_trait>( &'life0 self, height: u64, view: u64, accounts: Vec<FeeAccount>, ) -> Pin<Box<dyn Future<Output = Result<FeeMerkleTree>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_blocks_frontier<'life0, 'async_trait>( &'life0 self, height: u64, view: u64, ) -> Pin<Box<dyn Future<Output = Result<BlocksFrontier>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_chain_config<'life0, 'async_trait>( &'life0 self, commitment: String, ) -> Pin<Box<dyn Future<Output = Result<ChainConfig>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_leaf_chain<'life0, 'async_trait>( &'life0 self, height: u64, ) -> Pin<Box<dyn Future<Output = Result<Vec<Leaf2>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_cert2<'life0, 'async_trait>( &'life0 self, height: u64, ) -> Pin<Box<dyn Future<Output = Result<Certificate2<SeqTypes>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_reward_account_v1<'life0, 'async_trait>( &'life0 self, height: u64, view: u64, address: String, ) -> Pin<Box<dyn Future<Output = Result<RewardAccountQueryDataV1>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_reward_accounts_v1<'life0, 'async_trait>( &'life0 self, height: u64, view: u64, accounts: Vec<RewardAccountV1>, ) -> Pin<Box<dyn Future<Output = Result<RewardMerkleTreeV1>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_reward_account_v2<'life0, 'async_trait>( &'life0 self, height: u64, view: u64, address: String, ) -> Pin<Box<dyn Future<Output = Result<RewardAccountQueryDataV2>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_reward_merkle_tree_v2<'life0, 'async_trait>( &'life0 self, height: u64, view: u64, ) -> Pin<Box<dyn Future<Output = Result<Value>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_state_cert<'life0, 'async_trait>( &'life0 self, epoch: u64, ) -> Pin<Box<dyn Future<Output = Result<LightClientStateUpdateCertificateV2<SeqTypes>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

impl<D> CatchupService for NodeApiStateImpl<D>

Source§

fn get_catchup_fee_account<'life0, 'async_trait>( &'life0 self, request: Request<GetCatchupFeeAccountRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<FeeAccountProofResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Prove one fee account’s balance at a height and view
Source§

fn get_catchup_fee_accounts<'life0, 'async_trait>( &'life0 self, request: Request<GetCatchupFeeAccountsRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<FeeMerkleTreeResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the fee merkle tree holding the given accounts at a height and view
Source§

fn get_catchup_blocks_frontier<'life0, 'async_trait>( &'life0 self, request: Request<GetCatchupBlocksFrontierRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<MerklePathResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the block merkle tree frontier at a height and view
Source§

fn get_catchup_chain_config<'life0, 'async_trait>( &'life0 self, request: Request<GetCatchupChainConfigRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<CatchupChainConfigResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Resolve a chain configuration by its commitment
Source§

fn get_catchup_leaf_chain<'life0, 'async_trait>( &'life0 self, request: Request<GetCatchupLeafChainRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<CatchupLeafChainResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the leaves from the given height up to the next decide
Source§

fn get_catchup_cert2<'life0, 'async_trait>( &'life0 self, request: Request<GetCatchupCert2Request>, ) -> Pin<Box<dyn Future<Output = Result<Response<Cert2Response>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the phase-2 certificate finalizing a height
Source§

fn get_catchup_reward_account<'life0, 'async_trait>( &'life0 self, request: Request<GetCatchupRewardAccountRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<RewardAccountProofResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Prove one reward account’s balance in the v1 tree. An account with no entry gets an absence proof and a zero balance
Source§

fn get_catchup_reward_accounts<'life0, 'async_trait>( &'life0 self, request: Request<GetCatchupRewardAccountsRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<RewardMerkleTreeV1Response>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the v1 reward merkle tree holding the given accounts
Source§

fn get_catchup_reward_account_v2<'life0, 'async_trait>( &'life0 self, request: Request<GetCatchupRewardAccountV2Request>, ) -> Pin<Box<dyn Future<Output = Result<Response<RewardAccountProofResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Prove one reward account’s balance in the v2 tree. An account with no entry gets an absence proof and a zero balance
Source§

fn get_catchup_reward_merkle_tree_v2<'life0, 'async_trait>( &'life0 self, request: Request<GetCatchupRewardMerkleTreeV2Request>, ) -> Pin<Box<dyn Future<Output = Result<Response<RewardMerkleTreeV2Response>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the whole v2 reward merkle tree at a height and view, in the serialized form the merklized-state reward tree route serves
Source§

fn get_catchup_state_cert<'life0, 'async_trait>( &'life0 self, request: Request<GetCatchupStateCertRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<StateCertV2Response>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the certificate closing an epoch
Source§

impl<D: Clone> Clone for NodeApiStateImpl<D>

Source§

fn clone(&self) -> NodeApiStateImpl<D>

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl<D> ConfigApi for NodeApiStateImpl<D>
where D: Deref + Clone + Send + Sync + 'static, D::Target: HotShotConfigDataSource + Send + Sync,

Source§

fn hotshot_config<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<PublicNetworkConfig>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn env<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<Vec<String>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

The allowlisted environment variables, each as a single KEY=value string. Unset variables are present with an empty value.
Source§

fn runtime_config<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<RuntimeConfig>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

impl<D> ConfigService for NodeApiStateImpl<D>
where D: Deref + Clone + Send + Sync + 'static, D::Target: HotShotConfigDataSource + Send + Sync,

Source§

fn get_hotshot_config<'life0, 'async_trait>( &'life0 self, _request: Request<GetHotshotConfigRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<HotshotConfigResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the consensus parameters this node runs with
Source§

fn get_env<'life0, 'async_trait>( &'life0 self, _request: Request<GetEnvRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<EnvResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the allowlisted environment variables of this node, set or not
Source§

fn get_runtime_config<'life0, 'async_trait>( &'life0 self, _request: Request<GetRuntimeConfigRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<RuntimeConfigResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the node’s effective runtime configuration
Source§

impl<D> DatabaseApi for NodeApiStateImpl<D>
where D: Deref + Clone + Send + Sync + 'static, D::Target: DatabaseMetadataSource + Send + Sync,

Source§

fn get_table_sizes<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<Vec<TableSize>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_migration_status<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<Vec<MigrationStatus>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

impl<D> DatabaseService for NodeApiStateImpl<D>
where D: Deref + Clone + Send + Sync + 'static, D::Target: DatabaseMetadataSource + Send + Sync,

Source§

fn get_table_sizes<'life0, 'async_trait>( &'life0 self, _request: Request<GetTableSizesRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<TableSizesResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the row count and disk usage of every database table
Source§

fn get_migration_status<'life0, 'async_trait>( &'life0 self, _request: Request<GetMigrationStatusRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<MigrationStatusResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the progress of the deferred background migrations
Source§

impl<D> ExplorerApi for NodeApiStateImpl<D>
where D: Deref + Clone + Send + Sync + 'static, D::Target: ExplorerDataSource<SeqTypes> + Send + Sync,

Source§

fn get_block_detail<'life0, 'async_trait>( &'life0 self, ident: BlockIdent, ) -> Pin<Box<dyn Future<Output = Result<BlockDetailResponse<SeqTypes>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_block_summaries<'life0, 'async_trait>( &'life0 self, target: BlockIdent, limit: u64, ) -> Pin<Box<dyn Future<Output = Result<BlockSummaryResponse<SeqTypes>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_transaction_detail<'life0, 'async_trait>( &'life0 self, ident: TxIdent, ) -> Pin<Box<dyn Future<Output = Result<TransactionDetailResponse<SeqTypes>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_transaction_summaries<'life0, 'async_trait>( &'life0 self, target: TxIdent, limit: u64, filter: TxSummaryFilter, ) -> Pin<Box<dyn Future<Output = Result<TransactionSummariesResponse<SeqTypes>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_explorer_summary<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<ExplorerSummaryResponse<SeqTypes>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_search_result<'life0, 'async_trait>( &'life0 self, query: String, ) -> Pin<Box<dyn Future<Output = Result<SearchResultResponse<SeqTypes>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

impl<D> ExplorerService for NodeApiStateImpl<D>
where D: Deref + Clone + Send + Sync + 'static, D::Target: ExplorerDataSource<SeqTypes> + Send + Sync,

Source§

fn get_explorer_block_detail<'life0, 'async_trait>( &'life0 self, request: Request<GetExplorerBlockDetailRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<ExplorerBlockDetailResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get one block in full
Source§

fn get_explorer_block_summaries<'life0, 'async_trait>( &'life0 self, request: Request<GetExplorerBlockSummariesRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<ExplorerBlockSummariesResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get a window of blocks ending at the target block
Source§

fn get_explorer_transaction_detail<'life0, 'async_trait>( &'life0 self, request: Request<GetExplorerTransactionDetailRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<ExplorerTransactionDetailResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get one transaction in full, with its payloads
Source§

fn get_explorer_transaction_summaries<'life0, 'async_trait>( &'life0 self, request: Request<GetExplorerTransactionSummariesRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<ExplorerTransactionSummariesResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get a window of transactions ending at the target transaction
Source§

fn get_explorer_summary<'life0, 'async_trait>( &'life0 self, _request: Request<GetExplorerSummaryRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<ExplorerSummaryResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get an at-a-glance snapshot of the chain
Search the chain for blocks and transactions matching a hash
Source§

impl<D> FeeStateApi for NodeApiStateImpl<D>
where D: Deref + Clone + Send + Sync + 'static, D::Target: MerklizedStateDataSource<SeqTypes, FeeMerkleTree, { <espresso_types::FeeMerkleTree as jf_merkle_tree_compat::MerkleTreeScheme>::ARITY }> + MerklizedStateHeightPersistence + Send + Sync,

Source§

fn get_fee_state_path<'life0, 'async_trait>( &'life0 self, snapshot: Snapshot, key: String, ) -> Pin<Box<dyn Future<Output = Result<FeeStatePath>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_fee_state_height<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<u64>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_fee_balance_latest<'life0, 'async_trait>( &'life0 self, address: String, ) -> Pin<Box<dyn Future<Output = Result<Option<FeeAmount>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

impl<D> HotShotAvailabilityApi for NodeApiStateImpl<D>
where D: Deref + Clone + Send + Sync + 'static, D::Target: AvailabilityDataSource<SeqTypes> + VersionedDataSource + Send + Sync, for<'a> <D::Target as VersionedDataSource>::ReadOnly<'a>: AvailabilityStorage<SeqTypes>,

Source§

fn get_leaf<'life0, 'async_trait>( &'life0 self, id: LeafId, ) -> Pin<Box<dyn Future<Output = Result<LeafQueryData<SeqTypes>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_leaf_range<'life0, 'async_trait>( &'life0 self, from: usize, until: usize, ) -> Pin<Box<dyn Future<Output = Result<Vec<LeafQueryData<SeqTypes>>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_header<'life0, 'async_trait>( &'life0 self, id: BlockId, ) -> Pin<Box<dyn Future<Output = Result<HsHeader<SeqTypes>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_header_range<'life0, 'async_trait>( &'life0 self, from: usize, until: usize, ) -> Pin<Box<dyn Future<Output = Result<Vec<HsHeader<SeqTypes>>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_block<'life0, 'async_trait>( &'life0 self, id: BlockId, ) -> Pin<Box<dyn Future<Output = Result<BlockQueryData<SeqTypes>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_block_range<'life0, 'async_trait>( &'life0 self, from: usize, until: usize, ) -> Pin<Box<dyn Future<Output = Result<Vec<BlockQueryData<SeqTypes>>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_payload<'life0, 'async_trait>( &'life0 self, id: PayloadId, ) -> Pin<Box<dyn Future<Output = Result<PayloadQueryData<SeqTypes>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_payload_range<'life0, 'async_trait>( &'life0 self, from: usize, until: usize, ) -> Pin<Box<dyn Future<Output = Result<Vec<PayloadQueryData<SeqTypes>>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_vid_common<'life0, 'async_trait>( &'life0 self, id: BlockId, ) -> Pin<Box<dyn Future<Output = Result<VidCommonQueryData<SeqTypes>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_vid_common_range<'life0, 'async_trait>( &'life0 self, from: usize, until: usize, ) -> Pin<Box<dyn Future<Output = Result<Vec<VidCommonQueryData<SeqTypes>>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_leaf_ranges<'life0, 'async_trait>( &'life0 self, ranges: Vec<Range<u64>>, ) -> Pin<Box<dyn Future<Output = Result<Vec<LeafQueryData<SeqTypes>>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

The objects for a set of half-open height ranges, which must be ascending and disjoint. Read more
Source§

fn get_block_ranges<'life0, 'async_trait>( &'life0 self, ranges: Vec<Range<u64>>, ) -> Pin<Box<dyn Future<Output = Result<Vec<BlockQueryData<SeqTypes>>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_vid_common_ranges<'life0, 'async_trait>( &'life0 self, ranges: Vec<Range<u64>>, ) -> Pin<Box<dyn Future<Output = Result<Vec<VidCommonQueryData<SeqTypes>>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_transaction_by_position<'life0, 'async_trait>( &'life0 self, height: u64, index: u64, ) -> Pin<Box<dyn Future<Output = Result<TransactionQueryData<SeqTypes>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_transaction_by_hash<'life0, 'async_trait>( &'life0 self, hash: String, ) -> Pin<Box<dyn Future<Output = Result<TransactionQueryData<SeqTypes>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_transaction_proof_by_position<'life0, 'async_trait>( &'life0 self, height: u64, index: u64, ) -> Pin<Box<dyn Future<Output = Result<TransactionWithProofQueryData<SeqTypes>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_transaction_proof_by_hash<'life0, 'async_trait>( &'life0 self, hash: String, ) -> Pin<Box<dyn Future<Output = Result<TransactionWithProofQueryData<SeqTypes>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_block_summary<'life0, 'async_trait>( &'life0 self, height: usize, ) -> Pin<Box<dyn Future<Output = Result<BlockSummaryQueryData<SeqTypes>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_block_summary_range<'life0, 'async_trait>( &'life0 self, from: usize, until: usize, ) -> Pin<Box<dyn Future<Output = Result<Vec<BlockSummaryQueryData<SeqTypes>>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_limits<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<HsLimits>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_cert2<'life0, 'async_trait>( &'life0 self, height: u64, ) -> Pin<Box<dyn Future<Output = Result<Option<Certificate2<SeqTypes>>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn stream_leaves<'life0, 'async_trait>( &'life0 self, from: usize, ) -> Pin<Box<dyn Future<Output = Result<BoxStream<'static, LeafQueryData<SeqTypes>>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn stream_headers<'life0, 'async_trait>( &'life0 self, from: usize, ) -> Pin<Box<dyn Future<Output = Result<BoxStream<'static, HsHeader<SeqTypes>>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn stream_blocks<'life0, 'async_trait>( &'life0 self, from: usize, ) -> Pin<Box<dyn Future<Output = Result<BoxStream<'static, BlockQueryData<SeqTypes>>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn stream_payloads<'life0, 'async_trait>( &'life0 self, from: usize, ) -> Pin<Box<dyn Future<Output = Result<BoxStream<'static, PayloadQueryData<SeqTypes>>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn stream_vid_common<'life0, 'async_trait>( &'life0 self, from: usize, ) -> Pin<Box<dyn Future<Output = Result<BoxStream<'static, VidCommonQueryData<SeqTypes>>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn stream_transactions<'life0, 'async_trait>( &'life0 self, from: usize, namespace: Option<u32>, ) -> Pin<Box<dyn Future<Output = Result<BoxStream<'static, TransactionQueryData<SeqTypes>>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

impl<D> LightClientApi for NodeApiStateImpl<D>
where D: Deref + Clone + Send + Sync + 'static, D::Target: AvailabilityDataSource<SeqTypes> + MerklizedStateDataSource<SeqTypes, BlockMerkleTree, 3> + MerklizedStateHeightPersistence + NodeStateDataSource + StakeTableDataSource<SeqTypes> + VersionedDataSource + Sized + Clone + Send + Sync + 'static, for<'a> <D::Target as VersionedDataSource>::ReadOnly<'a>: NodeStorage<SeqTypes> + AvailabilityStorage<SeqTypes>,

Source§

fn get_leaf_proof<'life0, 'async_trait>( &'life0 self, query: LeafQuery, finalized: Option<u64>, ) -> Pin<Box<dyn Future<Output = Result<LeafProof>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_header_proof<'life0, 'async_trait>( &'life0 self, root: u64, requested: HeaderQuery, ) -> Pin<Box<dyn Future<Output = Result<HeaderProof>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_light_client_stake_table<'life0, 'async_trait>( &'life0 self, epoch: u64, ) -> Pin<Box<dyn Future<Output = Result<Vec<StakeTableEvent>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_payload_proof<'life0, 'async_trait>( &'life0 self, height: u64, ) -> Pin<Box<dyn Future<Output = Result<PayloadProof>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_payload_proof_range<'life0, 'async_trait>( &'life0 self, start: u64, end: u64, ) -> Pin<Box<dyn Future<Output = Result<Vec<PayloadProof>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_payload_proof_ranges<'life0, 'async_trait>( &'life0 self, ranges: Vec<Range<u64>>, ) -> Pin<Box<dyn Future<Output = Result<Vec<PayloadProof>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Payload proofs for a set of (from, until) half-open height ranges, which need not be contiguous. Read more
Source§

fn get_lc_namespace_proof<'life0, 'async_trait>( &'life0 self, height: u64, namespace: u64, ) -> Pin<Box<dyn Future<Output = Result<NamespaceProof>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_lc_namespace_proof_range<'life0, 'async_trait>( &'life0 self, start: u64, end: u64, namespace: u64, ) -> Pin<Box<dyn Future<Output = Result<Vec<NamespaceProof>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_lc_namespaces_proof_range<'life0, 'async_trait>( &'life0 self, start: u64, end: u64, namespaces: String, ) -> Pin<Box<dyn Future<Output = Result<Vec<HashMap<u64, NamespaceProof>>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

namespaces is the raw TaggedBase64-encoded path segment produced by the light-client client (tag NS, wrapping a JSON Vec<u64>); decoding it is left to the implementation so this crate does not need a tagged-base64 dependency.
Source§

impl<D> LightClientService for NodeApiStateImpl<D>
where D: Deref + Clone + Send + Sync + 'static, D::Target: AvailabilityDataSource<SeqTypes> + MerklizedStateDataSource<SeqTypes, BlockMerkleTree, 3> + MerklizedStateHeightPersistence + NodeStateDataSource + StakeTableDataSource<SeqTypes> + VersionedDataSource + Sized + Clone + Send + Sync + 'static, for<'a> <D::Target as VersionedDataSource>::ReadOnly<'a>: NodeStorage<SeqTypes> + AvailabilityStorage<SeqTypes>,

Source§

fn get_light_client_leaf_proof<'life0, 'async_trait>( &'life0 self, request: Request<GetLightClientLeafProofRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<LightClientLeafProofResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get a leaf with a proof that it is finalized
Source§

fn get_light_client_header_proof<'life0, 'async_trait>( &'life0 self, request: Request<GetLightClientHeaderProofRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<LightClientHeaderProofResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get a header with a proof of membership under a trusted block merkle tree root
Source§

fn get_light_client_stake_table<'life0, 'async_trait>( &'life0 self, request: Request<GetLightClientStakeTableRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<LightClientStakeTableResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the stake table events that turn the previous epoch’s stake table into this epoch’s
Source§

fn get_light_client_payload_proof<'life0, 'async_trait>( &'life0 self, request: Request<GetLightClientPayloadProofRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<LightClientPayloadProofResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get a block payload with the data to check it against its header
Source§

fn get_light_client_payload_proof_range<'life0, 'async_trait>( &'life0 self, request: Request<GetLightClientPayloadProofRangeRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<LightClientPayloadProofRangeResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get payload proofs for a range of blocks
Source§

fn get_light_client_payload_proof_ranges<'life0, 'async_trait>( &'life0 self, request: Request<GetLightClientPayloadProofRangesRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<LightClientPayloadProofRangeResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get payload proofs for several ranges of blocks in one request
Source§

fn get_light_client_namespace_proof<'life0, 'async_trait>( &'life0 self, request: Request<GetLightClientNamespaceProofRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<LightClientNamespaceProofResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get a proof of one namespace’s transactions in a block, checked against its header
Source§

fn get_light_client_namespace_proof_range<'life0, 'async_trait>( &'life0 self, request: Request<GetLightClientNamespaceProofRangeRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<LightClientNamespaceProofRangeResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get one namespace’s proofs for a range of blocks
Source§

fn get_light_client_namespaces_proof_range<'life0, 'async_trait>( &'life0 self, request: Request<GetLightClientNamespacesProofRangeRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<LightClientNamespacesProofRangeResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get several namespaces’ proofs for a range of blocks
Source§

impl<D> MerklizedStateService for NodeApiStateImpl<D>
where D: Deref + Clone + Send + Sync + 'static, D::Target: MerklizedStateDataSource<SeqTypes, BlockMerkleTree, { <espresso_types::BlockMerkleTree as jf_merkle_tree_compat::MerkleTreeScheme>::ARITY }> + MerklizedStateDataSource<SeqTypes, FeeMerkleTree, { <espresso_types::FeeMerkleTree as jf_merkle_tree_compat::MerkleTreeScheme>::ARITY }> + MerklizedStateHeightPersistence + Send + Sync,

Source§

fn get_block_state_path<'life0, 'async_trait>( &'life0 self, request: Request<GetBlockStatePathRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<MerklePathResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the Merkle path to one leaf of the block merkle tree, which commits to past block headers. Exactly one of height or commit selects the snapshot. None or both is a 400
Source§

fn get_fee_state_path<'life0, 'async_trait>( &'life0 self, request: Request<GetFeeStatePathRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<MerklePathResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the Merkle path to one account of the fee merkle tree, which holds the fee balances. Exactly one of height or commit selects the snapshot. None or both is a 400
Source§

fn get_latest_fee_balance<'life0, 'async_trait>( &'life0 self, request: Request<GetLatestFeeBalanceRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<FeeBalanceResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get an account’s fee balance in the newest persisted state
Source§

fn get_state_height<'life0, 'async_trait>( &'life0 self, _request: Request<GetStateHeightRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<StateHeightResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the height of the newest persisted merklized state, which every tree shares
Source§

impl<D> NodeApi for NodeApiStateImpl<D>
where D: Deref + Clone + Send + Sync + 'static, D::Target: NodeDataSource<SeqTypes> + StakeTableDataSource<SeqTypes> + PruningDataSource + Send + Sync,

Source§

fn block_height<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<u64>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn count_transactions<'life0, 'async_trait>( &'life0 self, from: Option<u64>, to: Option<u64>, namespace: Option<u64>, ) -> Pin<Box<dyn Future<Output = Result<u64>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn payload_size<'life0, 'async_trait>( &'life0 self, from: Option<u64>, to: Option<u64>, namespace: Option<u64>, ) -> Pin<Box<dyn Future<Output = Result<u64>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_vid_share<'life0, 'async_trait>( &'life0 self, id: VidShareId, ) -> Pin<Box<dyn Future<Output = Result<VidShare>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn sync_status<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<SyncStatusQueryData>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_header_window<'life0, 'async_trait>( &'life0 self, start: HeaderWindowStart, end: u64, ) -> Pin<Box<dyn Future<Output = Result<TimeWindowQueryData<Header<SeqTypes>>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn limits<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<Limits>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn stake_table<'life0, 'async_trait>( &'life0 self, epoch: u64, ) -> Pin<Box<dyn Future<Output = Result<Vec<PeerConfig<SeqTypes>>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn stake_table_current<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<StakeTableWithEpochNumber<SeqTypes>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn da_stake_table<'life0, 'async_trait>( &'life0 self, epoch: u64, ) -> Pin<Box<dyn Future<Output = Result<Vec<PeerConfig<SeqTypes>>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn da_stake_table_current<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<StakeTableWithEpochNumber<SeqTypes>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_validators<'life0, 'async_trait>( &'life0 self, epoch: u64, ) -> Pin<Box<dyn Future<Output = Result<IndexMap<Address, AuthenticatedValidator<PubKey>>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_all_validators<'life0, 'async_trait>( &'life0 self, epoch: u64, offset: u64, limit: u64, ) -> Pin<Box<dyn Future<Output = Result<Vec<RegisteredValidator<PubKey>>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn current_proposal_participation<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<HashMap<PubKey, f64>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn proposal_participation<'life0, 'async_trait>( &'life0 self, epoch: u64, ) -> Pin<Box<dyn Future<Output = Result<HashMap<PubKey, f64>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn current_vote_participation<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<HashMap<PubKey, f64>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn vote_participation<'life0, 'async_trait>( &'life0 self, epoch: u64, ) -> Pin<Box<dyn Future<Output = Result<HashMap<PubKey, f64>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_block_reward<'life0, 'async_trait>( &'life0 self, epoch: Option<u64>, ) -> Pin<Box<dyn Future<Output = Result<Option<RewardAmount>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_oldest_block<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<Option<BlockQueryData<SeqTypes>>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_oldest_leaf<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<Option<LeafQueryData<SeqTypes>>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

impl<D> NodeService for NodeApiStateImpl<D>
where D: Deref + Clone + Send + Sync + 'static, D::Target: NodeDataSource<SeqTypes> + StakeTableDataSource<SeqTypes> + PruningDataSource + Send + Sync,

Source§

fn get_transaction_count<'life0, 'async_trait>( &'life0 self, request: Request<GetTransactionCountRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<TransactionCountResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Count the transactions in a block range, optionally in one namespace
Source§

fn get_payload_size<'life0, 'async_trait>( &'life0 self, request: Request<GetPayloadSizeRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<PayloadSizeResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the cumulative payload size of a block range, optionally of one namespace
Source§

fn get_sync_status<'life0, 'async_trait>( &'life0 self, _request: Request<GetSyncStatusRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<SyncStatusResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get which blocks, leaves and VID common data this node stores, still fetches, or has pruned
Source§

fn get_block_reward<'life0, 'async_trait>( &'life0 self, request: Request<GetBlockRewardRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<BlockRewardResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the block reward for an epoch
Source§

fn get_vid_share<'life0, 'async_trait>( &'life0 self, request: Request<GetVidShareRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<VidShareResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get this node’s VID share for a block, selected by exactly one of height, hash or payload_hash
Source§

fn get_header_window<'life0, 'async_trait>( &'life0 self, request: Request<GetHeaderWindowRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<HeaderWindowResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the headers whose timestamps fall in a window, plus the headers either side of it. The window starts at exactly one of start_time, start_height or start_hash
Source§

fn get_node_block_height<'life0, 'async_trait>( &'life0 self, _request: Request<GetNodeBlockHeightRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<NodeBlockHeightResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the height of the chain as this node sees it. /v2/status/block-height answers the same question; both exist because v1 has both, and a client watching one module should not have to call into another.
Source§

fn get_node_limits<'life0, 'async_trait>( &'life0 self, _request: Request<GetNodeLimitsRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<NodeLimitsResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get this node’s request limits
Source§

fn get_stake_table<'life0, 'async_trait>( &'life0 self, request: Request<GetStakeTableRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<StakeTableResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the consensus stake table for an epoch
Source§

fn get_validators<'life0, 'async_trait>( &'life0 self, request: Request<GetValidatorsRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<ValidatorsResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the validators eligible for consensus in an epoch
Source§

fn get_all_validators<'life0, 'async_trait>( &'life0 self, request: Request<GetAllValidatorsRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<ValidatorsResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get a page of every registered validator in an epoch, eligible or not
Source§

fn get_proposal_participation<'life0, 'async_trait>( &'life0 self, request: Request<GetProposalParticipationRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<ParticipationResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get, per validator, the proposals it made as a fraction of the views it led in an epoch
Source§

fn get_vote_participation<'life0, 'async_trait>( &'life0 self, request: Request<GetVoteParticipationRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<ParticipationResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get, per validator, the votes it cast as a fraction of an epoch’s views
Source§

impl<D> RewardApi for NodeApiStateImpl<D>
where D: RewardMerkleTreeDataSource + Deref, D::Target: MerklizedStateHeightPersistence + MerklizedStateDataSource<SeqTypes, RewardMerkleTreeV1, { <espresso_types::v0_3::RewardMerkleTreeV1 as jf_merkle_tree_compat::MerkleTreeScheme>::ARITY }> + MerklizedStateDataSource<SeqTypes, RewardMerkleTreeV2, { <espresso_types::v0_4::RewardMerkleTreeV2 as jf_merkle_tree_compat::MerkleTreeScheme>::ARITY }> + Send + Sync,

Source§

fn get_reward_state_height<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<u64>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the height of the last persisted reward-state-v1 merklized state snapshot
Source§

fn get_reward_state_v2_height<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<u64>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the height of the last persisted reward-state-v2 merklized state snapshot
Source§

fn get_reward_account_proof_v1<'life0, 'async_trait>( &'life0 self, height: u64, address: String, ) -> Pin<Box<dyn Future<Output = Result<RewardAccountQueryDataV1>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get Merkle proof for a reward account against the V1 (RewardMerkleTreeV1) tree Read more
Source§

fn get_reward_claim_input<'life0, 'async_trait>( &'life0 self, block_height: u64, address: String, ) -> Pin<Box<dyn Future<Output = Result<InternalRewardClaimInput>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get reward claim input for L1 contract submission Read more
Source§

fn get_reward_balance<'life0, 'async_trait>( &'life0 self, height: u64, address: String, ) -> Pin<Box<dyn Future<Output = Result<InternalRewardAmount>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get reward balance at a specific height Read more
Source§

fn get_latest_reward_balance<'life0, 'async_trait>( &'life0 self, address: String, ) -> Pin<Box<dyn Future<Output = Result<InternalRewardAmount>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get latest reward balance at the most recent finalized height Read more
Source§

fn get_reward_account_proof<'life0, 'async_trait>( &'life0 self, height: u64, address: String, ) -> Pin<Box<dyn Future<Output = Result<InternalRewardAccountQueryData>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get Merkle proof for a reward account at a specific height Read more
Source§

fn get_latest_reward_account_proof<'life0, 'async_trait>( &'life0 self, address: String, ) -> Pin<Box<dyn Future<Output = Result<InternalRewardAccountQueryData>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get Merkle proof for a reward account at the latest finalized height Read more
Source§

fn get_reward_amounts<'life0, 'async_trait>( &'life0 self, height: u64, offset: u64, limit: u64, ) -> Pin<Box<dyn Future<Output = Result<Vec<(Address, InternalRewardAmount)>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get paginated list of reward amounts at a specific height Read more
Source§

fn get_reward_merkle_tree_v2<'life0, 'async_trait>( &'life0 self, height: u64, ) -> Pin<Box<dyn Future<Output = Result<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get raw RewardMerkleTreeV2 snapshot at a given height Read more
Source§

fn get_reward_state_path_v1<'life0, 'async_trait>( &'life0 self, snapshot: Snapshot, key: String, ) -> Pin<Box<dyn Future<Output = Result<RewardStatePathV1>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the Merkle path for a key in the reward-state (RewardMerkleTreeV1) tree Read more
Source§

fn get_reward_state_path_v2<'life0, 'async_trait>( &'life0 self, snapshot: Snapshot, key: String, ) -> Pin<Box<dyn Future<Output = Result<RewardStatePathV2>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the Merkle path for a key in the reward-state-v2 (RewardMerkleTreeV2) tree Read more
Source§

impl<D> RewardStateService for NodeApiStateImpl<D>
where D: RewardMerkleTreeDataSource + Deref + Clone + Send + Sync + 'static, D::Target: MerklizedStateHeightPersistence + MerklizedStateDataSource<SeqTypes, RewardMerkleTreeV1, { <RewardMerkleTreeV1 as MerkleTreeScheme>::ARITY }> + MerklizedStateDataSource<SeqTypes, RewardMerkleTreeV2, { <RewardMerkleTreeV2 as MerkleTreeScheme>::ARITY }> + Send + Sync,

Source§

fn get_reward_balance<'life0, 'async_trait>( &'life0 self, request: Request<GetRewardBalanceRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<RewardBalanceResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get an account’s lifetime rewards at a height finalized by the light client contract, or at the newest one
Source§

fn get_reward_account_proof<'life0, 'async_trait>( &'life0 self, request: Request<GetRewardAccountProofRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<RewardAccountProofResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get an account’s lifetime rewards with the Merkle proof backing them, at a height finalized by the light client contract, or at the newest one
Source§

fn get_reward_claim_input<'life0, 'async_trait>( &'life0 self, request: Request<GetRewardClaimInputRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<RewardClaimInputResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get everything needed to call claimRewards on the L1 contract
Source§

fn get_reward_amounts<'life0, 'async_trait>( &'life0 self, request: Request<GetRewardAmountsRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<RewardAmountsResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get a page of reward amounts at a block height
Source§

fn get_reward_merkle_tree_v2<'life0, 'async_trait>( &'life0 self, request: Request<GetRewardMerkleTreeV2Request>, ) -> Pin<Box<dyn Future<Output = Result<Response<RewardMerkleTreeV2Response>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get this node’s serialized RewardMerkleTreeV2 snapshot at a block height
Source§

impl<D> StateSignatureApi for NodeApiStateImpl<D>
where D: Deref + Clone + Send + Sync + 'static, D::Target: StateSignatureDataSourceErased + Send + Sync,

Source§

fn get_state_signature<'life0, 'async_trait>( &'life0 self, height: u64, ) -> Pin<Box<dyn Future<Output = Result<LCV3StateSignatureRequestBody>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

impl<D> StateSignatureService for NodeApiStateImpl<D>
where D: Deref + Clone + Send + Sync + 'static, D::Target: StateSignatureDataSourceErased + Send + Sync,

Source§

fn get_state_signature<'life0, 'async_trait>( &'life0 self, request: Request<GetStateSignatureRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<StateSignatureResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get this node’s light client state signature for a block
Source§

impl<D> StatusApi for NodeApiStateImpl<D>
where D: Deref + Clone + Send + Sync + 'static, D::Target: StatusDataSource + NodeKeysDataSource + Send + Sync,

Source§

fn block_height<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<u64>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn success_rate<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<f64>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn time_since_last_decide<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<u64>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn metrics<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<String>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn keys<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<NodePublicKeys>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

impl<D> StatusService for NodeApiStateImpl<D>
where D: Deref + Clone + Send + Sync + 'static, D::Target: StatusDataSource + NodeKeysDataSource + Send + Sync,

Source§

fn get_block_height<'life0, 'async_trait>( &'life0 self, _request: Request<GetBlockHeightRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<BlockHeightResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the height of the latest decided block
Source§

fn get_success_rate<'life0, 'async_trait>( &'life0 self, _request: Request<GetSuccessRateRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<SuccessRateResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the fraction of views in which this node decided a block
Source§

fn get_time_since_last_decide<'life0, 'async_trait>( &'life0 self, _request: Request<GetTimeSinceLastDecideRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<TimeSinceLastDecideResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the seconds elapsed since this node last decided a block
Source§

fn get_node_keys<'life0, 'async_trait>( &'life0 self, _request: Request<GetNodeKeysRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<NodeKeysResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the node’s public keys
Source§

impl<D> SubmitApi for NodeApiStateImpl<D>
where D: Deref + Clone + Send + Sync + 'static, D::Target: SubmitDataSourceErased + Send + Sync,

Source§

fn submit<'life0, 'async_trait>( &'life0 self, tx: Transaction, ) -> Pin<Box<dyn Future<Output = Result<Commitment<Transaction>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

impl<D> SubmitService for NodeApiStateImpl<D>
where D: Deref + Clone + Send + Sync + 'static, D::Target: SubmitDataSourceErased + Send + Sync,

Source§

fn submit_transaction<'life0, 'async_trait>( &'life0 self, request: Request<SubmitTransactionRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<SubmitTransactionResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Submit a transaction for sequencing
Source§

impl<D> TokenApi for NodeApiStateImpl<D>

Source§

fn total_minted_supply<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<String>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn circulating_supply<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<String>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn circulating_supply_ethereum<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<String>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn total_issued_supply<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<String>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn total_reward_distributed<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<String>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

impl<D> TokenService for NodeApiStateImpl<D>

Source§

fn get_total_minted_supply<'life0, 'async_trait>( &'life0 self, _request: Request<GetTotalMintedSupplyRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<TotalMintedSupplyResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the total supply of the ESP token minted on Ethereum; excludes unclaimed rewards
Source§

fn get_circulating_supply<'life0, 'async_trait>( &'life0 self, _request: Request<GetCirculatingSupplyRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<CirculatingSupplyResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the circulating supply, following the mainnet unlock schedule
Source§

fn get_circulating_supply_ethereum<'life0, 'async_trait>( &'life0 self, _request: Request<GetCirculatingSupplyEthereumRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<CirculatingSupplyEthereumResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the circulating supply of ESP tokens on Ethereum L1
Source§

fn get_total_issued_supply<'life0, 'async_trait>( &'life0 self, _request: Request<GetTotalIssuedSupplyRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<TotalIssuedSupplyResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the total issued supply, including rewards not yet claimed on Ethereum
Source§

fn get_total_reward_distributed<'life0, 'async_trait>( &'life0 self, _request: Request<GetTotalRewardDistributedRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<TotalRewardDistributedResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the total rewards distributed by consensus, including rewards not yet claimed on Ethereum

Auto Trait Implementations§

§

impl<D> Freeze for NodeApiStateImpl<D>
where D: Freeze,

§

impl<D> RefUnwindSafe for NodeApiStateImpl<D>
where D: RefUnwindSafe,

§

impl<D> Send for NodeApiStateImpl<D>
where D: Send,

§

impl<D> Sync for NodeApiStateImpl<D>
where D: Sync,

§

impl<D> Unpin for NodeApiStateImpl<D>
where D: Unpin,

§

impl<D> UnsafeUnpin for NodeApiStateImpl<D>
where D: UnsafeUnpin,

§

impl<D> UnwindSafe for NodeApiStateImpl<D>
where D: UnwindSafe,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
§

impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
where ST: ?Sized, DT: ?Sized,

§

impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
§

impl<T> Conv for T

§

fn conv<T>(self) -> T
where Self: Into<T>,

Converts self into T using Into<T>. Read more
§

impl<T> Downcast for T
where T: Any,

§

fn into_any(self: Box<T>) -> Box<dyn Any>

Convert Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.
§

fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>

Convert Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be further downcast into Rc<ConcreteType> where ConcreteType implements Trait.
§

fn as_any(&self) -> &(dyn Any + 'static)

Convert &Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot generate &Any’s vtable from &Trait’s.
§

fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)

Convert &mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot generate &mut Any’s vtable from &mut Trait’s.
§

impl<T> DowncastSync for T
where T: Any + Send + Sync,

§

fn into_any_arc(self: Arc<T>) -> Arc<dyn Any + Send + Sync> ⓘ

Convert Arc<Trait> (where Trait: Downcast) to Arc<Any>. Arc<Any> can then be further downcast into Arc<ConcreteType> where ConcreteType implements Trait.
Source§

impl<T> DynClone for T
where T: Clone,

§

impl<T> FmtForward for T

§

fn fmt_binary(self) -> FmtBinary<Self>
where Self: Binary,

Causes self to use its Binary implementation when Debug-formatted.
§

fn fmt_display(self) -> FmtDisplay<Self>
where Self: Display,

Causes self to use its Display implementation when Debug-formatted.
§

fn fmt_lower_exp(self) -> FmtLowerExp<Self>
where Self: LowerExp,

Causes self to use its LowerExp implementation when Debug-formatted.
§

fn fmt_lower_hex(self) -> FmtLowerHex<Self>
where Self: LowerHex,

Causes self to use its LowerHex implementation when Debug-formatted.
§

fn fmt_octal(self) -> FmtOctal<Self>
where Self: Octal,

Causes self to use its Octal implementation when Debug-formatted.
§

fn fmt_pointer(self) -> FmtPointer<Self>
where Self: Pointer,

Causes self to use its Pointer implementation when Debug-formatted.
§

fn fmt_upper_exp(self) -> FmtUpperExp<Self>
where Self: UpperExp,

Causes self to use its UpperExp implementation when Debug-formatted.
§

fn fmt_upper_hex(self) -> FmtUpperHex<Self>
where Self: UpperHex,

Causes self to use its UpperHex implementation when Debug-formatted.
§

fn fmt_list(self) -> FmtList<Self>
where &'a Self: for<'a> IntoIterator,

Formats each item in a sequence. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<T> FromRef<T> for T
where T: Clone,

§

fn from_ref(input: &T) -> T

Converts to this type from a reference to the input type.
§

impl<T> FutureExt for T

§

fn with_context(self, otel_cx: Context) -> WithContext<Self> ⓘ

Attaches the provided Context to this type, returning a WithContext wrapper. Read more
§

fn with_current_context(self) -> WithContext<Self> ⓘ

Attaches the current Context to this type, returning a WithContext wrapper. Read more
§

impl<T> Instrument for T

§

fn instrument(self, span: Span) -> Instrumented<Self> ⓘ

Instruments this type with the provided [Span], returning an Instrumented wrapper. Read more
§

fn in_current_span(self) -> Instrumented<Self> ⓘ

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

§

impl<T> IntoApi for T

§

fn into_api<A>(self) -> UseApi<T, A>
where T: Sized,

into [UseApi]
Source§

impl<T> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
§

impl<T> IntoRequest<T> for T

§

fn into_request(self) -> Request<T>

Wrap the input message T in a tonic::Request
§

impl<T> JsonSchemaMaybe for T

§

impl<L> LayerExt<L> for L

§

fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>
where L: Layer<S>,

Applies the layer to a service and wraps it in [Layered].
§

impl<T> Pipe for T
where T: ?Sized,

§

fn pipe<R>(self, func: impl FnOnce(Self) -> R) -> R
where Self: Sized,

Pipes by value. This is generally the method you want to use. Read more
§

fn pipe_ref<'a, R>(&'a self, func: impl FnOnce(&'a Self) -> R) -> R
where R: 'a,

Borrows self and passes that borrow into the pipe function. Read more
§

fn pipe_ref_mut<'a, R>(&'a mut self, func: impl FnOnce(&'a mut Self) -> R) -> R
where R: 'a,

Mutably borrows self and passes that borrow into the pipe function. Read more
§

fn pipe_borrow<'a, B, R>(&'a self, func: impl FnOnce(&'a B) -> R) -> R
where Self: Borrow<B>, B: 'a + ?Sized, R: 'a,

Borrows self, then passes self.borrow() into the pipe function. Read more
§

fn pipe_borrow_mut<'a, B, R>( &'a mut self, func: impl FnOnce(&'a mut B) -> R, ) -> R
where Self: BorrowMut<B>, B: 'a + ?Sized, R: 'a,

Mutably borrows self, then passes self.borrow_mut() into the pipe function. Read more
§

fn pipe_as_ref<'a, U, R>(&'a self, func: impl FnOnce(&'a U) -> R) -> R
where Self: AsRef<U>, U: 'a + ?Sized, R: 'a,

Borrows self, then passes self.as_ref() into the pipe function.
§

fn pipe_as_mut<'a, U, R>(&'a mut self, func: impl FnOnce(&'a mut U) -> R) -> R
where Self: AsMut<U>, U: 'a + ?Sized, R: 'a,

Mutably borrows self, then passes self.as_mut() into the pipe function.
§

fn pipe_deref<'a, T, R>(&'a self, func: impl FnOnce(&'a T) -> R) -> R
where Self: Deref<Target = T>, T: 'a + ?Sized, R: 'a,

Borrows self, then passes self.deref() into the pipe function.
§

fn pipe_deref_mut<'a, T, R>( &'a mut self, func: impl FnOnce(&'a mut T) -> R, ) -> R
where Self: DerefMut<Target = T> + Deref, T: 'a + ?Sized, R: 'a,

Mutably borrows self, then passes self.deref_mut() into the pipe function.
§

impl<T> Pointable for T

§

const ALIGN: usize

The alignment of pointer.
§

type Init = T

The type for initializers.
§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
§

impl<T> PolicyExt for T
where T: ?Sized,

§

fn and<P, B, E>(self, other: P) -> And<T, P>
where T: Sized + Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns [Action::Follow] only if self and other return Action::Follow. Read more
§

fn or<P, B, E>(self, other: P) -> Or<T, P>
where T: Sized + Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns [Action::Follow] if either self or other returns Action::Follow. Read more
§

impl<T> Read<Exclusive, BecauseExclusive> for T
where T: ?Sized,

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
§

impl<T> Tap for T

§

fn tap(self, func: impl FnOnce(&Self)) -> Self

Immutable access to a value. Read more
§

fn tap_mut(self, func: impl FnOnce(&mut Self)) -> Self

Mutable access to a value. Read more
§

fn tap_borrow<B>(self, func: impl FnOnce(&B)) -> Self
where Self: Borrow<B>, B: ?Sized,

Immutable access to the Borrow<B> of a value. Read more
§

fn tap_borrow_mut<B>(self, func: impl FnOnce(&mut B)) -> Self
where Self: BorrowMut<B>, B: ?Sized,

Mutable access to the BorrowMut<B> of a value. Read more
§

fn tap_ref<R>(self, func: impl FnOnce(&R)) -> Self
where Self: AsRef<R>, R: ?Sized,

Immutable access to the AsRef<R> view of a value. Read more
§

fn tap_ref_mut<R>(self, func: impl FnOnce(&mut R)) -> Self
where Self: AsMut<R>, R: ?Sized,

Mutable access to the AsMut<R> view of a value. Read more
§

fn tap_deref<T>(self, func: impl FnOnce(&T)) -> Self
where Self: Deref<Target = T>, T: ?Sized,

Immutable access to the Deref::Target of a value. Read more
§

fn tap_deref_mut<T>(self, func: impl FnOnce(&mut T)) -> Self
where Self: DerefMut<Target = T> + Deref, T: ?Sized,

Mutable access to the Deref::Target of a value. Read more
§

fn tap_dbg(self, func: impl FnOnce(&Self)) -> Self

Calls .tap() only in debug builds, and is erased in release builds.
§

fn tap_mut_dbg(self, func: impl FnOnce(&mut Self)) -> Self

Calls .tap_mut() only in debug builds, and is erased in release builds.
§

fn tap_borrow_dbg<B>(self, func: impl FnOnce(&B)) -> Self
where Self: Borrow<B>, B: ?Sized,

Calls .tap_borrow() only in debug builds, and is erased in release builds.
§

fn tap_borrow_mut_dbg<B>(self, func: impl FnOnce(&mut B)) -> Self
where Self: BorrowMut<B>, B: ?Sized,

Calls .tap_borrow_mut() only in debug builds, and is erased in release builds.
§

fn tap_ref_dbg<R>(self, func: impl FnOnce(&R)) -> Self
where Self: AsRef<R>, R: ?Sized,

Calls .tap_ref() only in debug builds, and is erased in release builds.
§

fn tap_ref_mut_dbg<R>(self, func: impl FnOnce(&mut R)) -> Self
where Self: AsMut<R>, R: ?Sized,

Calls .tap_ref_mut() only in debug builds, and is erased in release builds.
§

fn tap_deref_dbg<T>(self, func: impl FnOnce(&T)) -> Self
where Self: Deref<Target = T>, T: ?Sized,

Calls .tap_deref() only in debug builds, and is erased in release builds.
§

fn tap_deref_mut_dbg<T>(self, func: impl FnOnce(&mut T)) -> Self
where Self: DerefMut<Target = T> + Deref, T: ?Sized,

Calls .tap_deref_mut() only in debug builds, and is erased in release builds.
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
§

impl<T> TryConv for T

§

fn try_conv<T>(self) -> Result<T, Self::Error>
where Self: TryInto<T>,

Attempts to convert self into T using TryInto<T>. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

§

fn vzip(self) -> V

§

impl<T> WithSubscriber for T

§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> ⓘ
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a [WithDispatch] wrapper. Read more
§

fn with_current_subscriber(self) -> WithDispatch<Self> ⓘ

Attaches the current default Subscriber to this type, returning a [WithDispatch] wrapper. Read more