mirror of
https://github.com/Nezumi-2711/9router.git
synced 2026-09-22 20:00:47 +00:00
fix: enhance retry logic and configuration for HTTP status codes
This commit is contained in:
@@ -45,8 +45,9 @@ export const RETRY_CONFIG = {
|
||||
// Backward compat: if value is a number, treated as attempts with RETRY_CONFIG.delayMs
|
||||
export const DEFAULT_RETRY_CONFIG = {
|
||||
429: { attempts: 0, delayMs: 0 },
|
||||
502: { attempts: 1, delayMs: 3000 },
|
||||
503: { attempts: 1, delayMs: 2000 }
|
||||
502: { attempts: 3, delayMs: 3000 },
|
||||
503: { attempts: 3, delayMs: 2000 },
|
||||
504: { attempts: 2, delayMs: 3000 }
|
||||
};
|
||||
|
||||
// Normalize a retry entry to { attempts, delayMs }
|
||||
|
||||
Reference in New Issue
Block a user