@adaptic/backend-legacy 0.0.959 → 0.0.961
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/ABTest.cjs +180 -66
- package/Account.cjs +180 -66
- package/AccountDecisionRecord.cjs +180 -66
- package/AccountLinkingRequest.cjs +180 -66
- package/Action.cjs +180 -66
- package/Alert.cjs +180 -66
- package/Allocation.cjs +180 -66
- package/AlpacaAccount.cjs +180 -66
- package/AnalyticsConfiguration.cjs +180 -66
- package/AnalyticsSnapshot.cjs +180 -66
- package/Asset.cjs +180 -66
- package/AuditLog.cjs +180 -66
- package/Authenticator.cjs +180 -66
- package/Configuration.cjs +180 -66
- package/ConflictEvent.cjs +180 -66
- package/ConnectionHealthSnapshot.cjs +180 -66
- package/Customer.cjs +180 -66
- package/DeadLetterMessage.cjs +180 -66
- package/DecisionMemorySummary.cjs +180 -66
- package/EconomicEvent.cjs +180 -66
- package/EquityBar.cjs +180 -66
- package/Event.cjs +180 -66
- package/EventSnapshot.cjs +180 -66
- package/FeatureImportanceAnalysis.cjs +180 -66
- package/InstitutionalFlowSignal.cjs +180 -66
- package/InstitutionalHolding.cjs +180 -66
- package/InstitutionalSentimentAlerts.cjs +180 -66
- package/InstitutionalSentimentErrors.cjs +180 -66
- package/InstitutionalSentimentHistory.cjs +180 -66
- package/InstitutionalSentimentMetrics.cjs +180 -66
- package/InviteToken.cjs +180 -66
- package/LinkedProvider.cjs +180 -66
- package/LlmConfiguration.cjs +180 -66
- package/MLModelVersion.cjs +180 -66
- package/MLTrainingData.cjs +180 -66
- package/MarketSentiment.cjs +180 -66
- package/ModelArtifact.cjs +180 -66
- package/ModelVersion.cjs +180 -66
- package/ModelVersionArtifact.cjs +180 -66
- package/NewsArticle.cjs +180 -66
- package/NewsArticleAssetSentiment.cjs +180 -66
- package/OptionsContract.cjs +180 -66
- package/OptionsGreeksHistory.cjs +180 -66
- package/OptionsPosition.cjs +180 -66
- package/OptionsPositionEvent.cjs +180 -66
- package/OptionsTradeExecution.cjs +180 -66
- package/PolicyOverlay.cjs +180 -66
- package/PortfolioGreeksHistory.cjs +180 -66
- package/ScheduledOptionOrder.cjs +180 -66
- package/Session.cjs +180 -66
- package/SignalGeneratorMetrics.cjs +180 -66
- package/SignalLineage.cjs +180 -66
- package/SignalOutcome.cjs +180 -66
- package/SignalPriorityQueue.cjs +180 -66
- package/SyncEvent.cjs +180 -66
- package/SystemAlert.cjs +180 -66
- package/Trade.cjs +180 -66
- package/TradeAuditEvent.cjs +180 -66
- package/TradeExecutionHistory.cjs +180 -66
- package/TradeOutcome.cjs +180 -66
- package/TradingPolicy.cjs +180 -66
- package/User.cjs +180 -66
- package/VerificationToken.cjs +180 -66
- package/WaitlistEntry.cjs +180 -66
- package/esm/ABTest.d.ts.map +1 -1
- package/esm/ABTest.js.map +1 -1
- package/esm/ABTest.mjs +180 -66
- package/esm/Account.d.ts.map +1 -1
- package/esm/Account.js.map +1 -1
- package/esm/Account.mjs +180 -66
- package/esm/AccountDecisionRecord.d.ts.map +1 -1
- package/esm/AccountDecisionRecord.js.map +1 -1
- package/esm/AccountDecisionRecord.mjs +180 -66
- package/esm/AccountLinkingRequest.d.ts.map +1 -1
- package/esm/AccountLinkingRequest.js.map +1 -1
- package/esm/AccountLinkingRequest.mjs +180 -66
- package/esm/Action.d.ts.map +1 -1
- package/esm/Action.js.map +1 -1
- package/esm/Action.mjs +180 -66
- package/esm/Alert.d.ts.map +1 -1
- package/esm/Alert.js.map +1 -1
- package/esm/Alert.mjs +180 -66
- package/esm/Allocation.d.ts.map +1 -1
- package/esm/Allocation.js.map +1 -1
- package/esm/Allocation.mjs +180 -66
- package/esm/AlpacaAccount.d.ts.map +1 -1
- package/esm/AlpacaAccount.js.map +1 -1
- package/esm/AlpacaAccount.mjs +180 -66
- package/esm/AnalyticsConfiguration.d.ts.map +1 -1
- package/esm/AnalyticsConfiguration.js.map +1 -1
- package/esm/AnalyticsConfiguration.mjs +180 -66
- package/esm/AnalyticsSnapshot.d.ts.map +1 -1
- package/esm/AnalyticsSnapshot.js.map +1 -1
- package/esm/AnalyticsSnapshot.mjs +180 -66
- package/esm/Asset.d.ts.map +1 -1
- package/esm/Asset.js.map +1 -1
- package/esm/Asset.mjs +180 -66
- package/esm/AuditLog.d.ts.map +1 -1
- package/esm/AuditLog.js.map +1 -1
- package/esm/AuditLog.mjs +180 -66
- package/esm/Authenticator.d.ts.map +1 -1
- package/esm/Authenticator.js.map +1 -1
- package/esm/Authenticator.mjs +180 -66
- package/esm/Configuration.d.ts.map +1 -1
- package/esm/Configuration.js.map +1 -1
- package/esm/Configuration.mjs +180 -66
- package/esm/ConflictEvent.d.ts.map +1 -1
- package/esm/ConflictEvent.js.map +1 -1
- package/esm/ConflictEvent.mjs +180 -66
- package/esm/ConnectionHealthSnapshot.d.ts.map +1 -1
- package/esm/ConnectionHealthSnapshot.js.map +1 -1
- package/esm/ConnectionHealthSnapshot.mjs +180 -66
- package/esm/Customer.d.ts.map +1 -1
- package/esm/Customer.js.map +1 -1
- package/esm/Customer.mjs +180 -66
- package/esm/DeadLetterMessage.d.ts.map +1 -1
- package/esm/DeadLetterMessage.js.map +1 -1
- package/esm/DeadLetterMessage.mjs +180 -66
- package/esm/DecisionMemorySummary.d.ts.map +1 -1
- package/esm/DecisionMemorySummary.js.map +1 -1
- package/esm/DecisionMemorySummary.mjs +180 -66
- package/esm/EconomicEvent.d.ts.map +1 -1
- package/esm/EconomicEvent.js.map +1 -1
- package/esm/EconomicEvent.mjs +180 -66
- package/esm/EquityBar.d.ts.map +1 -1
- package/esm/EquityBar.js.map +1 -1
- package/esm/EquityBar.mjs +180 -66
- package/esm/Event.d.ts.map +1 -1
- package/esm/Event.js.map +1 -1
- package/esm/Event.mjs +180 -66
- package/esm/EventSnapshot.d.ts.map +1 -1
- package/esm/EventSnapshot.js.map +1 -1
- package/esm/EventSnapshot.mjs +180 -66
- package/esm/FeatureImportanceAnalysis.d.ts.map +1 -1
- package/esm/FeatureImportanceAnalysis.js.map +1 -1
- package/esm/FeatureImportanceAnalysis.mjs +180 -66
- package/esm/InstitutionalFlowSignal.d.ts.map +1 -1
- package/esm/InstitutionalFlowSignal.js.map +1 -1
- package/esm/InstitutionalFlowSignal.mjs +180 -66
- package/esm/InstitutionalHolding.d.ts.map +1 -1
- package/esm/InstitutionalHolding.js.map +1 -1
- package/esm/InstitutionalHolding.mjs +180 -66
- package/esm/InstitutionalSentimentAlerts.d.ts.map +1 -1
- package/esm/InstitutionalSentimentAlerts.js.map +1 -1
- package/esm/InstitutionalSentimentAlerts.mjs +180 -66
- package/esm/InstitutionalSentimentErrors.d.ts.map +1 -1
- package/esm/InstitutionalSentimentErrors.js.map +1 -1
- package/esm/InstitutionalSentimentErrors.mjs +180 -66
- package/esm/InstitutionalSentimentHistory.d.ts.map +1 -1
- package/esm/InstitutionalSentimentHistory.js.map +1 -1
- package/esm/InstitutionalSentimentHistory.mjs +180 -66
- package/esm/InstitutionalSentimentMetrics.d.ts.map +1 -1
- package/esm/InstitutionalSentimentMetrics.js.map +1 -1
- package/esm/InstitutionalSentimentMetrics.mjs +180 -66
- package/esm/InviteToken.d.ts.map +1 -1
- package/esm/InviteToken.js.map +1 -1
- package/esm/InviteToken.mjs +180 -66
- package/esm/LinkedProvider.d.ts.map +1 -1
- package/esm/LinkedProvider.js.map +1 -1
- package/esm/LinkedProvider.mjs +180 -66
- package/esm/LlmConfiguration.d.ts.map +1 -1
- package/esm/LlmConfiguration.js.map +1 -1
- package/esm/LlmConfiguration.mjs +180 -66
- package/esm/MLModelVersion.d.ts.map +1 -1
- package/esm/MLModelVersion.js.map +1 -1
- package/esm/MLModelVersion.mjs +180 -66
- package/esm/MLTrainingData.d.ts.map +1 -1
- package/esm/MLTrainingData.js.map +1 -1
- package/esm/MLTrainingData.mjs +180 -66
- package/esm/MarketSentiment.d.ts.map +1 -1
- package/esm/MarketSentiment.js.map +1 -1
- package/esm/MarketSentiment.mjs +180 -66
- package/esm/ModelArtifact.d.ts.map +1 -1
- package/esm/ModelArtifact.js.map +1 -1
- package/esm/ModelArtifact.mjs +180 -66
- package/esm/ModelVersion.d.ts.map +1 -1
- package/esm/ModelVersion.js.map +1 -1
- package/esm/ModelVersion.mjs +180 -66
- package/esm/ModelVersionArtifact.d.ts.map +1 -1
- package/esm/ModelVersionArtifact.js.map +1 -1
- package/esm/ModelVersionArtifact.mjs +180 -66
- package/esm/NewsArticle.d.ts.map +1 -1
- package/esm/NewsArticle.js.map +1 -1
- package/esm/NewsArticle.mjs +180 -66
- package/esm/NewsArticleAssetSentiment.d.ts.map +1 -1
- package/esm/NewsArticleAssetSentiment.js.map +1 -1
- package/esm/NewsArticleAssetSentiment.mjs +180 -66
- package/esm/OptionsContract.d.ts.map +1 -1
- package/esm/OptionsContract.js.map +1 -1
- package/esm/OptionsContract.mjs +180 -66
- package/esm/OptionsGreeksHistory.d.ts.map +1 -1
- package/esm/OptionsGreeksHistory.js.map +1 -1
- package/esm/OptionsGreeksHistory.mjs +180 -66
- package/esm/OptionsPosition.d.ts.map +1 -1
- package/esm/OptionsPosition.js.map +1 -1
- package/esm/OptionsPosition.mjs +180 -66
- package/esm/OptionsPositionEvent.d.ts.map +1 -1
- package/esm/OptionsPositionEvent.js.map +1 -1
- package/esm/OptionsPositionEvent.mjs +180 -66
- package/esm/OptionsTradeExecution.d.ts.map +1 -1
- package/esm/OptionsTradeExecution.js.map +1 -1
- package/esm/OptionsTradeExecution.mjs +180 -66
- package/esm/PolicyOverlay.d.ts.map +1 -1
- package/esm/PolicyOverlay.js.map +1 -1
- package/esm/PolicyOverlay.mjs +180 -66
- package/esm/PortfolioGreeksHistory.d.ts.map +1 -1
- package/esm/PortfolioGreeksHistory.js.map +1 -1
- package/esm/PortfolioGreeksHistory.mjs +180 -66
- package/esm/ScheduledOptionOrder.d.ts.map +1 -1
- package/esm/ScheduledOptionOrder.js.map +1 -1
- package/esm/ScheduledOptionOrder.mjs +180 -66
- package/esm/Session.d.ts.map +1 -1
- package/esm/Session.js.map +1 -1
- package/esm/Session.mjs +180 -66
- package/esm/SignalGeneratorMetrics.d.ts.map +1 -1
- package/esm/SignalGeneratorMetrics.js.map +1 -1
- package/esm/SignalGeneratorMetrics.mjs +180 -66
- package/esm/SignalLineage.d.ts.map +1 -1
- package/esm/SignalLineage.js.map +1 -1
- package/esm/SignalLineage.mjs +180 -66
- package/esm/SignalOutcome.d.ts.map +1 -1
- package/esm/SignalOutcome.js.map +1 -1
- package/esm/SignalOutcome.mjs +180 -66
- package/esm/SignalPriorityQueue.d.ts.map +1 -1
- package/esm/SignalPriorityQueue.js.map +1 -1
- package/esm/SignalPriorityQueue.mjs +180 -66
- package/esm/SyncEvent.d.ts.map +1 -1
- package/esm/SyncEvent.js.map +1 -1
- package/esm/SyncEvent.mjs +180 -66
- package/esm/SystemAlert.d.ts.map +1 -1
- package/esm/SystemAlert.js.map +1 -1
- package/esm/SystemAlert.mjs +180 -66
- package/esm/Trade.d.ts.map +1 -1
- package/esm/Trade.js.map +1 -1
- package/esm/Trade.mjs +180 -66
- package/esm/TradeAuditEvent.d.ts.map +1 -1
- package/esm/TradeAuditEvent.js.map +1 -1
- package/esm/TradeAuditEvent.mjs +180 -66
- package/esm/TradeExecutionHistory.d.ts.map +1 -1
- package/esm/TradeExecutionHistory.js.map +1 -1
- package/esm/TradeExecutionHistory.mjs +180 -66
- package/esm/TradeOutcome.d.ts.map +1 -1
- package/esm/TradeOutcome.js.map +1 -1
- package/esm/TradeOutcome.mjs +180 -66
- package/esm/TradingPolicy.d.ts.map +1 -1
- package/esm/TradingPolicy.js.map +1 -1
- package/esm/TradingPolicy.mjs +180 -66
- package/esm/User.d.ts.map +1 -1
- package/esm/User.js.map +1 -1
- package/esm/User.mjs +180 -66
- package/esm/VerificationToken.d.ts.map +1 -1
- package/esm/VerificationToken.js.map +1 -1
- package/esm/VerificationToken.mjs +180 -66
- package/esm/WaitlistEntry.d.ts.map +1 -1
- package/esm/WaitlistEntry.js.map +1 -1
- package/esm/WaitlistEntry.mjs +180 -66
- package/esm/index.d.ts.map +1 -1
- package/package.json +1 -1
package/esm/NewsArticle.mjs
CHANGED
|
@@ -303,13 +303,28 @@ export const NewsArticle = {
|
|
|
303
303
|
await new Promise(resolve => setTimeout(resolve, delay));
|
|
304
304
|
continue;
|
|
305
305
|
}
|
|
306
|
-
// Log structured error details and rethrow
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
306
|
+
// Log structured error details and rethrow.
|
|
307
|
+
// Demote transient failures to WARN with explicit transient+recoveryHint
|
|
308
|
+
// metadata so log analytics can distinguish recoverable upstream retries
|
|
309
|
+
// from true defects.
|
|
310
|
+
if (isConnectionError) {
|
|
311
|
+
logger.warn("Database create operation failed (transient after retries)", {
|
|
312
|
+
operation: 'createOneNewsArticle',
|
|
313
|
+
model: 'NewsArticle',
|
|
314
|
+
error: String(error),
|
|
315
|
+
isRetryable: true,
|
|
316
|
+
transient: true,
|
|
317
|
+
recoveryHint: "Upstream caller should retry on next cycle",
|
|
318
|
+
});
|
|
319
|
+
}
|
|
320
|
+
else {
|
|
321
|
+
logger.error("Database create operation failed", {
|
|
322
|
+
operation: 'createOneNewsArticle',
|
|
323
|
+
model: 'NewsArticle',
|
|
324
|
+
error: String(error),
|
|
325
|
+
isRetryable: false,
|
|
326
|
+
});
|
|
327
|
+
}
|
|
313
328
|
throw error;
|
|
314
329
|
}
|
|
315
330
|
}
|
|
@@ -443,13 +458,25 @@ export const NewsArticle = {
|
|
|
443
458
|
await new Promise(resolve => setTimeout(resolve, delay));
|
|
444
459
|
continue;
|
|
445
460
|
}
|
|
446
|
-
// Log structured error details and rethrow
|
|
447
|
-
|
|
448
|
-
operation
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
461
|
+
// Log structured error details and rethrow (transient -> WARN).
|
|
462
|
+
if (isConnectionError) {
|
|
463
|
+
logger.warn("Database createMany operation failed (transient after retries)", {
|
|
464
|
+
operation: 'createManyNewsArticle',
|
|
465
|
+
model: 'NewsArticle',
|
|
466
|
+
error: String(error),
|
|
467
|
+
isRetryable: true,
|
|
468
|
+
transient: true,
|
|
469
|
+
recoveryHint: "Upstream caller should retry on next cycle",
|
|
470
|
+
});
|
|
471
|
+
}
|
|
472
|
+
else {
|
|
473
|
+
logger.error("Database createMany operation failed", {
|
|
474
|
+
operation: 'createManyNewsArticle',
|
|
475
|
+
model: 'NewsArticle',
|
|
476
|
+
error: String(error),
|
|
477
|
+
isRetryable: false,
|
|
478
|
+
});
|
|
479
|
+
}
|
|
453
480
|
throw error;
|
|
454
481
|
}
|
|
455
482
|
}
|
|
@@ -1179,14 +1206,27 @@ export const NewsArticle = {
|
|
|
1179
1206
|
await new Promise(resolve => setTimeout(resolve, delay));
|
|
1180
1207
|
continue;
|
|
1181
1208
|
}
|
|
1182
|
-
// Log structured error details and rethrow
|
|
1183
|
-
|
|
1184
|
-
operation
|
|
1185
|
-
|
|
1186
|
-
|
|
1187
|
-
|
|
1188
|
-
|
|
1189
|
-
|
|
1209
|
+
// Log structured error details and rethrow (transient -> WARN).
|
|
1210
|
+
if (isConnectionError) {
|
|
1211
|
+
logger.warn("Database update operation failed (transient after retries)", {
|
|
1212
|
+
operation: 'updateOneNewsArticle',
|
|
1213
|
+
model: 'NewsArticle',
|
|
1214
|
+
error: String(error),
|
|
1215
|
+
recordId: props.id,
|
|
1216
|
+
isRetryable: true,
|
|
1217
|
+
transient: true,
|
|
1218
|
+
recoveryHint: "Upstream caller should retry on next cycle",
|
|
1219
|
+
});
|
|
1220
|
+
}
|
|
1221
|
+
else {
|
|
1222
|
+
logger.error("Database update operation failed", {
|
|
1223
|
+
operation: 'updateOneNewsArticle',
|
|
1224
|
+
model: 'NewsArticle',
|
|
1225
|
+
error: String(error),
|
|
1226
|
+
recordId: props.id,
|
|
1227
|
+
isRetryable: false,
|
|
1228
|
+
});
|
|
1229
|
+
}
|
|
1190
1230
|
throw error;
|
|
1191
1231
|
}
|
|
1192
1232
|
}
|
|
@@ -2075,14 +2115,27 @@ export const NewsArticle = {
|
|
|
2075
2115
|
await new Promise(resolve => setTimeout(resolve, delay));
|
|
2076
2116
|
continue;
|
|
2077
2117
|
}
|
|
2078
|
-
// Log structured error details and rethrow
|
|
2079
|
-
|
|
2080
|
-
operation
|
|
2081
|
-
|
|
2082
|
-
|
|
2083
|
-
|
|
2084
|
-
|
|
2085
|
-
|
|
2118
|
+
// Log structured error details and rethrow (transient -> WARN).
|
|
2119
|
+
if (isConnectionError) {
|
|
2120
|
+
logger.warn("Database upsert operation failed (transient after retries)", {
|
|
2121
|
+
operation: 'upsertOneNewsArticle',
|
|
2122
|
+
model: 'NewsArticle',
|
|
2123
|
+
error: String(error),
|
|
2124
|
+
recordId: props.id,
|
|
2125
|
+
isRetryable: true,
|
|
2126
|
+
transient: true,
|
|
2127
|
+
recoveryHint: "Upstream caller should retry on next cycle",
|
|
2128
|
+
});
|
|
2129
|
+
}
|
|
2130
|
+
else {
|
|
2131
|
+
logger.error("Database upsert operation failed", {
|
|
2132
|
+
operation: 'upsertOneNewsArticle',
|
|
2133
|
+
model: 'NewsArticle',
|
|
2134
|
+
error: String(error),
|
|
2135
|
+
recordId: props.id,
|
|
2136
|
+
isRetryable: false,
|
|
2137
|
+
});
|
|
2138
|
+
}
|
|
2086
2139
|
throw error;
|
|
2087
2140
|
}
|
|
2088
2141
|
}
|
|
@@ -2810,13 +2863,25 @@ export const NewsArticle = {
|
|
|
2810
2863
|
await new Promise(resolve => setTimeout(resolve, delay));
|
|
2811
2864
|
continue;
|
|
2812
2865
|
}
|
|
2813
|
-
// Log structured error details and rethrow
|
|
2814
|
-
|
|
2815
|
-
operation
|
|
2816
|
-
|
|
2817
|
-
|
|
2818
|
-
|
|
2819
|
-
|
|
2866
|
+
// Log structured error details and rethrow (transient -> WARN).
|
|
2867
|
+
if (isConnectionError) {
|
|
2868
|
+
logger.warn("Database updateMany operation failed (transient after retries)", {
|
|
2869
|
+
operation: 'updateManyNewsArticle',
|
|
2870
|
+
model: 'NewsArticle',
|
|
2871
|
+
error: String(error),
|
|
2872
|
+
isRetryable: true,
|
|
2873
|
+
transient: true,
|
|
2874
|
+
recoveryHint: "Upstream caller should retry on next cycle",
|
|
2875
|
+
});
|
|
2876
|
+
}
|
|
2877
|
+
else {
|
|
2878
|
+
logger.error("Database updateMany operation failed", {
|
|
2879
|
+
operation: 'updateManyNewsArticle',
|
|
2880
|
+
model: 'NewsArticle',
|
|
2881
|
+
error: String(error),
|
|
2882
|
+
isRetryable: false,
|
|
2883
|
+
});
|
|
2884
|
+
}
|
|
2820
2885
|
throw error;
|
|
2821
2886
|
}
|
|
2822
2887
|
}
|
|
@@ -2938,14 +3003,27 @@ export const NewsArticle = {
|
|
|
2938
3003
|
await new Promise(resolve => setTimeout(resolve, delay));
|
|
2939
3004
|
continue;
|
|
2940
3005
|
}
|
|
2941
|
-
// Log structured error details and rethrow
|
|
2942
|
-
|
|
2943
|
-
operation
|
|
2944
|
-
|
|
2945
|
-
|
|
2946
|
-
|
|
2947
|
-
|
|
2948
|
-
|
|
3006
|
+
// Log structured error details and rethrow (transient -> WARN).
|
|
3007
|
+
if (isConnectionError) {
|
|
3008
|
+
logger.warn("Database delete operation failed (transient after retries)", {
|
|
3009
|
+
operation: 'deleteOneNewsArticle',
|
|
3010
|
+
model: 'NewsArticle',
|
|
3011
|
+
error: String(error),
|
|
3012
|
+
recordId: props.id,
|
|
3013
|
+
isRetryable: true,
|
|
3014
|
+
transient: true,
|
|
3015
|
+
recoveryHint: "Upstream caller should retry on next cycle",
|
|
3016
|
+
});
|
|
3017
|
+
}
|
|
3018
|
+
else {
|
|
3019
|
+
logger.error("Database delete operation failed", {
|
|
3020
|
+
operation: 'deleteOneNewsArticle',
|
|
3021
|
+
model: 'NewsArticle',
|
|
3022
|
+
error: String(error),
|
|
3023
|
+
recordId: props.id,
|
|
3024
|
+
isRetryable: false,
|
|
3025
|
+
});
|
|
3026
|
+
}
|
|
2949
3027
|
throw error;
|
|
2950
3028
|
}
|
|
2951
3029
|
}
|
|
@@ -3044,13 +3122,25 @@ export const NewsArticle = {
|
|
|
3044
3122
|
await new Promise(resolve => setTimeout(resolve, delay));
|
|
3045
3123
|
continue;
|
|
3046
3124
|
}
|
|
3047
|
-
// Log structured error details and rethrow
|
|
3048
|
-
|
|
3049
|
-
operation
|
|
3050
|
-
|
|
3051
|
-
|
|
3052
|
-
|
|
3053
|
-
|
|
3125
|
+
// Log structured error details and rethrow (transient -> WARN).
|
|
3126
|
+
if (isConnectionError) {
|
|
3127
|
+
logger.warn("Database get operation failed (transient after retries)", {
|
|
3128
|
+
operation: 'getNewsArticle',
|
|
3129
|
+
model: 'NewsArticle',
|
|
3130
|
+
error: String(error),
|
|
3131
|
+
isRetryable: true,
|
|
3132
|
+
transient: true,
|
|
3133
|
+
recoveryHint: "Upstream caller should retry on next cycle",
|
|
3134
|
+
});
|
|
3135
|
+
}
|
|
3136
|
+
else {
|
|
3137
|
+
logger.error("Database get operation failed", {
|
|
3138
|
+
operation: 'getNewsArticle',
|
|
3139
|
+
model: 'NewsArticle',
|
|
3140
|
+
error: String(error),
|
|
3141
|
+
isRetryable: false,
|
|
3142
|
+
});
|
|
3143
|
+
}
|
|
3054
3144
|
throw error;
|
|
3055
3145
|
}
|
|
3056
3146
|
}
|
|
@@ -3136,13 +3226,25 @@ export const NewsArticle = {
|
|
|
3136
3226
|
await new Promise(resolve => setTimeout(resolve, delay));
|
|
3137
3227
|
continue;
|
|
3138
3228
|
}
|
|
3139
|
-
// Log structured error details and rethrow
|
|
3140
|
-
|
|
3141
|
-
operation
|
|
3142
|
-
|
|
3143
|
-
|
|
3144
|
-
|
|
3145
|
-
|
|
3229
|
+
// Log structured error details and rethrow (transient -> WARN).
|
|
3230
|
+
if (isConnectionError) {
|
|
3231
|
+
logger.warn("Database getAll operation failed (transient after retries)", {
|
|
3232
|
+
operation: 'getAllNewsArticle',
|
|
3233
|
+
model: 'NewsArticle',
|
|
3234
|
+
error: String(error),
|
|
3235
|
+
isRetryable: true,
|
|
3236
|
+
transient: true,
|
|
3237
|
+
recoveryHint: "Upstream caller should retry on next cycle",
|
|
3238
|
+
});
|
|
3239
|
+
}
|
|
3240
|
+
else {
|
|
3241
|
+
logger.error("Database getAll operation failed", {
|
|
3242
|
+
operation: 'getAllNewsArticle',
|
|
3243
|
+
model: 'NewsArticle',
|
|
3244
|
+
error: String(error),
|
|
3245
|
+
isRetryable: false,
|
|
3246
|
+
});
|
|
3247
|
+
}
|
|
3146
3248
|
throw error;
|
|
3147
3249
|
}
|
|
3148
3250
|
}
|
|
@@ -3255,13 +3357,25 @@ export const NewsArticle = {
|
|
|
3255
3357
|
await new Promise(resolve => setTimeout(resolve, delay));
|
|
3256
3358
|
continue;
|
|
3257
3359
|
}
|
|
3258
|
-
// Log structured error details and rethrow
|
|
3259
|
-
|
|
3260
|
-
operation
|
|
3261
|
-
|
|
3262
|
-
|
|
3263
|
-
|
|
3264
|
-
|
|
3360
|
+
// Log structured error details and rethrow (transient -> WARN).
|
|
3361
|
+
if (isConnectionError) {
|
|
3362
|
+
logger.warn("Database findMany operation failed (transient after retries)", {
|
|
3363
|
+
operation: 'findManyNewsArticle',
|
|
3364
|
+
model: 'NewsArticle',
|
|
3365
|
+
error: String(error),
|
|
3366
|
+
isRetryable: true,
|
|
3367
|
+
transient: true,
|
|
3368
|
+
recoveryHint: "Upstream caller should retry on next cycle",
|
|
3369
|
+
});
|
|
3370
|
+
}
|
|
3371
|
+
else {
|
|
3372
|
+
logger.error("Database findMany operation failed", {
|
|
3373
|
+
operation: 'findManyNewsArticle',
|
|
3374
|
+
model: 'NewsArticle',
|
|
3375
|
+
error: String(error),
|
|
3376
|
+
isRetryable: false,
|
|
3377
|
+
});
|
|
3378
|
+
}
|
|
3265
3379
|
throw error;
|
|
3266
3380
|
}
|
|
3267
3381
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NewsArticleAssetSentiment.d.ts","sourceRoot":"","sources":["../../src/NewsArticleAssetSentiment.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,yBAAyB,IAAI,6BAA6B,EAAE,MAAM,iEAAiE,CAAC;AAC7I,OAAO,EAAmB,gBAAgB,EAAE,qBAAqB,EAAoB,MAAM,UAAU,CAAC;AAoBpG,eAAO,MAAM,yBAAyB;IAEpC;;;;;OAKG;IAEH;;;;;;OAMG;kBACiB,6BAA6B,iBAAiB,gBAAgB,CAAC,qBAAqB,CAAC,GAAG,OAAO,CAAC,6BAA6B,CAAC;
|
|
1
|
+
{"version":3,"file":"NewsArticleAssetSentiment.d.ts","sourceRoot":"","sources":["../../src/NewsArticleAssetSentiment.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,yBAAyB,IAAI,6BAA6B,EAAE,MAAM,iEAAiE,CAAC;AAC7I,OAAO,EAAmB,gBAAgB,EAAE,qBAAqB,EAAoB,MAAM,UAAU,CAAC;AAoBpG,eAAO,MAAM,yBAAyB;IAEpC;;;;;OAKG;IAEH;;;;;;OAMG;kBACiB,6BAA6B,iBAAiB,gBAAgB,CAAC,qBAAqB,CAAC,GAAG,OAAO,CAAC,6BAA6B,CAAC;IAoTpJ;;;;;;;OAOG;sBACqB,6BAA6B,EAAE,iBAAiB,gBAAgB,CAAC,qBAAqB,CAAC,YAAY;QAAE,cAAc,CAAC,EAAE,OAAO,CAAA;KAAE,GAAG,OAAO,CAAC;QAAE,KAAK,EAAE,MAAM,CAAA;KAAE,GAAG,IAAI,CAAC;IAmJ3L;;;;;;OAMG;kBACiB,6BAA6B,iBAAiB,gBAAgB,CAAC,qBAAqB,CAAC,GAAG,OAAO,CAAC,6BAA6B,CAAC;IAmoBlJ;;;;;;OAMG;kBACiB,6BAA6B,iBAAiB,gBAAgB,CAAC,qBAAqB,CAAC,GAAG,OAAO,CAAC,6BAA6B,CAAC;IAwyBlJ;;;;;;OAMG;sBACqB,6BAA6B,EAAE,iBAAiB,gBAAgB,CAAC,qBAAqB,CAAC,GAAG,OAAO,CAAC;QAAE,KAAK,EAAE,MAAM,CAAA;KAAE,GAAG,IAAI,CAAC;IAioBnJ;;;;;;OAMG;kBACiB,6BAA6B,iBAAiB,gBAAgB,CAAC,qBAAqB,CAAC,GAAG,OAAO,CAAC,6BAA6B,CAAC;IAqJlJ;;;;;;;OAOG;eACc,6BAA6B,iBAAiB,gBAAgB,CAAC,qBAAqB,CAAC,eAAe,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,OAAO,CAAC,6BAA6B,GAAG,IAAI,CAAC;IAyH5L;;;;;OAKG;0BACyB,gBAAgB,CAAC,qBAAqB,CAAC,GAAG,OAAO,CAAC,6BAA6B,EAAE,GAAG,IAAI,CAAC;IA6GrH;;;;;;;OAOG;oBACmB,6BAA6B,iBAAiB,gBAAgB,CAAC,qBAAqB,CAAC,eAAe,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,OAAO,CAAC,6BAA6B,EAAE,GAAG,IAAI,CAAC;CAuIpM,CAAC"}
|