@adaptic/backend-legacy 0.0.918 → 0.0.920
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 +6 -5
- package/ABTest.d.ts +4 -1
- package/Account.cjs +6 -5
- package/Account.d.ts +4 -1
- package/AccountDecisionRecord.cjs +6 -5
- package/AccountDecisionRecord.d.ts +4 -1
- package/AccountLinkingRequest.cjs +6 -5
- package/AccountLinkingRequest.d.ts +4 -1
- package/Action.cjs +6 -5
- package/Action.d.ts +4 -1
- package/Alert.cjs +6 -5
- package/Alert.d.ts +4 -1
- package/Allocation.cjs +6 -5
- package/Allocation.d.ts +4 -1
- package/AlpacaAccount.cjs +6 -5
- package/AlpacaAccount.d.ts +4 -1
- package/AnalyticsConfiguration.cjs +6 -5
- package/AnalyticsConfiguration.d.ts +4 -1
- package/AnalyticsSnapshot.cjs +6 -5
- package/AnalyticsSnapshot.d.ts +4 -1
- package/Asset.cjs +6 -5
- package/Asset.d.ts +4 -1
- package/AuditLog.cjs +6 -5
- package/AuditLog.d.ts +4 -1
- package/Authenticator.cjs +6 -5
- package/Authenticator.d.ts +4 -1
- package/Configuration.cjs +6 -5
- package/Configuration.d.ts +4 -1
- package/ConflictEvent.cjs +6 -5
- package/ConflictEvent.d.ts +4 -1
- package/ConnectionHealthSnapshot.cjs +6 -5
- package/ConnectionHealthSnapshot.d.ts +4 -1
- package/Customer.cjs +6 -5
- package/Customer.d.ts +4 -1
- package/DeadLetterMessage.cjs +6 -5
- package/DeadLetterMessage.d.ts +4 -1
- package/DecisionMemorySummary.cjs +6 -5
- package/DecisionMemorySummary.d.ts +4 -1
- package/EconomicEvent.cjs +6 -5
- package/EconomicEvent.d.ts +4 -1
- package/EquityBar.cjs +6 -5
- package/EquityBar.d.ts +4 -1
- package/Event.cjs +6 -5
- package/Event.d.ts +4 -1
- package/EventSnapshot.cjs +6 -5
- package/EventSnapshot.d.ts +4 -1
- package/FeatureImportanceAnalysis.cjs +6 -5
- package/FeatureImportanceAnalysis.d.ts +4 -1
- package/InstitutionalFlowSignal.cjs +6 -5
- package/InstitutionalFlowSignal.d.ts +4 -1
- package/InstitutionalHolding.cjs +6 -5
- package/InstitutionalHolding.d.ts +4 -1
- package/InstitutionalSentimentAlerts.cjs +6 -5
- package/InstitutionalSentimentAlerts.d.ts +4 -1
- package/InstitutionalSentimentErrors.cjs +6 -5
- package/InstitutionalSentimentErrors.d.ts +4 -1
- package/InstitutionalSentimentHistory.cjs +6 -5
- package/InstitutionalSentimentHistory.d.ts +4 -1
- package/InstitutionalSentimentMetrics.cjs +6 -5
- package/InstitutionalSentimentMetrics.d.ts +4 -1
- package/InviteToken.cjs +6 -5
- package/InviteToken.d.ts +4 -1
- package/LinkedProvider.cjs +6 -5
- package/LinkedProvider.d.ts +4 -1
- package/LlmConfiguration.cjs +6 -5
- package/LlmConfiguration.d.ts +4 -1
- package/MLTrainingData.cjs +6 -5
- package/MLTrainingData.d.ts +4 -1
- package/MarketSentiment.cjs +6 -5
- package/MarketSentiment.d.ts +4 -1
- package/ModelArtifact.cjs +6 -5
- package/ModelArtifact.d.ts +4 -1
- package/ModelVersion.cjs +6 -5
- package/ModelVersion.d.ts +4 -1
- package/ModelVersionArtifact.cjs +6 -5
- package/ModelVersionArtifact.d.ts +4 -1
- package/NewsArticle.cjs +6 -5
- package/NewsArticle.d.ts +4 -1
- package/NewsArticleAssetSentiment.cjs +6 -5
- package/NewsArticleAssetSentiment.d.ts +4 -1
- package/OptionsContract.cjs +6 -5
- package/OptionsContract.d.ts +4 -1
- package/OptionsGreeksHistory.cjs +6 -5
- package/OptionsGreeksHistory.d.ts +4 -1
- package/OptionsPosition.cjs +6 -5
- package/OptionsPosition.d.ts +4 -1
- package/OptionsTradeExecution.cjs +6 -5
- package/OptionsTradeExecution.d.ts +4 -1
- package/PolicyOverlay.cjs +6 -5
- package/PolicyOverlay.d.ts +4 -1
- package/PortfolioGreeksHistory.cjs +6 -5
- package/PortfolioGreeksHistory.d.ts +4 -1
- package/ScheduledOptionOrder.cjs +6 -5
- package/ScheduledOptionOrder.d.ts +4 -1
- package/Session.cjs +6 -5
- package/Session.d.ts +4 -1
- package/SignalGeneratorMetrics.cjs +6 -5
- package/SignalGeneratorMetrics.d.ts +4 -1
- package/SignalLineage.cjs +6 -5
- package/SignalLineage.d.ts +4 -1
- package/SignalOutcome.cjs +6 -5
- package/SignalOutcome.d.ts +4 -1
- package/SignalPriorityQueue.cjs +6 -5
- package/SignalPriorityQueue.d.ts +4 -1
- package/SyncEvent.cjs +6 -5
- package/SyncEvent.d.ts +4 -1
- package/SystemAlert.cjs +6 -5
- package/SystemAlert.d.ts +4 -1
- package/Trade.cjs +6 -5
- package/Trade.d.ts +4 -1
- package/TradeAuditEvent.cjs +6 -5
- package/TradeAuditEvent.d.ts +4 -1
- package/TradeExecutionHistory.cjs +9 -5
- package/TradeExecutionHistory.d.ts +4 -1
- package/TradingPolicy.cjs +6 -5
- package/TradingPolicy.d.ts +4 -1
- package/User.cjs +6 -5
- package/User.d.ts +4 -1
- package/VerificationToken.cjs +6 -5
- package/VerificationToken.d.ts +4 -1
- package/WaitlistEntry.cjs +6 -5
- package/WaitlistEntry.d.ts +4 -1
- package/esm/ABTest.d.ts +4 -1
- package/esm/ABTest.d.ts.map +1 -1
- package/esm/ABTest.js.map +1 -1
- package/esm/ABTest.mjs +6 -5
- package/esm/Account.d.ts +4 -1
- package/esm/Account.d.ts.map +1 -1
- package/esm/Account.js.map +1 -1
- package/esm/Account.mjs +6 -5
- package/esm/AccountDecisionRecord.d.ts +4 -1
- package/esm/AccountDecisionRecord.d.ts.map +1 -1
- package/esm/AccountDecisionRecord.js.map +1 -1
- package/esm/AccountDecisionRecord.mjs +6 -5
- package/esm/AccountLinkingRequest.d.ts +4 -1
- package/esm/AccountLinkingRequest.d.ts.map +1 -1
- package/esm/AccountLinkingRequest.js.map +1 -1
- package/esm/AccountLinkingRequest.mjs +6 -5
- package/esm/Action.d.ts +4 -1
- package/esm/Action.d.ts.map +1 -1
- package/esm/Action.js.map +1 -1
- package/esm/Action.mjs +6 -5
- package/esm/Alert.d.ts +4 -1
- package/esm/Alert.d.ts.map +1 -1
- package/esm/Alert.js.map +1 -1
- package/esm/Alert.mjs +6 -5
- package/esm/Allocation.d.ts +4 -1
- package/esm/Allocation.d.ts.map +1 -1
- package/esm/Allocation.js.map +1 -1
- package/esm/Allocation.mjs +6 -5
- package/esm/AlpacaAccount.d.ts +4 -1
- package/esm/AlpacaAccount.d.ts.map +1 -1
- package/esm/AlpacaAccount.js.map +1 -1
- package/esm/AlpacaAccount.mjs +6 -5
- package/esm/AnalyticsConfiguration.d.ts +4 -1
- package/esm/AnalyticsConfiguration.d.ts.map +1 -1
- package/esm/AnalyticsConfiguration.js.map +1 -1
- package/esm/AnalyticsConfiguration.mjs +6 -5
- package/esm/AnalyticsSnapshot.d.ts +4 -1
- package/esm/AnalyticsSnapshot.d.ts.map +1 -1
- package/esm/AnalyticsSnapshot.js.map +1 -1
- package/esm/AnalyticsSnapshot.mjs +6 -5
- package/esm/Asset.d.ts +4 -1
- package/esm/Asset.d.ts.map +1 -1
- package/esm/Asset.js.map +1 -1
- package/esm/Asset.mjs +6 -5
- package/esm/AuditLog.d.ts +4 -1
- package/esm/AuditLog.d.ts.map +1 -1
- package/esm/AuditLog.js.map +1 -1
- package/esm/AuditLog.mjs +6 -5
- package/esm/Authenticator.d.ts +4 -1
- package/esm/Authenticator.d.ts.map +1 -1
- package/esm/Authenticator.js.map +1 -1
- package/esm/Authenticator.mjs +6 -5
- package/esm/Configuration.d.ts +4 -1
- package/esm/Configuration.d.ts.map +1 -1
- package/esm/Configuration.js.map +1 -1
- package/esm/Configuration.mjs +6 -5
- package/esm/ConflictEvent.d.ts +4 -1
- package/esm/ConflictEvent.d.ts.map +1 -1
- package/esm/ConflictEvent.js.map +1 -1
- package/esm/ConflictEvent.mjs +6 -5
- package/esm/ConnectionHealthSnapshot.d.ts +4 -1
- package/esm/ConnectionHealthSnapshot.d.ts.map +1 -1
- package/esm/ConnectionHealthSnapshot.js.map +1 -1
- package/esm/ConnectionHealthSnapshot.mjs +6 -5
- package/esm/Customer.d.ts +4 -1
- package/esm/Customer.d.ts.map +1 -1
- package/esm/Customer.js.map +1 -1
- package/esm/Customer.mjs +6 -5
- package/esm/DeadLetterMessage.d.ts +4 -1
- package/esm/DeadLetterMessage.d.ts.map +1 -1
- package/esm/DeadLetterMessage.js.map +1 -1
- package/esm/DeadLetterMessage.mjs +6 -5
- package/esm/DecisionMemorySummary.d.ts +4 -1
- package/esm/DecisionMemorySummary.d.ts.map +1 -1
- package/esm/DecisionMemorySummary.js.map +1 -1
- package/esm/DecisionMemorySummary.mjs +6 -5
- package/esm/EconomicEvent.d.ts +4 -1
- package/esm/EconomicEvent.d.ts.map +1 -1
- package/esm/EconomicEvent.js.map +1 -1
- package/esm/EconomicEvent.mjs +6 -5
- package/esm/EquityBar.d.ts +4 -1
- package/esm/EquityBar.d.ts.map +1 -1
- package/esm/EquityBar.js.map +1 -1
- package/esm/EquityBar.mjs +6 -5
- package/esm/Event.d.ts +4 -1
- package/esm/Event.d.ts.map +1 -1
- package/esm/Event.js.map +1 -1
- package/esm/Event.mjs +6 -5
- package/esm/EventSnapshot.d.ts +4 -1
- package/esm/EventSnapshot.d.ts.map +1 -1
- package/esm/EventSnapshot.js.map +1 -1
- package/esm/EventSnapshot.mjs +6 -5
- package/esm/FeatureImportanceAnalysis.d.ts +4 -1
- package/esm/FeatureImportanceAnalysis.d.ts.map +1 -1
- package/esm/FeatureImportanceAnalysis.js.map +1 -1
- package/esm/FeatureImportanceAnalysis.mjs +6 -5
- package/esm/InstitutionalFlowSignal.d.ts +4 -1
- package/esm/InstitutionalFlowSignal.d.ts.map +1 -1
- package/esm/InstitutionalFlowSignal.js.map +1 -1
- package/esm/InstitutionalFlowSignal.mjs +6 -5
- package/esm/InstitutionalHolding.d.ts +4 -1
- package/esm/InstitutionalHolding.d.ts.map +1 -1
- package/esm/InstitutionalHolding.js.map +1 -1
- package/esm/InstitutionalHolding.mjs +6 -5
- package/esm/InstitutionalSentimentAlerts.d.ts +4 -1
- package/esm/InstitutionalSentimentAlerts.d.ts.map +1 -1
- package/esm/InstitutionalSentimentAlerts.js.map +1 -1
- package/esm/InstitutionalSentimentAlerts.mjs +6 -5
- package/esm/InstitutionalSentimentErrors.d.ts +4 -1
- package/esm/InstitutionalSentimentErrors.d.ts.map +1 -1
- package/esm/InstitutionalSentimentErrors.js.map +1 -1
- package/esm/InstitutionalSentimentErrors.mjs +6 -5
- package/esm/InstitutionalSentimentHistory.d.ts +4 -1
- package/esm/InstitutionalSentimentHistory.d.ts.map +1 -1
- package/esm/InstitutionalSentimentHistory.js.map +1 -1
- package/esm/InstitutionalSentimentHistory.mjs +6 -5
- package/esm/InstitutionalSentimentMetrics.d.ts +4 -1
- package/esm/InstitutionalSentimentMetrics.d.ts.map +1 -1
- package/esm/InstitutionalSentimentMetrics.js.map +1 -1
- package/esm/InstitutionalSentimentMetrics.mjs +6 -5
- package/esm/InviteToken.d.ts +4 -1
- package/esm/InviteToken.d.ts.map +1 -1
- package/esm/InviteToken.js.map +1 -1
- package/esm/InviteToken.mjs +6 -5
- package/esm/LinkedProvider.d.ts +4 -1
- package/esm/LinkedProvider.d.ts.map +1 -1
- package/esm/LinkedProvider.js.map +1 -1
- package/esm/LinkedProvider.mjs +6 -5
- package/esm/LlmConfiguration.d.ts +4 -1
- package/esm/LlmConfiguration.d.ts.map +1 -1
- package/esm/LlmConfiguration.js.map +1 -1
- package/esm/LlmConfiguration.mjs +6 -5
- package/esm/MLTrainingData.d.ts +4 -1
- package/esm/MLTrainingData.d.ts.map +1 -1
- package/esm/MLTrainingData.js.map +1 -1
- package/esm/MLTrainingData.mjs +6 -5
- package/esm/MarketSentiment.d.ts +4 -1
- package/esm/MarketSentiment.d.ts.map +1 -1
- package/esm/MarketSentiment.js.map +1 -1
- package/esm/MarketSentiment.mjs +6 -5
- package/esm/ModelArtifact.d.ts +4 -1
- package/esm/ModelArtifact.d.ts.map +1 -1
- package/esm/ModelArtifact.js.map +1 -1
- package/esm/ModelArtifact.mjs +6 -5
- package/esm/ModelVersion.d.ts +4 -1
- package/esm/ModelVersion.d.ts.map +1 -1
- package/esm/ModelVersion.js.map +1 -1
- package/esm/ModelVersion.mjs +6 -5
- package/esm/ModelVersionArtifact.d.ts +4 -1
- package/esm/ModelVersionArtifact.d.ts.map +1 -1
- package/esm/ModelVersionArtifact.js.map +1 -1
- package/esm/ModelVersionArtifact.mjs +6 -5
- package/esm/NewsArticle.d.ts +4 -1
- package/esm/NewsArticle.d.ts.map +1 -1
- package/esm/NewsArticle.js.map +1 -1
- package/esm/NewsArticle.mjs +6 -5
- package/esm/NewsArticleAssetSentiment.d.ts +4 -1
- package/esm/NewsArticleAssetSentiment.d.ts.map +1 -1
- package/esm/NewsArticleAssetSentiment.js.map +1 -1
- package/esm/NewsArticleAssetSentiment.mjs +6 -5
- package/esm/OptionsContract.d.ts +4 -1
- package/esm/OptionsContract.d.ts.map +1 -1
- package/esm/OptionsContract.js.map +1 -1
- package/esm/OptionsContract.mjs +6 -5
- package/esm/OptionsGreeksHistory.d.ts +4 -1
- package/esm/OptionsGreeksHistory.d.ts.map +1 -1
- package/esm/OptionsGreeksHistory.js.map +1 -1
- package/esm/OptionsGreeksHistory.mjs +6 -5
- package/esm/OptionsPosition.d.ts +4 -1
- package/esm/OptionsPosition.d.ts.map +1 -1
- package/esm/OptionsPosition.js.map +1 -1
- package/esm/OptionsPosition.mjs +6 -5
- package/esm/OptionsTradeExecution.d.ts +4 -1
- package/esm/OptionsTradeExecution.d.ts.map +1 -1
- package/esm/OptionsTradeExecution.js.map +1 -1
- package/esm/OptionsTradeExecution.mjs +6 -5
- package/esm/PolicyOverlay.d.ts +4 -1
- package/esm/PolicyOverlay.d.ts.map +1 -1
- package/esm/PolicyOverlay.js.map +1 -1
- package/esm/PolicyOverlay.mjs +6 -5
- package/esm/PortfolioGreeksHistory.d.ts +4 -1
- package/esm/PortfolioGreeksHistory.d.ts.map +1 -1
- package/esm/PortfolioGreeksHistory.js.map +1 -1
- package/esm/PortfolioGreeksHistory.mjs +6 -5
- package/esm/ScheduledOptionOrder.d.ts +4 -1
- package/esm/ScheduledOptionOrder.d.ts.map +1 -1
- package/esm/ScheduledOptionOrder.js.map +1 -1
- package/esm/ScheduledOptionOrder.mjs +6 -5
- package/esm/Session.d.ts +4 -1
- package/esm/Session.d.ts.map +1 -1
- package/esm/Session.js.map +1 -1
- package/esm/Session.mjs +6 -5
- package/esm/SignalGeneratorMetrics.d.ts +4 -1
- package/esm/SignalGeneratorMetrics.d.ts.map +1 -1
- package/esm/SignalGeneratorMetrics.js.map +1 -1
- package/esm/SignalGeneratorMetrics.mjs +6 -5
- package/esm/SignalLineage.d.ts +4 -1
- package/esm/SignalLineage.d.ts.map +1 -1
- package/esm/SignalLineage.js.map +1 -1
- package/esm/SignalLineage.mjs +6 -5
- package/esm/SignalOutcome.d.ts +4 -1
- package/esm/SignalOutcome.d.ts.map +1 -1
- package/esm/SignalOutcome.js.map +1 -1
- package/esm/SignalOutcome.mjs +6 -5
- package/esm/SignalPriorityQueue.d.ts +4 -1
- package/esm/SignalPriorityQueue.d.ts.map +1 -1
- package/esm/SignalPriorityQueue.js.map +1 -1
- package/esm/SignalPriorityQueue.mjs +6 -5
- package/esm/SyncEvent.d.ts +4 -1
- package/esm/SyncEvent.d.ts.map +1 -1
- package/esm/SyncEvent.js.map +1 -1
- package/esm/SyncEvent.mjs +6 -5
- package/esm/SystemAlert.d.ts +4 -1
- package/esm/SystemAlert.d.ts.map +1 -1
- package/esm/SystemAlert.js.map +1 -1
- package/esm/SystemAlert.mjs +6 -5
- package/esm/Trade.d.ts +4 -1
- package/esm/Trade.d.ts.map +1 -1
- package/esm/Trade.js.map +1 -1
- package/esm/Trade.mjs +6 -5
- package/esm/TradeAuditEvent.d.ts +4 -1
- package/esm/TradeAuditEvent.d.ts.map +1 -1
- package/esm/TradeAuditEvent.js.map +1 -1
- package/esm/TradeAuditEvent.mjs +6 -5
- package/esm/TradeExecutionHistory.d.ts +4 -1
- package/esm/TradeExecutionHistory.d.ts.map +1 -1
- package/esm/TradeExecutionHistory.js.map +1 -1
- package/esm/TradeExecutionHistory.mjs +9 -5
- package/esm/TradingPolicy.d.ts +4 -1
- package/esm/TradingPolicy.d.ts.map +1 -1
- package/esm/TradingPolicy.js.map +1 -1
- package/esm/TradingPolicy.mjs +6 -5
- package/esm/User.d.ts +4 -1
- package/esm/User.d.ts.map +1 -1
- package/esm/User.js.map +1 -1
- package/esm/User.mjs +6 -5
- package/esm/VerificationToken.d.ts +4 -1
- package/esm/VerificationToken.d.ts.map +1 -1
- package/esm/VerificationToken.js.map +1 -1
- package/esm/VerificationToken.mjs +6 -5
- package/esm/WaitlistEntry.d.ts +4 -1
- package/esm/WaitlistEntry.d.ts.map +1 -1
- package/esm/WaitlistEntry.js.map +1 -1
- package/esm/WaitlistEntry.mjs +6 -5
- package/esm/index.d.ts +183 -61
- package/esm/index.d.ts.map +1 -1
- package/index.d.ts +183 -61
- package/package.json +1 -1
package/Event.cjs
CHANGED
|
@@ -174,9 +174,10 @@ exports.Event = {
|
|
|
174
174
|
* Enhanced with connection resilience against Prisma connection errors.
|
|
175
175
|
* @param props - Array of Event objects for the new records.
|
|
176
176
|
* @param globalClient - Apollo Client instance.
|
|
177
|
+
* @param options - Optional control flags (e.g., skipDuplicates).
|
|
177
178
|
* @returns The count of created records or null.
|
|
178
179
|
*/
|
|
179
|
-
async createMany(props, globalClient) {
|
|
180
|
+
async createMany(props, globalClient, options) {
|
|
180
181
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
|
|
181
182
|
// Maximum number of retries for database connection issues
|
|
182
183
|
const MAX_RETRIES = 3;
|
|
@@ -193,8 +194,8 @@ exports.Event = {
|
|
|
193
194
|
]);
|
|
194
195
|
const { gql, ApolloError } = modules;
|
|
195
196
|
const CREATE_MANY_EVENT = gql `
|
|
196
|
-
mutation createManyEvent($data: [EventCreateManyInput!]
|
|
197
|
-
createManyEvent(data: $data) {
|
|
197
|
+
mutation createManyEvent($data: [EventCreateManyInput!]!, $skipDuplicates: Boolean) {
|
|
198
|
+
createManyEvent(data: $data, skipDuplicates: $skipDuplicates) {
|
|
198
199
|
count
|
|
199
200
|
}
|
|
200
201
|
}`;
|
|
@@ -223,6 +224,7 @@ exports.Event = {
|
|
|
223
224
|
archived: prop.archived !== undefined ? prop.archived : undefined,
|
|
224
225
|
tags: prop.tags !== undefined ? prop.tags : undefined,
|
|
225
226
|
})),
|
|
227
|
+
...((options === null || options === void 0 ? void 0 : options.skipDuplicates) ? { skipDuplicates: true } : {}),
|
|
226
228
|
};
|
|
227
229
|
const filteredVariables = (0, utils_1.removeUndefinedProps)(variables);
|
|
228
230
|
const response = await client.mutate({
|
|
@@ -253,10 +255,9 @@ exports.Event = {
|
|
|
253
255
|
((_h = error.message) === null || _h === void 0 ? void 0 : _h.includes('P2003'));
|
|
254
256
|
if (isConstraintViolation) {
|
|
255
257
|
const constraintMatch = (_j = error.message) === null || _j === void 0 ? void 0 : _j.match(/constraint\s+"([^"]+)"/);
|
|
256
|
-
logger_1.logger.
|
|
258
|
+
logger_1.logger.warn("Duplicate key in createManyEvent (expected during overlapping fetches)", {
|
|
257
259
|
operation: 'createManyEvent',
|
|
258
260
|
model: 'Event',
|
|
259
|
-
error: String(error),
|
|
260
261
|
constraintName: constraintMatch ? constraintMatch[1] : undefined,
|
|
261
262
|
errorCategory: 'CONSTRAINT_VIOLATION',
|
|
262
263
|
isRetryable: false,
|
package/Event.d.ts
CHANGED
|
@@ -20,9 +20,12 @@ export declare const Event: {
|
|
|
20
20
|
* Enhanced with connection resilience against Prisma connection errors.
|
|
21
21
|
* @param props - Array of Event objects for the new records.
|
|
22
22
|
* @param globalClient - Apollo Client instance.
|
|
23
|
+
* @param options - Optional control flags (e.g., skipDuplicates).
|
|
23
24
|
* @returns The count of created records or null.
|
|
24
25
|
*/
|
|
25
|
-
createMany(props: EventType[], globalClient?: ApolloClientType<NormalizedCacheObject
|
|
26
|
+
createMany(props: EventType[], globalClient?: ApolloClientType<NormalizedCacheObject>, options?: {
|
|
27
|
+
skipDuplicates?: boolean;
|
|
28
|
+
}): Promise<{
|
|
26
29
|
count: number;
|
|
27
30
|
} | null>;
|
|
28
31
|
/**
|
package/EventSnapshot.cjs
CHANGED
|
@@ -140,9 +140,10 @@ exports.EventSnapshot = {
|
|
|
140
140
|
* Enhanced with connection resilience against Prisma connection errors.
|
|
141
141
|
* @param props - Array of EventSnapshot objects for the new records.
|
|
142
142
|
* @param globalClient - Apollo Client instance.
|
|
143
|
+
* @param options - Optional control flags (e.g., skipDuplicates).
|
|
143
144
|
* @returns The count of created records or null.
|
|
144
145
|
*/
|
|
145
|
-
async createMany(props, globalClient) {
|
|
146
|
+
async createMany(props, globalClient, options) {
|
|
146
147
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
|
|
147
148
|
// Maximum number of retries for database connection issues
|
|
148
149
|
const MAX_RETRIES = 3;
|
|
@@ -159,8 +160,8 @@ exports.EventSnapshot = {
|
|
|
159
160
|
]);
|
|
160
161
|
const { gql, ApolloError } = modules;
|
|
161
162
|
const CREATE_MANY_EVENTSNAPSHOT = gql `
|
|
162
|
-
mutation createManyEventSnapshot($data: [EventSnapshotCreateManyInput!]
|
|
163
|
-
createManyEventSnapshot(data: $data) {
|
|
163
|
+
mutation createManyEventSnapshot($data: [EventSnapshotCreateManyInput!]!, $skipDuplicates: Boolean) {
|
|
164
|
+
createManyEventSnapshot(data: $data, skipDuplicates: $skipDuplicates) {
|
|
164
165
|
count
|
|
165
166
|
}
|
|
166
167
|
}`;
|
|
@@ -172,6 +173,7 @@ exports.EventSnapshot = {
|
|
|
172
173
|
state: prop.state !== undefined ? prop.state : undefined,
|
|
173
174
|
timestamp: prop.timestamp !== undefined ? prop.timestamp : undefined,
|
|
174
175
|
})),
|
|
176
|
+
...((options === null || options === void 0 ? void 0 : options.skipDuplicates) ? { skipDuplicates: true } : {}),
|
|
175
177
|
};
|
|
176
178
|
const filteredVariables = (0, utils_1.removeUndefinedProps)(variables);
|
|
177
179
|
const response = await client.mutate({
|
|
@@ -202,10 +204,9 @@ exports.EventSnapshot = {
|
|
|
202
204
|
((_h = error.message) === null || _h === void 0 ? void 0 : _h.includes('P2003'));
|
|
203
205
|
if (isConstraintViolation) {
|
|
204
206
|
const constraintMatch = (_j = error.message) === null || _j === void 0 ? void 0 : _j.match(/constraint\s+"([^"]+)"/);
|
|
205
|
-
logger_1.logger.
|
|
207
|
+
logger_1.logger.warn("Duplicate key in createManyEventSnapshot (expected during overlapping fetches)", {
|
|
206
208
|
operation: 'createManyEventSnapshot',
|
|
207
209
|
model: 'EventSnapshot',
|
|
208
|
-
error: String(error),
|
|
209
210
|
constraintName: constraintMatch ? constraintMatch[1] : undefined,
|
|
210
211
|
errorCategory: 'CONSTRAINT_VIOLATION',
|
|
211
212
|
isRetryable: false,
|
package/EventSnapshot.d.ts
CHANGED
|
@@ -20,9 +20,12 @@ export declare const EventSnapshot: {
|
|
|
20
20
|
* Enhanced with connection resilience against Prisma connection errors.
|
|
21
21
|
* @param props - Array of EventSnapshot objects for the new records.
|
|
22
22
|
* @param globalClient - Apollo Client instance.
|
|
23
|
+
* @param options - Optional control flags (e.g., skipDuplicates).
|
|
23
24
|
* @returns The count of created records or null.
|
|
24
25
|
*/
|
|
25
|
-
createMany(props: EventSnapshotType[], globalClient?: ApolloClientType<NormalizedCacheObject
|
|
26
|
+
createMany(props: EventSnapshotType[], globalClient?: ApolloClientType<NormalizedCacheObject>, options?: {
|
|
27
|
+
skipDuplicates?: boolean;
|
|
28
|
+
}): Promise<{
|
|
26
29
|
count: number;
|
|
27
30
|
} | null>;
|
|
28
31
|
/**
|
|
@@ -1027,9 +1027,10 @@ exports.FeatureImportanceAnalysis = {
|
|
|
1027
1027
|
* Enhanced with connection resilience against Prisma connection errors.
|
|
1028
1028
|
* @param props - Array of FeatureImportanceAnalysis objects for the new records.
|
|
1029
1029
|
* @param globalClient - Apollo Client instance.
|
|
1030
|
+
* @param options - Optional control flags (e.g., skipDuplicates).
|
|
1030
1031
|
* @returns The count of created records or null.
|
|
1031
1032
|
*/
|
|
1032
|
-
async createMany(props, globalClient) {
|
|
1033
|
+
async createMany(props, globalClient, options) {
|
|
1033
1034
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
|
|
1034
1035
|
// Maximum number of retries for database connection issues
|
|
1035
1036
|
const MAX_RETRIES = 3;
|
|
@@ -1046,8 +1047,8 @@ exports.FeatureImportanceAnalysis = {
|
|
|
1046
1047
|
]);
|
|
1047
1048
|
const { gql, ApolloError } = modules;
|
|
1048
1049
|
const CREATE_MANY_FEATUREIMPORTANCEANALYSIS = gql `
|
|
1049
|
-
mutation createManyFeatureImportanceAnalysis($data: [FeatureImportanceAnalysisCreateManyInput!]
|
|
1050
|
-
createManyFeatureImportanceAnalysis(data: $data) {
|
|
1050
|
+
mutation createManyFeatureImportanceAnalysis($data: [FeatureImportanceAnalysisCreateManyInput!]!, $skipDuplicates: Boolean) {
|
|
1051
|
+
createManyFeatureImportanceAnalysis(data: $data, skipDuplicates: $skipDuplicates) {
|
|
1051
1052
|
count
|
|
1052
1053
|
}
|
|
1053
1054
|
}`;
|
|
@@ -1069,6 +1070,7 @@ exports.FeatureImportanceAnalysis = {
|
|
|
1069
1070
|
insightsStabilityScore: prop.insightsStabilityScore !== undefined ? prop.insightsStabilityScore : undefined,
|
|
1070
1071
|
insightsRecommendations: prop.insightsRecommendations !== undefined ? prop.insightsRecommendations : undefined,
|
|
1071
1072
|
})),
|
|
1073
|
+
...((options === null || options === void 0 ? void 0 : options.skipDuplicates) ? { skipDuplicates: true } : {}),
|
|
1072
1074
|
};
|
|
1073
1075
|
const filteredVariables = (0, utils_1.removeUndefinedProps)(variables);
|
|
1074
1076
|
const response = await client.mutate({
|
|
@@ -1099,10 +1101,9 @@ exports.FeatureImportanceAnalysis = {
|
|
|
1099
1101
|
((_h = error.message) === null || _h === void 0 ? void 0 : _h.includes('P2003'));
|
|
1100
1102
|
if (isConstraintViolation) {
|
|
1101
1103
|
const constraintMatch = (_j = error.message) === null || _j === void 0 ? void 0 : _j.match(/constraint\s+"([^"]+)"/);
|
|
1102
|
-
logger_1.logger.
|
|
1104
|
+
logger_1.logger.warn("Duplicate key in createManyFeatureImportanceAnalysis (expected during overlapping fetches)", {
|
|
1103
1105
|
operation: 'createManyFeatureImportanceAnalysis',
|
|
1104
1106
|
model: 'FeatureImportanceAnalysis',
|
|
1105
|
-
error: String(error),
|
|
1106
1107
|
constraintName: constraintMatch ? constraintMatch[1] : undefined,
|
|
1107
1108
|
errorCategory: 'CONSTRAINT_VIOLATION',
|
|
1108
1109
|
isRetryable: false,
|
|
@@ -20,9 +20,12 @@ export declare const FeatureImportanceAnalysis: {
|
|
|
20
20
|
* Enhanced with connection resilience against Prisma connection errors.
|
|
21
21
|
* @param props - Array of FeatureImportanceAnalysis objects for the new records.
|
|
22
22
|
* @param globalClient - Apollo Client instance.
|
|
23
|
+
* @param options - Optional control flags (e.g., skipDuplicates).
|
|
23
24
|
* @returns The count of created records or null.
|
|
24
25
|
*/
|
|
25
|
-
createMany(props: FeatureImportanceAnalysisType[], globalClient?: ApolloClientType<NormalizedCacheObject
|
|
26
|
+
createMany(props: FeatureImportanceAnalysisType[], globalClient?: ApolloClientType<NormalizedCacheObject>, options?: {
|
|
27
|
+
skipDuplicates?: boolean;
|
|
28
|
+
}): Promise<{
|
|
26
29
|
count: number;
|
|
27
30
|
} | null>;
|
|
28
31
|
/**
|
|
@@ -353,9 +353,10 @@ exports.InstitutionalFlowSignal = {
|
|
|
353
353
|
* Enhanced with connection resilience against Prisma connection errors.
|
|
354
354
|
* @param props - Array of InstitutionalFlowSignal objects for the new records.
|
|
355
355
|
* @param globalClient - Apollo Client instance.
|
|
356
|
+
* @param options - Optional control flags (e.g., skipDuplicates).
|
|
356
357
|
* @returns The count of created records or null.
|
|
357
358
|
*/
|
|
358
|
-
async createMany(props, globalClient) {
|
|
359
|
+
async createMany(props, globalClient, options) {
|
|
359
360
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
|
|
360
361
|
// Maximum number of retries for database connection issues
|
|
361
362
|
const MAX_RETRIES = 3;
|
|
@@ -372,8 +373,8 @@ exports.InstitutionalFlowSignal = {
|
|
|
372
373
|
]);
|
|
373
374
|
const { gql, ApolloError } = modules;
|
|
374
375
|
const CREATE_MANY_INSTITUTIONALFLOWSIGNAL = gql `
|
|
375
|
-
mutation createManyInstitutionalFlowSignal($data: [InstitutionalFlowSignalCreateManyInput!]
|
|
376
|
-
createManyInstitutionalFlowSignal(data: $data) {
|
|
376
|
+
mutation createManyInstitutionalFlowSignal($data: [InstitutionalFlowSignalCreateManyInput!]!, $skipDuplicates: Boolean) {
|
|
377
|
+
createManyInstitutionalFlowSignal(data: $data, skipDuplicates: $skipDuplicates) {
|
|
377
378
|
count
|
|
378
379
|
}
|
|
379
380
|
}`;
|
|
@@ -384,6 +385,7 @@ exports.InstitutionalFlowSignal = {
|
|
|
384
385
|
signalType: prop.signalType !== undefined ? prop.signalType : undefined,
|
|
385
386
|
metadata: prop.metadata !== undefined ? prop.metadata : undefined,
|
|
386
387
|
})),
|
|
388
|
+
...((options === null || options === void 0 ? void 0 : options.skipDuplicates) ? { skipDuplicates: true } : {}),
|
|
387
389
|
};
|
|
388
390
|
const filteredVariables = (0, utils_1.removeUndefinedProps)(variables);
|
|
389
391
|
const response = await client.mutate({
|
|
@@ -414,10 +416,9 @@ exports.InstitutionalFlowSignal = {
|
|
|
414
416
|
((_h = error.message) === null || _h === void 0 ? void 0 : _h.includes('P2003'));
|
|
415
417
|
if (isConstraintViolation) {
|
|
416
418
|
const constraintMatch = (_j = error.message) === null || _j === void 0 ? void 0 : _j.match(/constraint\s+"([^"]+)"/);
|
|
417
|
-
logger_1.logger.
|
|
419
|
+
logger_1.logger.warn("Duplicate key in createManyInstitutionalFlowSignal (expected during overlapping fetches)", {
|
|
418
420
|
operation: 'createManyInstitutionalFlowSignal',
|
|
419
421
|
model: 'InstitutionalFlowSignal',
|
|
420
|
-
error: String(error),
|
|
421
422
|
constraintName: constraintMatch ? constraintMatch[1] : undefined,
|
|
422
423
|
errorCategory: 'CONSTRAINT_VIOLATION',
|
|
423
424
|
isRetryable: false,
|
|
@@ -20,9 +20,12 @@ export declare const InstitutionalFlowSignal: {
|
|
|
20
20
|
* Enhanced with connection resilience against Prisma connection errors.
|
|
21
21
|
* @param props - Array of InstitutionalFlowSignal objects for the new records.
|
|
22
22
|
* @param globalClient - Apollo Client instance.
|
|
23
|
+
* @param options - Optional control flags (e.g., skipDuplicates).
|
|
23
24
|
* @returns The count of created records or null.
|
|
24
25
|
*/
|
|
25
|
-
createMany(props: InstitutionalFlowSignalType[], globalClient?: ApolloClientType<NormalizedCacheObject
|
|
26
|
+
createMany(props: InstitutionalFlowSignalType[], globalClient?: ApolloClientType<NormalizedCacheObject>, options?: {
|
|
27
|
+
skipDuplicates?: boolean;
|
|
28
|
+
}): Promise<{
|
|
26
29
|
count: number;
|
|
27
30
|
} | null>;
|
|
28
31
|
/**
|
package/InstitutionalHolding.cjs
CHANGED
|
@@ -357,9 +357,10 @@ exports.InstitutionalHolding = {
|
|
|
357
357
|
* Enhanced with connection resilience against Prisma connection errors.
|
|
358
358
|
* @param props - Array of InstitutionalHolding objects for the new records.
|
|
359
359
|
* @param globalClient - Apollo Client instance.
|
|
360
|
+
* @param options - Optional control flags (e.g., skipDuplicates).
|
|
360
361
|
* @returns The count of created records or null.
|
|
361
362
|
*/
|
|
362
|
-
async createMany(props, globalClient) {
|
|
363
|
+
async createMany(props, globalClient, options) {
|
|
363
364
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
|
|
364
365
|
// Maximum number of retries for database connection issues
|
|
365
366
|
const MAX_RETRIES = 3;
|
|
@@ -376,8 +377,8 @@ exports.InstitutionalHolding = {
|
|
|
376
377
|
]);
|
|
377
378
|
const { gql, ApolloError } = modules;
|
|
378
379
|
const CREATE_MANY_INSTITUTIONALHOLDING = gql `
|
|
379
|
-
mutation createManyInstitutionalHolding($data: [InstitutionalHoldingCreateManyInput!]
|
|
380
|
-
createManyInstitutionalHolding(data: $data) {
|
|
380
|
+
mutation createManyInstitutionalHolding($data: [InstitutionalHoldingCreateManyInput!]!, $skipDuplicates: Boolean) {
|
|
381
|
+
createManyInstitutionalHolding(data: $data, skipDuplicates: $skipDuplicates) {
|
|
381
382
|
count
|
|
382
383
|
}
|
|
383
384
|
}`;
|
|
@@ -391,6 +392,7 @@ exports.InstitutionalHolding = {
|
|
|
391
392
|
changeShares: prop.changeShares !== undefined ? prop.changeShares : undefined,
|
|
392
393
|
metadata: prop.metadata !== undefined ? prop.metadata : undefined,
|
|
393
394
|
})),
|
|
395
|
+
...((options === null || options === void 0 ? void 0 : options.skipDuplicates) ? { skipDuplicates: true } : {}),
|
|
394
396
|
};
|
|
395
397
|
const filteredVariables = (0, utils_1.removeUndefinedProps)(variables);
|
|
396
398
|
const response = await client.mutate({
|
|
@@ -421,10 +423,9 @@ exports.InstitutionalHolding = {
|
|
|
421
423
|
((_h = error.message) === null || _h === void 0 ? void 0 : _h.includes('P2003'));
|
|
422
424
|
if (isConstraintViolation) {
|
|
423
425
|
const constraintMatch = (_j = error.message) === null || _j === void 0 ? void 0 : _j.match(/constraint\s+"([^"]+)"/);
|
|
424
|
-
logger_1.logger.
|
|
426
|
+
logger_1.logger.warn("Duplicate key in createManyInstitutionalHolding (expected during overlapping fetches)", {
|
|
425
427
|
operation: 'createManyInstitutionalHolding',
|
|
426
428
|
model: 'InstitutionalHolding',
|
|
427
|
-
error: String(error),
|
|
428
429
|
constraintName: constraintMatch ? constraintMatch[1] : undefined,
|
|
429
430
|
errorCategory: 'CONSTRAINT_VIOLATION',
|
|
430
431
|
isRetryable: false,
|
|
@@ -20,9 +20,12 @@ export declare const InstitutionalHolding: {
|
|
|
20
20
|
* Enhanced with connection resilience against Prisma connection errors.
|
|
21
21
|
* @param props - Array of InstitutionalHolding objects for the new records.
|
|
22
22
|
* @param globalClient - Apollo Client instance.
|
|
23
|
+
* @param options - Optional control flags (e.g., skipDuplicates).
|
|
23
24
|
* @returns The count of created records or null.
|
|
24
25
|
*/
|
|
25
|
-
createMany(props: InstitutionalHoldingType[], globalClient?: ApolloClientType<NormalizedCacheObject
|
|
26
|
+
createMany(props: InstitutionalHoldingType[], globalClient?: ApolloClientType<NormalizedCacheObject>, options?: {
|
|
27
|
+
skipDuplicates?: boolean;
|
|
28
|
+
}): Promise<{
|
|
26
29
|
count: number;
|
|
27
30
|
} | null>;
|
|
28
31
|
/**
|
|
@@ -148,9 +148,10 @@ exports.InstitutionalSentimentAlerts = {
|
|
|
148
148
|
* Enhanced with connection resilience against Prisma connection errors.
|
|
149
149
|
* @param props - Array of InstitutionalSentimentAlerts objects for the new records.
|
|
150
150
|
* @param globalClient - Apollo Client instance.
|
|
151
|
+
* @param options - Optional control flags (e.g., skipDuplicates).
|
|
151
152
|
* @returns The count of created records or null.
|
|
152
153
|
*/
|
|
153
|
-
async createMany(props, globalClient) {
|
|
154
|
+
async createMany(props, globalClient, options) {
|
|
154
155
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
|
|
155
156
|
// Maximum number of retries for database connection issues
|
|
156
157
|
const MAX_RETRIES = 3;
|
|
@@ -167,8 +168,8 @@ exports.InstitutionalSentimentAlerts = {
|
|
|
167
168
|
]);
|
|
168
169
|
const { gql, ApolloError } = modules;
|
|
169
170
|
const CREATE_MANY_INSTITUTIONALSENTIMENTALERTS = gql `
|
|
170
|
-
mutation createManyInstitutionalSentimentAlerts($data: [InstitutionalSentimentAlertsCreateManyInput!]
|
|
171
|
-
createManyInstitutionalSentimentAlerts(data: $data) {
|
|
171
|
+
mutation createManyInstitutionalSentimentAlerts($data: [InstitutionalSentimentAlertsCreateManyInput!]!, $skipDuplicates: Boolean) {
|
|
172
|
+
createManyInstitutionalSentimentAlerts(data: $data, skipDuplicates: $skipDuplicates) {
|
|
172
173
|
count
|
|
173
174
|
}
|
|
174
175
|
}`;
|
|
@@ -184,6 +185,7 @@ exports.InstitutionalSentimentAlerts = {
|
|
|
184
185
|
resolvedAt: prop.resolvedAt !== undefined ? prop.resolvedAt : undefined,
|
|
185
186
|
resolvedBy: prop.resolvedBy !== undefined ? prop.resolvedBy : undefined,
|
|
186
187
|
})),
|
|
188
|
+
...((options === null || options === void 0 ? void 0 : options.skipDuplicates) ? { skipDuplicates: true } : {}),
|
|
187
189
|
};
|
|
188
190
|
const filteredVariables = (0, utils_1.removeUndefinedProps)(variables);
|
|
189
191
|
const response = await client.mutate({
|
|
@@ -214,10 +216,9 @@ exports.InstitutionalSentimentAlerts = {
|
|
|
214
216
|
((_h = error.message) === null || _h === void 0 ? void 0 : _h.includes('P2003'));
|
|
215
217
|
if (isConstraintViolation) {
|
|
216
218
|
const constraintMatch = (_j = error.message) === null || _j === void 0 ? void 0 : _j.match(/constraint\s+"([^"]+)"/);
|
|
217
|
-
logger_1.logger.
|
|
219
|
+
logger_1.logger.warn("Duplicate key in createManyInstitutionalSentimentAlerts (expected during overlapping fetches)", {
|
|
218
220
|
operation: 'createManyInstitutionalSentimentAlerts',
|
|
219
221
|
model: 'InstitutionalSentimentAlerts',
|
|
220
|
-
error: String(error),
|
|
221
222
|
constraintName: constraintMatch ? constraintMatch[1] : undefined,
|
|
222
223
|
errorCategory: 'CONSTRAINT_VIOLATION',
|
|
223
224
|
isRetryable: false,
|
|
@@ -20,9 +20,12 @@ export declare const InstitutionalSentimentAlerts: {
|
|
|
20
20
|
* Enhanced with connection resilience against Prisma connection errors.
|
|
21
21
|
* @param props - Array of InstitutionalSentimentAlerts objects for the new records.
|
|
22
22
|
* @param globalClient - Apollo Client instance.
|
|
23
|
+
* @param options - Optional control flags (e.g., skipDuplicates).
|
|
23
24
|
* @returns The count of created records or null.
|
|
24
25
|
*/
|
|
25
|
-
createMany(props: InstitutionalSentimentAlertsType[], globalClient?: ApolloClientType<NormalizedCacheObject
|
|
26
|
+
createMany(props: InstitutionalSentimentAlertsType[], globalClient?: ApolloClientType<NormalizedCacheObject>, options?: {
|
|
27
|
+
skipDuplicates?: boolean;
|
|
28
|
+
}): Promise<{
|
|
26
29
|
count: number;
|
|
27
30
|
} | null>;
|
|
28
31
|
/**
|
|
@@ -139,9 +139,10 @@ exports.InstitutionalSentimentErrors = {
|
|
|
139
139
|
* Enhanced with connection resilience against Prisma connection errors.
|
|
140
140
|
* @param props - Array of InstitutionalSentimentErrors objects for the new records.
|
|
141
141
|
* @param globalClient - Apollo Client instance.
|
|
142
|
+
* @param options - Optional control flags (e.g., skipDuplicates).
|
|
142
143
|
* @returns The count of created records or null.
|
|
143
144
|
*/
|
|
144
|
-
async createMany(props, globalClient) {
|
|
145
|
+
async createMany(props, globalClient, options) {
|
|
145
146
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
|
|
146
147
|
// Maximum number of retries for database connection issues
|
|
147
148
|
const MAX_RETRIES = 3;
|
|
@@ -158,8 +159,8 @@ exports.InstitutionalSentimentErrors = {
|
|
|
158
159
|
]);
|
|
159
160
|
const { gql, ApolloError } = modules;
|
|
160
161
|
const CREATE_MANY_INSTITUTIONALSENTIMENTERRORS = gql `
|
|
161
|
-
mutation createManyInstitutionalSentimentErrors($data: [InstitutionalSentimentErrorsCreateManyInput!]
|
|
162
|
-
createManyInstitutionalSentimentErrors(data: $data) {
|
|
162
|
+
mutation createManyInstitutionalSentimentErrors($data: [InstitutionalSentimentErrorsCreateManyInput!]!, $skipDuplicates: Boolean) {
|
|
163
|
+
createManyInstitutionalSentimentErrors(data: $data, skipDuplicates: $skipDuplicates) {
|
|
163
164
|
count
|
|
164
165
|
}
|
|
165
166
|
}`;
|
|
@@ -171,6 +172,7 @@ exports.InstitutionalSentimentErrors = {
|
|
|
171
172
|
recordCount: prop.recordCount !== undefined ? prop.recordCount : undefined,
|
|
172
173
|
severity: prop.severity !== undefined ? prop.severity : undefined,
|
|
173
174
|
})),
|
|
175
|
+
...((options === null || options === void 0 ? void 0 : options.skipDuplicates) ? { skipDuplicates: true } : {}),
|
|
174
176
|
};
|
|
175
177
|
const filteredVariables = (0, utils_1.removeUndefinedProps)(variables);
|
|
176
178
|
const response = await client.mutate({
|
|
@@ -201,10 +203,9 @@ exports.InstitutionalSentimentErrors = {
|
|
|
201
203
|
((_h = error.message) === null || _h === void 0 ? void 0 : _h.includes('P2003'));
|
|
202
204
|
if (isConstraintViolation) {
|
|
203
205
|
const constraintMatch = (_j = error.message) === null || _j === void 0 ? void 0 : _j.match(/constraint\s+"([^"]+)"/);
|
|
204
|
-
logger_1.logger.
|
|
206
|
+
logger_1.logger.warn("Duplicate key in createManyInstitutionalSentimentErrors (expected during overlapping fetches)", {
|
|
205
207
|
operation: 'createManyInstitutionalSentimentErrors',
|
|
206
208
|
model: 'InstitutionalSentimentErrors',
|
|
207
|
-
error: String(error),
|
|
208
209
|
constraintName: constraintMatch ? constraintMatch[1] : undefined,
|
|
209
210
|
errorCategory: 'CONSTRAINT_VIOLATION',
|
|
210
211
|
isRetryable: false,
|
|
@@ -20,9 +20,12 @@ export declare const InstitutionalSentimentErrors: {
|
|
|
20
20
|
* Enhanced with connection resilience against Prisma connection errors.
|
|
21
21
|
* @param props - Array of InstitutionalSentimentErrors objects for the new records.
|
|
22
22
|
* @param globalClient - Apollo Client instance.
|
|
23
|
+
* @param options - Optional control flags (e.g., skipDuplicates).
|
|
23
24
|
* @returns The count of created records or null.
|
|
24
25
|
*/
|
|
25
|
-
createMany(props: InstitutionalSentimentErrorsType[], globalClient?: ApolloClientType<NormalizedCacheObject
|
|
26
|
+
createMany(props: InstitutionalSentimentErrorsType[], globalClient?: ApolloClientType<NormalizedCacheObject>, options?: {
|
|
27
|
+
skipDuplicates?: boolean;
|
|
28
|
+
}): Promise<{
|
|
26
29
|
count: number;
|
|
27
30
|
} | null>;
|
|
28
31
|
/**
|
|
@@ -218,9 +218,10 @@ exports.InstitutionalSentimentHistory = {
|
|
|
218
218
|
* Enhanced with connection resilience against Prisma connection errors.
|
|
219
219
|
* @param props - Array of InstitutionalSentimentHistory objects for the new records.
|
|
220
220
|
* @param globalClient - Apollo Client instance.
|
|
221
|
+
* @param options - Optional control flags (e.g., skipDuplicates).
|
|
221
222
|
* @returns The count of created records or null.
|
|
222
223
|
*/
|
|
223
|
-
async createMany(props, globalClient) {
|
|
224
|
+
async createMany(props, globalClient, options) {
|
|
224
225
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
|
|
225
226
|
// Maximum number of retries for database connection issues
|
|
226
227
|
const MAX_RETRIES = 3;
|
|
@@ -237,8 +238,8 @@ exports.InstitutionalSentimentHistory = {
|
|
|
237
238
|
]);
|
|
238
239
|
const { gql, ApolloError } = modules;
|
|
239
240
|
const CREATE_MANY_INSTITUTIONALSENTIMENTHISTORY = gql `
|
|
240
|
-
mutation createManyInstitutionalSentimentHistory($data: [InstitutionalSentimentHistoryCreateManyInput!]
|
|
241
|
-
createManyInstitutionalSentimentHistory(data: $data) {
|
|
241
|
+
mutation createManyInstitutionalSentimentHistory($data: [InstitutionalSentimentHistoryCreateManyInput!]!, $skipDuplicates: Boolean) {
|
|
242
|
+
createManyInstitutionalSentimentHistory(data: $data, skipDuplicates: $skipDuplicates) {
|
|
242
243
|
count
|
|
243
244
|
}
|
|
244
245
|
}`;
|
|
@@ -289,6 +290,7 @@ exports.InstitutionalSentimentHistory = {
|
|
|
289
290
|
darkPoolVolumeSignificance: prop.darkPoolVolumeSignificance !== undefined ? prop.darkPoolVolumeSignificance : undefined,
|
|
290
291
|
darkPoolPriceImpact: prop.darkPoolPriceImpact !== undefined ? prop.darkPoolPriceImpact : undefined,
|
|
291
292
|
})),
|
|
293
|
+
...((options === null || options === void 0 ? void 0 : options.skipDuplicates) ? { skipDuplicates: true } : {}),
|
|
292
294
|
};
|
|
293
295
|
const filteredVariables = (0, utils_1.removeUndefinedProps)(variables);
|
|
294
296
|
const response = await client.mutate({
|
|
@@ -319,10 +321,9 @@ exports.InstitutionalSentimentHistory = {
|
|
|
319
321
|
((_h = error.message) === null || _h === void 0 ? void 0 : _h.includes('P2003'));
|
|
320
322
|
if (isConstraintViolation) {
|
|
321
323
|
const constraintMatch = (_j = error.message) === null || _j === void 0 ? void 0 : _j.match(/constraint\s+"([^"]+)"/);
|
|
322
|
-
logger_1.logger.
|
|
324
|
+
logger_1.logger.warn("Duplicate key in createManyInstitutionalSentimentHistory (expected during overlapping fetches)", {
|
|
323
325
|
operation: 'createManyInstitutionalSentimentHistory',
|
|
324
326
|
model: 'InstitutionalSentimentHistory',
|
|
325
|
-
error: String(error),
|
|
326
327
|
constraintName: constraintMatch ? constraintMatch[1] : undefined,
|
|
327
328
|
errorCategory: 'CONSTRAINT_VIOLATION',
|
|
328
329
|
isRetryable: false,
|
|
@@ -20,9 +20,12 @@ export declare const InstitutionalSentimentHistory: {
|
|
|
20
20
|
* Enhanced with connection resilience against Prisma connection errors.
|
|
21
21
|
* @param props - Array of InstitutionalSentimentHistory objects for the new records.
|
|
22
22
|
* @param globalClient - Apollo Client instance.
|
|
23
|
+
* @param options - Optional control flags (e.g., skipDuplicates).
|
|
23
24
|
* @returns The count of created records or null.
|
|
24
25
|
*/
|
|
25
|
-
createMany(props: InstitutionalSentimentHistoryType[], globalClient?: ApolloClientType<NormalizedCacheObject
|
|
26
|
+
createMany(props: InstitutionalSentimentHistoryType[], globalClient?: ApolloClientType<NormalizedCacheObject>, options?: {
|
|
27
|
+
skipDuplicates?: boolean;
|
|
28
|
+
}): Promise<{
|
|
26
29
|
count: number;
|
|
27
30
|
} | null>;
|
|
28
31
|
/**
|
|
@@ -143,9 +143,10 @@ exports.InstitutionalSentimentMetrics = {
|
|
|
143
143
|
* Enhanced with connection resilience against Prisma connection errors.
|
|
144
144
|
* @param props - Array of InstitutionalSentimentMetrics objects for the new records.
|
|
145
145
|
* @param globalClient - Apollo Client instance.
|
|
146
|
+
* @param options - Optional control flags (e.g., skipDuplicates).
|
|
146
147
|
* @returns The count of created records or null.
|
|
147
148
|
*/
|
|
148
|
-
async createMany(props, globalClient) {
|
|
149
|
+
async createMany(props, globalClient, options) {
|
|
149
150
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
|
|
150
151
|
// Maximum number of retries for database connection issues
|
|
151
152
|
const MAX_RETRIES = 3;
|
|
@@ -162,8 +163,8 @@ exports.InstitutionalSentimentMetrics = {
|
|
|
162
163
|
]);
|
|
163
164
|
const { gql, ApolloError } = modules;
|
|
164
165
|
const CREATE_MANY_INSTITUTIONALSENTIMENTMETRICS = gql `
|
|
165
|
-
mutation createManyInstitutionalSentimentMetrics($data: [InstitutionalSentimentMetricsCreateManyInput!]
|
|
166
|
-
createManyInstitutionalSentimentMetrics(data: $data) {
|
|
166
|
+
mutation createManyInstitutionalSentimentMetrics($data: [InstitutionalSentimentMetricsCreateManyInput!]!, $skipDuplicates: Boolean) {
|
|
167
|
+
createManyInstitutionalSentimentMetrics(data: $data, skipDuplicates: $skipDuplicates) {
|
|
167
168
|
count
|
|
168
169
|
}
|
|
169
170
|
}`;
|
|
@@ -177,6 +178,7 @@ exports.InstitutionalSentimentMetrics = {
|
|
|
177
178
|
processingTimeMs: prop.processingTimeMs !== undefined ? prop.processingTimeMs : undefined,
|
|
178
179
|
batchSize: prop.batchSize !== undefined ? prop.batchSize : undefined,
|
|
179
180
|
})),
|
|
181
|
+
...((options === null || options === void 0 ? void 0 : options.skipDuplicates) ? { skipDuplicates: true } : {}),
|
|
180
182
|
};
|
|
181
183
|
const filteredVariables = (0, utils_1.removeUndefinedProps)(variables);
|
|
182
184
|
const response = await client.mutate({
|
|
@@ -207,10 +209,9 @@ exports.InstitutionalSentimentMetrics = {
|
|
|
207
209
|
((_h = error.message) === null || _h === void 0 ? void 0 : _h.includes('P2003'));
|
|
208
210
|
if (isConstraintViolation) {
|
|
209
211
|
const constraintMatch = (_j = error.message) === null || _j === void 0 ? void 0 : _j.match(/constraint\s+"([^"]+)"/);
|
|
210
|
-
logger_1.logger.
|
|
212
|
+
logger_1.logger.warn("Duplicate key in createManyInstitutionalSentimentMetrics (expected during overlapping fetches)", {
|
|
211
213
|
operation: 'createManyInstitutionalSentimentMetrics',
|
|
212
214
|
model: 'InstitutionalSentimentMetrics',
|
|
213
|
-
error: String(error),
|
|
214
215
|
constraintName: constraintMatch ? constraintMatch[1] : undefined,
|
|
215
216
|
errorCategory: 'CONSTRAINT_VIOLATION',
|
|
216
217
|
isRetryable: false,
|
|
@@ -20,9 +20,12 @@ export declare const InstitutionalSentimentMetrics: {
|
|
|
20
20
|
* Enhanced with connection resilience against Prisma connection errors.
|
|
21
21
|
* @param props - Array of InstitutionalSentimentMetrics objects for the new records.
|
|
22
22
|
* @param globalClient - Apollo Client instance.
|
|
23
|
+
* @param options - Optional control flags (e.g., skipDuplicates).
|
|
23
24
|
* @returns The count of created records or null.
|
|
24
25
|
*/
|
|
25
|
-
createMany(props: InstitutionalSentimentMetricsType[], globalClient?: ApolloClientType<NormalizedCacheObject
|
|
26
|
+
createMany(props: InstitutionalSentimentMetricsType[], globalClient?: ApolloClientType<NormalizedCacheObject>, options?: {
|
|
27
|
+
skipDuplicates?: boolean;
|
|
28
|
+
}): Promise<{
|
|
26
29
|
count: number;
|
|
27
30
|
} | null>;
|
|
28
31
|
/**
|
package/InviteToken.cjs
CHANGED
|
@@ -441,9 +441,10 @@ exports.InviteToken = {
|
|
|
441
441
|
* Enhanced with connection resilience against Prisma connection errors.
|
|
442
442
|
* @param props - Array of InviteToken objects for the new records.
|
|
443
443
|
* @param globalClient - Apollo Client instance.
|
|
444
|
+
* @param options - Optional control flags (e.g., skipDuplicates).
|
|
444
445
|
* @returns The count of created records or null.
|
|
445
446
|
*/
|
|
446
|
-
async createMany(props, globalClient) {
|
|
447
|
+
async createMany(props, globalClient, options) {
|
|
447
448
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
|
|
448
449
|
// Maximum number of retries for database connection issues
|
|
449
450
|
const MAX_RETRIES = 3;
|
|
@@ -460,8 +461,8 @@ exports.InviteToken = {
|
|
|
460
461
|
]);
|
|
461
462
|
const { gql, ApolloError } = modules;
|
|
462
463
|
const CREATE_MANY_INVITETOKEN = gql `
|
|
463
|
-
mutation createManyInviteToken($data: [InviteTokenCreateManyInput!]
|
|
464
|
-
createManyInviteToken(data: $data) {
|
|
464
|
+
mutation createManyInviteToken($data: [InviteTokenCreateManyInput!]!, $skipDuplicates: Boolean) {
|
|
465
|
+
createManyInviteToken(data: $data, skipDuplicates: $skipDuplicates) {
|
|
465
466
|
count
|
|
466
467
|
}
|
|
467
468
|
}`;
|
|
@@ -474,6 +475,7 @@ exports.InviteToken = {
|
|
|
474
475
|
usedAt: prop.usedAt !== undefined ? prop.usedAt : undefined,
|
|
475
476
|
expiresAt: prop.expiresAt !== undefined ? prop.expiresAt : undefined,
|
|
476
477
|
})),
|
|
478
|
+
...((options === null || options === void 0 ? void 0 : options.skipDuplicates) ? { skipDuplicates: true } : {}),
|
|
477
479
|
};
|
|
478
480
|
const filteredVariables = (0, utils_1.removeUndefinedProps)(variables);
|
|
479
481
|
const response = await client.mutate({
|
|
@@ -504,10 +506,9 @@ exports.InviteToken = {
|
|
|
504
506
|
((_h = error.message) === null || _h === void 0 ? void 0 : _h.includes('P2003'));
|
|
505
507
|
if (isConstraintViolation) {
|
|
506
508
|
const constraintMatch = (_j = error.message) === null || _j === void 0 ? void 0 : _j.match(/constraint\s+"([^"]+)"/);
|
|
507
|
-
logger_1.logger.
|
|
509
|
+
logger_1.logger.warn("Duplicate key in createManyInviteToken (expected during overlapping fetches)", {
|
|
508
510
|
operation: 'createManyInviteToken',
|
|
509
511
|
model: 'InviteToken',
|
|
510
|
-
error: String(error),
|
|
511
512
|
constraintName: constraintMatch ? constraintMatch[1] : undefined,
|
|
512
513
|
errorCategory: 'CONSTRAINT_VIOLATION',
|
|
513
514
|
isRetryable: false,
|
package/InviteToken.d.ts
CHANGED
|
@@ -20,9 +20,12 @@ export declare const InviteToken: {
|
|
|
20
20
|
* Enhanced with connection resilience against Prisma connection errors.
|
|
21
21
|
* @param props - Array of InviteToken objects for the new records.
|
|
22
22
|
* @param globalClient - Apollo Client instance.
|
|
23
|
+
* @param options - Optional control flags (e.g., skipDuplicates).
|
|
23
24
|
* @returns The count of created records or null.
|
|
24
25
|
*/
|
|
25
|
-
createMany(props: InviteTokenType[], globalClient?: ApolloClientType<NormalizedCacheObject
|
|
26
|
+
createMany(props: InviteTokenType[], globalClient?: ApolloClientType<NormalizedCacheObject>, options?: {
|
|
27
|
+
skipDuplicates?: boolean;
|
|
28
|
+
}): Promise<{
|
|
26
29
|
count: number;
|
|
27
30
|
} | null>;
|
|
28
31
|
/**
|
package/LinkedProvider.cjs
CHANGED
|
@@ -574,9 +574,10 @@ exports.LinkedProvider = {
|
|
|
574
574
|
* Enhanced with connection resilience against Prisma connection errors.
|
|
575
575
|
* @param props - Array of LinkedProvider objects for the new records.
|
|
576
576
|
* @param globalClient - Apollo Client instance.
|
|
577
|
+
* @param options - Optional control flags (e.g., skipDuplicates).
|
|
577
578
|
* @returns The count of created records or null.
|
|
578
579
|
*/
|
|
579
|
-
async createMany(props, globalClient) {
|
|
580
|
+
async createMany(props, globalClient, options) {
|
|
580
581
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
|
|
581
582
|
// Maximum number of retries for database connection issues
|
|
582
583
|
const MAX_RETRIES = 3;
|
|
@@ -593,8 +594,8 @@ exports.LinkedProvider = {
|
|
|
593
594
|
]);
|
|
594
595
|
const { gql, ApolloError } = modules;
|
|
595
596
|
const CREATE_MANY_LINKEDPROVIDER = gql `
|
|
596
|
-
mutation createManyLinkedProvider($data: [LinkedProviderCreateManyInput!]
|
|
597
|
-
createManyLinkedProvider(data: $data) {
|
|
597
|
+
mutation createManyLinkedProvider($data: [LinkedProviderCreateManyInput!]!, $skipDuplicates: Boolean) {
|
|
598
|
+
createManyLinkedProvider(data: $data, skipDuplicates: $skipDuplicates) {
|
|
598
599
|
count
|
|
599
600
|
}
|
|
600
601
|
}`;
|
|
@@ -609,6 +610,7 @@ exports.LinkedProvider = {
|
|
|
609
610
|
expiresAt: prop.expiresAt !== undefined ? prop.expiresAt : undefined,
|
|
610
611
|
linkedAt: prop.linkedAt !== undefined ? prop.linkedAt : undefined,
|
|
611
612
|
})),
|
|
613
|
+
...((options === null || options === void 0 ? void 0 : options.skipDuplicates) ? { skipDuplicates: true } : {}),
|
|
612
614
|
};
|
|
613
615
|
const filteredVariables = (0, utils_1.removeUndefinedProps)(variables);
|
|
614
616
|
const response = await client.mutate({
|
|
@@ -639,10 +641,9 @@ exports.LinkedProvider = {
|
|
|
639
641
|
((_h = error.message) === null || _h === void 0 ? void 0 : _h.includes('P2003'));
|
|
640
642
|
if (isConstraintViolation) {
|
|
641
643
|
const constraintMatch = (_j = error.message) === null || _j === void 0 ? void 0 : _j.match(/constraint\s+"([^"]+)"/);
|
|
642
|
-
logger_1.logger.
|
|
644
|
+
logger_1.logger.warn("Duplicate key in createManyLinkedProvider (expected during overlapping fetches)", {
|
|
643
645
|
operation: 'createManyLinkedProvider',
|
|
644
646
|
model: 'LinkedProvider',
|
|
645
|
-
error: String(error),
|
|
646
647
|
constraintName: constraintMatch ? constraintMatch[1] : undefined,
|
|
647
648
|
errorCategory: 'CONSTRAINT_VIOLATION',
|
|
648
649
|
isRetryable: false,
|