21 lines
556 B
Rust
21 lines
556 B
Rust
use harmony::{
|
|
inventory::Inventory,
|
|
maestro::Maestro,
|
|
modules::dummy::{ErrorScore, PanicScore, SuccessScore},
|
|
topology::LocalhostTopology,
|
|
};
|
|
|
|
#[tokio::main]
|
|
async fn main() {
|
|
let inventory = Inventory::autoload();
|
|
let topology = LocalhostTopology::new();
|
|
let mut maestro = Maestro::initialize(inventory, topology).await.unwrap();
|
|
|
|
maestro.register_all(vec![
|
|
Box::new(SuccessScore {}),
|
|
Box::new(ErrorScore {}),
|
|
Box::new(PanicScore {}),
|
|
]);
|
|
harmony_cli::init(maestro, None).await.unwrap();
|
|
}
|