Skip to content

Commit

Permalink
⚡️ Review rpc networks failsafe
Browse files Browse the repository at this point in the history
  • Loading branch information
KONFeature committed Jan 7, 2025
1 parent d02b4f5 commit c5598f3
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
10 changes: 5 additions & 5 deletions packages/erpc/src/networks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ import type { FailsafeConfig, NetworkConfig } from "@erpc-cloud/config";

const defaultFailsafe: FailsafeConfig = {
retry: {
maxAttempts: 5,
delay: "500ms",
backoffMaxDelay: "10s",
maxAttempts: 2,
delay: "100ms",
backoffMaxDelay: "2s",
backoffFactor: 0.5,
jitter: "200ms",
},
Expand All @@ -19,7 +19,7 @@ export const arbNetwork = {
failsafe: {
...defaultFailsafe,
timeout: {
duration: "30s",
duration: "5s",
},
},
evm: {
Expand All @@ -32,7 +32,7 @@ export const arbSepoliaNetwork = {
failsafe: {
...defaultFailsafe,
timeout: {
duration: "60s",
duration: "10s",
},
},
evm: {
Expand Down
4 changes: 2 additions & 2 deletions packages/erpc/src/rateLimits.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,13 +35,13 @@ export const alchemyRateRules: RuleExport = [
genericRateLimitsRules(200),
{
method: "eth_getLogs",
maxCount: 30,
maxCount: 20,
period: "1s",
waitTime: "10s",
},
{
method: "eth_getBlockByNumber",
maxCount: 60,
maxCount: 30,
period: "1s",
waitTime: "10s",
},
Expand Down

0 comments on commit c5598f3

Please sign in to comment.