Crate sp_utils[][src]

Expand description

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:

LabelDescription
entityName of channel passed to tracing_unbounded
actionOne of send/received/dropped

Modules

Metering primitives and globals

Features to meter unbounded channels