Running Floresta
So far in the Floresta journey we have mostly learned about the two core library crates: floresta-chain
and floresta-wire
.
In Chapter 1 we went over the common library (floresta-common
), the three extra libraries (floresta-watch-only
, floresta-compact-filters
, and floresta-electrum
) and the floresta
meta-crate. We also mentioned floresta-rpc
and floresta-node
, the libraries powering our two current binaries.
This chapter puts it all together leveraging the assembler library floresta-node
, which provides:
-
The
Florestad
struct: the "orchestrator" that starts the node, spawning asynchronous tasks for each subsystem (theUtreexoNode
, an optional JSON-RPC server, the Electrum server, etc.). It also sends the stop signal when requested to, as the main loop inflorestad
keeps checking for aCtrl+C
signal. -
The
Config
type: a single configuration struct used to bootstrapFlorestad
.