Module utils

Source

MacrosΒ§

delayed_panic πŸ”’
Delays the exit of the program for 15 seconds, to allow for logs to be flushed. Then panics with the given arguments.

StructsΒ§

AddMethodMiddleware
AddMethodMiddlewareLayer
RbfSigningInfo
Information to re-sign an RBF transaction. Specifically the merkle root of the taproot to keyspend with and the output index of the utxo to be re-signed.
TxMetadata

EnumsΒ§

FeePayingType
Specifies the fee bumping strategy used for a transaction.

TraitsΒ§

Last20Bytes
NamedEntity
A trait for entities that have a name, operator, verifier, etc. Used to distinguish between state machines with different owners in the database, and to provide a human-readable name for the entity for task names.
ScriptBufExt
TryLast20Bytes

FunctionsΒ§

combine_errors
Collects errors from an iterator of results and returns a combined error if any failed.
env_subscriber_to_human πŸ”’
env_subscriber_to_json πŸ”’
env_subscriber_with_file πŸ”’
flatten_join_named_results
Collects all errors (both outer and inner) from named task results and returns a combined error if any task failed.
get_vergen_response
initialize_logger
Initializes a [tracing] subscriber depending on the environment. [EnvFilter] is used with an optional default level. Sets up the color_eyre handler.
initialize_telemetry
is_json_logs πŸ”’
join_all_combine_errors
Executes a collection of fallible futures concurrently and aggregates failures into a single BridgeError.
monitor_standalone_task
Monitors a [tokio::task::JoinHandle] in the background and logs it’s end result.
timed_request
Wraps a future with a timeout, returning a Status::deadline_exceeded gRPC error if the future does not complete within the specified duration.
timed_request_base
Wraps a future with a timeout and adds a debug span with the description.
timed_try_join_all
Concurrently executes a collection of futures, applying a timeout to each one individually. If any future fails or times out, the entire operation is aborted and an error is returned.
try_set_global_subscriber πŸ”’

Type AliasesΒ§

BoxFuture πŸ”’