File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -79,7 +79,9 @@ pub trait DistributedScheduler: Send {
7979 scheduled_tasks : & ' a mut BinaryHeap < ScheduledTask > ,
8080 ) -> Pin < Box < dyn Future < Output = Result < ( ) , BeatError > > + Send + ' a > > ;
8181
82- fn shutdown < ' a > ( & ' a mut self ) -> Pin < Box < dyn Future < Output = Result < ( ) , BeatError > > + Send + ' a > > {
82+ fn shutdown < ' a > (
83+ & ' a mut self ,
84+ ) -> Pin < Box < dyn Future < Output = Result < ( ) , BeatError > > + Send + ' a > > {
8385 Box :: pin ( async { Ok ( ( ) ) } )
8486 }
8587}
Original file line number Diff line number Diff line change @@ -516,7 +516,9 @@ impl DistributedScheduler for RedisSchedulerBackend {
516516 } )
517517 }
518518
519- fn shutdown < ' a > ( & ' a mut self ) -> Pin < Box < dyn Future < Output = Result < ( ) , BeatError > > + Send + ' a > > {
519+ fn shutdown < ' a > (
520+ & ' a mut self ,
521+ ) -> Pin < Box < dyn Future < Output = Result < ( ) , BeatError > > + Send + ' a > > {
520522 Box :: pin ( async move {
521523 if self . state . is_leader {
522524 if let Err ( err) = self . release_lock ( ) . await {
Original file line number Diff line number Diff line change @@ -235,7 +235,8 @@ async fn test_beat_max_sleep_duration() {
235235 & mut self ,
236236 _scheduled_tasks : & mut std:: collections:: BinaryHeap < ScheduledTask > ,
237237 ) -> Result < ( ) , BeatError > {
238- self . num_sync_calls . fetch_add ( 1 , std:: sync:: atomic:: Ordering :: Relaxed ) ;
238+ self . num_sync_calls
239+ . fetch_add ( 1 , std:: sync:: atomic:: Ordering :: Relaxed ) ;
239240 Ok ( ( ) )
240241 }
241242 }
You can’t perform that action at this time.
0 commit comments