update
This commit is contained in:
@@ -11,7 +11,7 @@
|
||||
|
||||
const nats = require('nats');
|
||||
const crypto = require('crypto');
|
||||
const fetch = require('node-fetch');
|
||||
// Use native fetch available in Node.js 18+
|
||||
const arrow = require('apache-arrow');
|
||||
|
||||
// ---------------------------------------------- Constants ---------------------------------------------- //
|
||||
@@ -302,7 +302,7 @@ async function fetchWithBackoff(url, maxRetries, baseDelay, maxDelay, correlatio
|
||||
throw new Error(`Failed to fetch: ${response.status}`);
|
||||
}
|
||||
} catch (e) {
|
||||
logTrace(correlationId, `Attempt ${attempt} failed: ${e.constructor.name}`);
|
||||
logTrace(correlationId, `Attempt ${attempt} failed: ${e.constructor.name} - ${e.message}`);
|
||||
|
||||
if (attempt < maxRetries) {
|
||||
await new Promise(resolve => setTimeout(resolve, delay));
|
||||
|
||||
Reference in New Issue
Block a user