@@ -125,22 +125,20 @@ impl Scheduler {
125125 let startup_start = Instant :: now ( ) ;
126126 while !self . all_ready ( ) {
127127 if startup_start. elapsed ( ) > self . startup_timeout {
128- let reason = alloc :: format !(
128+ error ! (
129129 "Startup timeout of {:?} exceeded. Not all activities became ready." ,
130130 self . startup_timeout
131131 ) ;
132- error ! ( "{}" , reason) ;
133- self . shutdown_gracefully ( & reason) ;
132+ self . shutdown_gracefully ( "Startup timeout exceeded." ) ;
134133 return ;
135134 }
136135 if self . wait_next_ready ( ) . is_err ( ) {
137136 // An error here (like a timeout on receive) can also be a startup failure.
138- let reason = alloc :: format !(
137+ error ! (
139138 "Failed to receive ready signal from all activities within startup timeout {:?}." ,
140139 self . startup_timeout
141140 ) ;
142- error ! ( "{}" , reason) ;
143- self . shutdown_gracefully ( & reason) ;
141+ self . shutdown_gracefully ( "Failed to receive ready signals during startup." ) ;
144142 return ;
145143 }
146144 }
@@ -166,10 +164,8 @@ impl Scheduler {
166164 // Wait until a new ready signal has been received.
167165 // If we receive an error (i.e., an ActivityFailed signal), proceed to graceful shutdown.
168166 if let Err ( e) = self . wait_next_ready ( ) {
169- let reason =
170- alloc:: format!( "A failure occurred during step execution: {:?}" , e) ;
171- error ! ( "{}" , & reason) ;
172- self . shutdown_gracefully ( & reason) ;
167+ error ! ( "A failure occurred during step execution: {:?}" , e) ;
168+ self . shutdown_gracefully ( "A failure occurred during step execution." ) ;
173169 return ;
174170 }
175171 }
0 commit comments