Crate mithril_common

Source
Expand description

Shared datatypes and traits used by Mithril rust projects

Provide:

Re-exports§

pub use entities::CardanoNetwork;
pub use entities::MagicId;

Modules§

api_version
API Version provider service
cardano_block_scanner
The module used for parsing Cardano transactions
certificate_chain
Tools to retrieve, validate the Certificate Chain created by an aggregator
chain_observer
Tools to request metadata, like the current epoch or the stake distribution, from the Cardano
chain_reader
Tools to read chain blocks sequentially
crypto_helper
Tools and types to abstract the use of the Mithril STM library
digesters
Tools to compute mithril digest from a Cardano node database.
entities
The entities used by, and exchanged between, the aggregator, signers and client.
era
The module used for handling eras
logging
Logging utilities for the Mithril project.
messages
Messages module This module aims at providing shared structures for API communications.
protocol
Protocol module
signable_builder
The module used for building signables
test_utils
Test utilities

Macros§

assert_dir_eq
Compare a directory against a string representing its expected structure or against another directory.
assert_same_json
Compare two json strings ignoring keys order
current_function
Returns the name of the function that called this macro.
current_function_path
Returns the path of the function that called this macro.
era_deprecate
Macro used to mark the code that should be cleaned up when the new era is activated
temp_dir
Return a temporary directory based on the current function name.
temp_dir_create
Create and return a temporary directory based on the current function name.

Structs§

MithrilTickerService
A TickerService using a ChainObserver and a ImmutableFileObserver.

Constants§

MITHRIL_AGGREGATOR_VERSION_HEADER
Mithril aggregator node version header name
MITHRIL_API_VERSION_HEADER
Mithril API protocol version header name
MITHRIL_ORIGIN_TAG_HEADER
Mithril origin of the request
MITHRIL_SIGNER_VERSION_HEADER
Mithril signer node version header name

Traits§

TickerService
TickerService

Type Aliases§

StdError
Generic error type
StdResult
Generic result type