@adaptic/backend-legacy 0.0.960 → 0.0.962
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/client.cjs +131 -9
- package/client.d.ts +32 -0
- 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/client.d.ts +32 -0
- package/esm/client.d.ts.map +1 -1
- package/esm/client.js.map +1 -1
- package/esm/client.mjs +130 -9
- package/esm/index.d.ts +2 -2
- package/esm/index.d.ts.map +1 -1
- package/esm/index.js.map +1 -1
- package/esm/index.mjs +1 -1
- package/index.cjs +2 -1
- package/index.d.ts +2 -2
- package/package.json +1 -1
package/esm/Action.mjs
CHANGED
|
@@ -198,13 +198,28 @@ export const Action = {
|
|
|
198
198
|
await new Promise(resolve => setTimeout(resolve, delay));
|
|
199
199
|
continue;
|
|
200
200
|
}
|
|
201
|
-
// Log structured error details and rethrow
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
201
|
+
// Log structured error details and rethrow.
|
|
202
|
+
// Demote transient failures to WARN with explicit transient+recoveryHint
|
|
203
|
+
// metadata so log analytics can distinguish recoverable upstream retries
|
|
204
|
+
// from true defects.
|
|
205
|
+
if (isConnectionError) {
|
|
206
|
+
logger.warn("Database create operation failed (transient after retries)", {
|
|
207
|
+
operation: 'createOneAction',
|
|
208
|
+
model: 'Action',
|
|
209
|
+
error: String(error),
|
|
210
|
+
isRetryable: true,
|
|
211
|
+
transient: true,
|
|
212
|
+
recoveryHint: "Upstream caller should retry on next cycle",
|
|
213
|
+
});
|
|
214
|
+
}
|
|
215
|
+
else {
|
|
216
|
+
logger.error("Database create operation failed", {
|
|
217
|
+
operation: 'createOneAction',
|
|
218
|
+
model: 'Action',
|
|
219
|
+
error: String(error),
|
|
220
|
+
isRetryable: false,
|
|
221
|
+
});
|
|
222
|
+
}
|
|
208
223
|
throw error;
|
|
209
224
|
}
|
|
210
225
|
}
|
|
@@ -331,13 +346,25 @@ export const Action = {
|
|
|
331
346
|
await new Promise(resolve => setTimeout(resolve, delay));
|
|
332
347
|
continue;
|
|
333
348
|
}
|
|
334
|
-
// Log structured error details and rethrow
|
|
335
|
-
|
|
336
|
-
operation
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
349
|
+
// Log structured error details and rethrow (transient -> WARN).
|
|
350
|
+
if (isConnectionError) {
|
|
351
|
+
logger.warn("Database createMany operation failed (transient after retries)", {
|
|
352
|
+
operation: 'createManyAction',
|
|
353
|
+
model: 'Action',
|
|
354
|
+
error: String(error),
|
|
355
|
+
isRetryable: true,
|
|
356
|
+
transient: true,
|
|
357
|
+
recoveryHint: "Upstream caller should retry on next cycle",
|
|
358
|
+
});
|
|
359
|
+
}
|
|
360
|
+
else {
|
|
361
|
+
logger.error("Database createMany operation failed", {
|
|
362
|
+
operation: 'createManyAction',
|
|
363
|
+
model: 'Action',
|
|
364
|
+
error: String(error),
|
|
365
|
+
isRetryable: false,
|
|
366
|
+
});
|
|
367
|
+
}
|
|
341
368
|
throw error;
|
|
342
369
|
}
|
|
343
370
|
}
|
|
@@ -639,14 +666,27 @@ export const Action = {
|
|
|
639
666
|
await new Promise(resolve => setTimeout(resolve, delay));
|
|
640
667
|
continue;
|
|
641
668
|
}
|
|
642
|
-
// Log structured error details and rethrow
|
|
643
|
-
|
|
644
|
-
operation
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
669
|
+
// Log structured error details and rethrow (transient -> WARN).
|
|
670
|
+
if (isConnectionError) {
|
|
671
|
+
logger.warn("Database update operation failed (transient after retries)", {
|
|
672
|
+
operation: 'updateOneAction',
|
|
673
|
+
model: 'Action',
|
|
674
|
+
error: String(error),
|
|
675
|
+
recordId: props.id,
|
|
676
|
+
isRetryable: true,
|
|
677
|
+
transient: true,
|
|
678
|
+
recoveryHint: "Upstream caller should retry on next cycle",
|
|
679
|
+
});
|
|
680
|
+
}
|
|
681
|
+
else {
|
|
682
|
+
logger.error("Database update operation failed", {
|
|
683
|
+
operation: 'updateOneAction',
|
|
684
|
+
model: 'Action',
|
|
685
|
+
error: String(error),
|
|
686
|
+
recordId: props.id,
|
|
687
|
+
isRetryable: false,
|
|
688
|
+
});
|
|
689
|
+
}
|
|
650
690
|
throw error;
|
|
651
691
|
}
|
|
652
692
|
}
|
|
@@ -1011,14 +1051,27 @@ export const Action = {
|
|
|
1011
1051
|
await new Promise(resolve => setTimeout(resolve, delay));
|
|
1012
1052
|
continue;
|
|
1013
1053
|
}
|
|
1014
|
-
// Log structured error details and rethrow
|
|
1015
|
-
|
|
1016
|
-
operation
|
|
1017
|
-
|
|
1018
|
-
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
|
|
1054
|
+
// Log structured error details and rethrow (transient -> WARN).
|
|
1055
|
+
if (isConnectionError) {
|
|
1056
|
+
logger.warn("Database upsert operation failed (transient after retries)", {
|
|
1057
|
+
operation: 'upsertOneAction',
|
|
1058
|
+
model: 'Action',
|
|
1059
|
+
error: String(error),
|
|
1060
|
+
recordId: props.id,
|
|
1061
|
+
isRetryable: true,
|
|
1062
|
+
transient: true,
|
|
1063
|
+
recoveryHint: "Upstream caller should retry on next cycle",
|
|
1064
|
+
});
|
|
1065
|
+
}
|
|
1066
|
+
else {
|
|
1067
|
+
logger.error("Database upsert operation failed", {
|
|
1068
|
+
operation: 'upsertOneAction',
|
|
1069
|
+
model: 'Action',
|
|
1070
|
+
error: String(error),
|
|
1071
|
+
recordId: props.id,
|
|
1072
|
+
isRetryable: false,
|
|
1073
|
+
});
|
|
1074
|
+
}
|
|
1022
1075
|
throw error;
|
|
1023
1076
|
}
|
|
1024
1077
|
}
|
|
@@ -1318,13 +1371,25 @@ export const Action = {
|
|
|
1318
1371
|
await new Promise(resolve => setTimeout(resolve, delay));
|
|
1319
1372
|
continue;
|
|
1320
1373
|
}
|
|
1321
|
-
// Log structured error details and rethrow
|
|
1322
|
-
|
|
1323
|
-
operation
|
|
1324
|
-
|
|
1325
|
-
|
|
1326
|
-
|
|
1327
|
-
|
|
1374
|
+
// Log structured error details and rethrow (transient -> WARN).
|
|
1375
|
+
if (isConnectionError) {
|
|
1376
|
+
logger.warn("Database updateMany operation failed (transient after retries)", {
|
|
1377
|
+
operation: 'updateManyAction',
|
|
1378
|
+
model: 'Action',
|
|
1379
|
+
error: String(error),
|
|
1380
|
+
isRetryable: true,
|
|
1381
|
+
transient: true,
|
|
1382
|
+
recoveryHint: "Upstream caller should retry on next cycle",
|
|
1383
|
+
});
|
|
1384
|
+
}
|
|
1385
|
+
else {
|
|
1386
|
+
logger.error("Database updateMany operation failed", {
|
|
1387
|
+
operation: 'updateManyAction',
|
|
1388
|
+
model: 'Action',
|
|
1389
|
+
error: String(error),
|
|
1390
|
+
isRetryable: false,
|
|
1391
|
+
});
|
|
1392
|
+
}
|
|
1328
1393
|
throw error;
|
|
1329
1394
|
}
|
|
1330
1395
|
}
|
|
@@ -1446,14 +1511,27 @@ export const Action = {
|
|
|
1446
1511
|
await new Promise(resolve => setTimeout(resolve, delay));
|
|
1447
1512
|
continue;
|
|
1448
1513
|
}
|
|
1449
|
-
// Log structured error details and rethrow
|
|
1450
|
-
|
|
1451
|
-
operation
|
|
1452
|
-
|
|
1453
|
-
|
|
1454
|
-
|
|
1455
|
-
|
|
1456
|
-
|
|
1514
|
+
// Log structured error details and rethrow (transient -> WARN).
|
|
1515
|
+
if (isConnectionError) {
|
|
1516
|
+
logger.warn("Database delete operation failed (transient after retries)", {
|
|
1517
|
+
operation: 'deleteOneAction',
|
|
1518
|
+
model: 'Action',
|
|
1519
|
+
error: String(error),
|
|
1520
|
+
recordId: props.id,
|
|
1521
|
+
isRetryable: true,
|
|
1522
|
+
transient: true,
|
|
1523
|
+
recoveryHint: "Upstream caller should retry on next cycle",
|
|
1524
|
+
});
|
|
1525
|
+
}
|
|
1526
|
+
else {
|
|
1527
|
+
logger.error("Database delete operation failed", {
|
|
1528
|
+
operation: 'deleteOneAction',
|
|
1529
|
+
model: 'Action',
|
|
1530
|
+
error: String(error),
|
|
1531
|
+
recordId: props.id,
|
|
1532
|
+
isRetryable: false,
|
|
1533
|
+
});
|
|
1534
|
+
}
|
|
1457
1535
|
throw error;
|
|
1458
1536
|
}
|
|
1459
1537
|
}
|
|
@@ -1558,13 +1636,25 @@ export const Action = {
|
|
|
1558
1636
|
await new Promise(resolve => setTimeout(resolve, delay));
|
|
1559
1637
|
continue;
|
|
1560
1638
|
}
|
|
1561
|
-
// Log structured error details and rethrow
|
|
1562
|
-
|
|
1563
|
-
operation
|
|
1564
|
-
|
|
1565
|
-
|
|
1566
|
-
|
|
1567
|
-
|
|
1639
|
+
// Log structured error details and rethrow (transient -> WARN).
|
|
1640
|
+
if (isConnectionError) {
|
|
1641
|
+
logger.warn("Database get operation failed (transient after retries)", {
|
|
1642
|
+
operation: 'getAction',
|
|
1643
|
+
model: 'Action',
|
|
1644
|
+
error: String(error),
|
|
1645
|
+
isRetryable: true,
|
|
1646
|
+
transient: true,
|
|
1647
|
+
recoveryHint: "Upstream caller should retry on next cycle",
|
|
1648
|
+
});
|
|
1649
|
+
}
|
|
1650
|
+
else {
|
|
1651
|
+
logger.error("Database get operation failed", {
|
|
1652
|
+
operation: 'getAction',
|
|
1653
|
+
model: 'Action',
|
|
1654
|
+
error: String(error),
|
|
1655
|
+
isRetryable: false,
|
|
1656
|
+
});
|
|
1657
|
+
}
|
|
1568
1658
|
throw error;
|
|
1569
1659
|
}
|
|
1570
1660
|
}
|
|
@@ -1650,13 +1740,25 @@ export const Action = {
|
|
|
1650
1740
|
await new Promise(resolve => setTimeout(resolve, delay));
|
|
1651
1741
|
continue;
|
|
1652
1742
|
}
|
|
1653
|
-
// Log structured error details and rethrow
|
|
1654
|
-
|
|
1655
|
-
operation
|
|
1656
|
-
|
|
1657
|
-
|
|
1658
|
-
|
|
1659
|
-
|
|
1743
|
+
// Log structured error details and rethrow (transient -> WARN).
|
|
1744
|
+
if (isConnectionError) {
|
|
1745
|
+
logger.warn("Database getAll operation failed (transient after retries)", {
|
|
1746
|
+
operation: 'getAllAction',
|
|
1747
|
+
model: 'Action',
|
|
1748
|
+
error: String(error),
|
|
1749
|
+
isRetryable: true,
|
|
1750
|
+
transient: true,
|
|
1751
|
+
recoveryHint: "Upstream caller should retry on next cycle",
|
|
1752
|
+
});
|
|
1753
|
+
}
|
|
1754
|
+
else {
|
|
1755
|
+
logger.error("Database getAll operation failed", {
|
|
1756
|
+
operation: 'getAllAction',
|
|
1757
|
+
model: 'Action',
|
|
1758
|
+
error: String(error),
|
|
1759
|
+
isRetryable: false,
|
|
1760
|
+
});
|
|
1761
|
+
}
|
|
1660
1762
|
throw error;
|
|
1661
1763
|
}
|
|
1662
1764
|
}
|
|
@@ -1772,13 +1874,25 @@ export const Action = {
|
|
|
1772
1874
|
await new Promise(resolve => setTimeout(resolve, delay));
|
|
1773
1875
|
continue;
|
|
1774
1876
|
}
|
|
1775
|
-
// Log structured error details and rethrow
|
|
1776
|
-
|
|
1777
|
-
operation
|
|
1778
|
-
|
|
1779
|
-
|
|
1780
|
-
|
|
1781
|
-
|
|
1877
|
+
// Log structured error details and rethrow (transient -> WARN).
|
|
1878
|
+
if (isConnectionError) {
|
|
1879
|
+
logger.warn("Database findMany operation failed (transient after retries)", {
|
|
1880
|
+
operation: 'findManyAction',
|
|
1881
|
+
model: 'Action',
|
|
1882
|
+
error: String(error),
|
|
1883
|
+
isRetryable: true,
|
|
1884
|
+
transient: true,
|
|
1885
|
+
recoveryHint: "Upstream caller should retry on next cycle",
|
|
1886
|
+
});
|
|
1887
|
+
}
|
|
1888
|
+
else {
|
|
1889
|
+
logger.error("Database findMany operation failed", {
|
|
1890
|
+
operation: 'findManyAction',
|
|
1891
|
+
model: 'Action',
|
|
1892
|
+
error: String(error),
|
|
1893
|
+
isRetryable: false,
|
|
1894
|
+
});
|
|
1895
|
+
}
|
|
1782
1896
|
throw error;
|
|
1783
1897
|
}
|
|
1784
1898
|
}
|
package/esm/Alert.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Alert.d.ts","sourceRoot":"","sources":["../../src/Alert.ts"],"names":[],"mappings":"AAEA,OA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