@@ -179,7 +179,7 @@ impl Display for NodeInfo {
179
179
180
180
/// LightningNode represents the functionality that is required to execute events on a lightning node.
181
181
#[ async_trait]
182
- pub trait LightningNode {
182
+ pub trait LightningNode : Send {
183
183
/// Get information about the node.
184
184
fn get_info ( & self ) -> & NodeInfo ;
185
185
/// Get the network this node is running at
@@ -325,7 +325,7 @@ enum SimulationOutput {
325
325
#[ derive( Clone ) ]
326
326
pub struct Simulation {
327
327
// The lightning node that is being simulated.
328
- nodes : HashMap < PublicKey , Arc < Mutex < dyn LightningNode + Send > > > ,
328
+ nodes : HashMap < PublicKey , Arc < Mutex < dyn LightningNode > > > ,
329
329
// The activity that are to be executed on the node.
330
330
activity : Vec < ActivityDefinition > ,
331
331
// High level triggers used to manage simulation tasks and shutdown.
@@ -362,7 +362,7 @@ struct ExecutorKit {
362
362
363
363
impl Simulation {
364
364
pub fn new (
365
- nodes : HashMap < PublicKey , Arc < Mutex < dyn LightningNode + Send > > > ,
365
+ nodes : HashMap < PublicKey , Arc < Mutex < dyn LightningNode > > > ,
366
366
activity : Vec < ActivityDefinition > ,
367
367
total_time : Option < u32 > ,
368
368
expected_payment_msat : u64 ,
@@ -722,7 +722,7 @@ impl Simulation {
722
722
// expect the senders corresponding to our receiver to be dropped, which will cause the receiver to error out and
723
723
// exit.
724
724
async fn consume_events (
725
- node : Arc < Mutex < dyn LightningNode + Send > > ,
725
+ node : Arc < Mutex < dyn LightningNode > > ,
726
726
mut receiver : Receiver < SimulationEvent > ,
727
727
sender : Sender < SimulationOutput > ,
728
728
shutdown : Trigger ,
@@ -986,7 +986,7 @@ async fn run_results_logger(
986
986
/// out. In the multiple-producer case, a single producer shutting down does not drop *all* sending channels so the
987
987
/// consumer will not exit and a trigger is required.
988
988
async fn produce_simulation_results (
989
- nodes : HashMap < PublicKey , Arc < Mutex < dyn LightningNode + Send > > > ,
989
+ nodes : HashMap < PublicKey , Arc < Mutex < dyn LightningNode > > > ,
990
990
mut output_receiver : Receiver < SimulationOutput > ,
991
991
results : Sender < ( Payment , PaymentResult ) > ,
992
992
shutdown : Listener ,
@@ -1034,7 +1034,7 @@ async fn produce_simulation_results(
1034
1034
}
1035
1035
1036
1036
async fn track_payment_result (
1037
- node : Arc < Mutex < dyn LightningNode + Send > > ,
1037
+ node : Arc < Mutex < dyn LightningNode > > ,
1038
1038
results : Sender < ( Payment , PaymentResult ) > ,
1039
1039
payment : Payment ,
1040
1040
shutdown : Listener ,
0 commit comments