Skip to content

Commit 587db84

Browse files
authored
Merge pull request #277 from hypha-space/leo/fix_push_streaming_retry
Fix push streaming retry
2 parents c83ac32 + 665a036 commit 587db84

File tree

2 files changed

+3
-9
lines changed

2 files changed

+3
-9
lines changed

crates/worker/src/connector/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -353,7 +353,7 @@ where
353353
let network = network.clone();
354354
async move {
355355
let retry_strategy =
356-
FixedInterval::from_millis(200).map(jitter).take(6);
356+
FixedInterval::from_millis(200).map(jitter).take(15);
357357

358358
async fn attempt_push<T>(
359359
network: T,

crates/worker/src/executor/parameter_server.rs

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -340,18 +340,12 @@ impl JobExecutor for ParameterServerExecutor {
340340
}
341341
};
342342

343-
match Retry::spawn(retry_strategy.clone(), || {
344-
let connector = connector.clone();
345-
let send = send.clone();
346-
let cancel = cancel.clone();
347-
async move { broadcast_update(
343+
match broadcast_update(
348344
connector.clone(),
349345
send,
350346
gradient_file,
351-
cancel.clone(),
347+
cancel.clone()
352348
).await
353-
}
354-
}).await
355349
{
356350
Ok(()) => {
357351
pending_update = None;

0 commit comments

Comments
 (0)