mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-26 09:57:56 +00:00
fe8d2bc7f4
* beefy: add dummy latest_finalized() RPC * beefy: rpc latest_best_beefy() using shared mem * beefy: rpc populate latest_best_beefy() * beefy: rpc handle readiness * beefy: best block over channel - wip Not working because channel can't be simply opened and receiver passed to `rpc_extensions_builder` because `rpc_extensions_builder` has to be `Fn` and not `FnOnce`... and and Receiver side of mpsc can't be cloned yay!.. * beefy: make notification channels payload-agnostic * beefy: use notification mechanism instead of custom channel * beefy: add tracing key to notif channels * sc-utils: add notification channel - wip * beefy: use sc-utils generic notification channel * grandpa: use sc-utils generic notification channel * fix grumbles * beefy-rpc: get best block header instead of number * beefy-rpc: rename to `beefy_getFinalizedHead` * fix nitpicks * client-rpc-notifications: move generic Error from struct to fn * beefy: use header from notification instead of getting from database * beefy-rpc: get best block hash instead of header * beefy-rpc: fix and improve latestHead test * beefy-rpc: bubble up errors from rpc-handler instantiation * update lockfile * Apply suggestions from code review Co-authored-by: André Silva <123550+andresilva@users.noreply.github.com> * fix errors and warnings * fix nit Co-authored-by: André Silva <123550+andresilva@users.noreply.github.com>
43 lines
1.7 KiB
Rust
43 lines
1.7 KiB
Rust
// This file is part of Substrate.
|
|
|
|
// Copyright (C) 2020-2022 Parity Technologies (UK) Ltd.
|
|
// SPDX-License-Identifier: GPL-3.0-or-later WITH Classpath-exception-2.0
|
|
|
|
// This program is free software: you can redistribute it and/or modify
|
|
// it under the terms of the GNU General Public License as published by
|
|
// the Free Software Foundation, either version 3 of the License, or
|
|
// (at your option) any later version.
|
|
|
|
// This program is distributed in the hope that it will be useful,
|
|
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
// GNU General Public License for more details.
|
|
|
|
// You should have received a copy of the GNU General Public License
|
|
// along with this program. If not, see <https://www.gnu.org/licenses/>.
|
|
|
|
//! Utilities Primitives for Substrate
|
|
//!
|
|
//! # Features
|
|
//!
|
|
//! ## metered
|
|
//!
|
|
//! This feature changes the behaviour of the function `mpsc::tracing_unbounded`.
|
|
//! With the disabled feature this function is an alias to `futures::channel::mpsc::unbounded`.
|
|
//! However, when the feature is enabled it creates wrapper types to `UnboundedSender<T>`
|
|
//! and `UnboundedReceiver<T>` to register every `send`/`received`/`dropped` action happened on
|
|
//! the channel.
|
|
//!
|
|
//! Also this feature creates and registers a prometheus vector with name `unbounded_channel_len`
|
|
//! and labels:
|
|
//!
|
|
//! | Label | Description |
|
|
//! | ------------ | --------------------------------------------- |
|
|
//! | entity | Name of channel passed to `tracing_unbounded` |
|
|
//! | action | One of `send`/`received`/`dropped` |
|
|
|
|
pub mod metrics;
|
|
pub mod mpsc;
|
|
pub mod notification;
|
|
pub mod status_sinks;
|