Skip to content

Commit

Permalink
fix: back off when response health response is not ok
Browse files Browse the repository at this point in the history
  • Loading branch information
DASPRiD committed Nov 4, 2024
1 parent 1bf43d9 commit b27dedd
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -277,9 +277,11 @@ export class SyncManager {
return;
}
} catch {
this.config.logger.info("Unable to verify health, backing off");
await new Promise((resolve) => setTimeout(resolve, 5000));
// Noop
}

this.config.logger.info("Unable to verify health, backing off");
await new Promise((resolve) => setTimeout(resolve, 5000));
}

throw new Error(`Service "${serviceName}" didn't turn ready within 60 seconds`);
Expand Down

0 comments on commit b27dedd

Please sign in to comment.