Skip to content

Commit 4541d4b

Browse files
authored
Merge pull request #320 from HathorNetwork/fix/rc/increase-retry-attempts
fix: increase retry attempts when getting events from fullnodes
1 parent 75b0736 commit 4541d4b

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

packages/daemon/src/services/index.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -859,7 +859,9 @@ export const checkForMissedEvents = async (context: Context): Promise<{ hasNewEv
859859
return res;
860860
},
861861
{
862-
maxRetries: 3,
862+
// It's possible that the fullnode is under high load or having intermittent issues,
863+
// so we use a higher number of retries to give it a chance to recover
864+
maxRetries: 10,
863865
initialDelayMs: 1000,
864866
maxDelayMs: 10000,
865867
backoffMultiplier: 2,

packages/daemon/src/utils/retry.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ export interface RetryOptions {
1616
}
1717

1818
const DEFAULT_OPTIONS: Required<RetryOptions> = {
19-
maxRetries: 3,
19+
maxRetries: 5,
2020
initialDelayMs: 1000,
2121
maxDelayMs: 10000,
2222
backoffMultiplier: 2,

0 commit comments

Comments
 (0)