perf: batch gateway submits and isolate callbacks

This commit is contained in:
hectorzhao
2026-08-25 11:39:59 +08:00
parent c6f11014d6
commit 761c123b65
29 changed files with 1912 additions and 193 deletions
+22
View File
@@ -1828,6 +1828,28 @@ model SmsSubmitRecord {
@@index([channelGroupId])
}
model GatewaySubmitOutbox {
id String @id @default(cuid())
submitId String @unique
messageRecordId String
channelId String
payload Json
schemaVersion String @default("v1")
status String @default("pending")
attemptCount Int @default(0)
nextAttemptAt DateTime @default(now())
leaseOwner String?
leaseExpiresAt DateTime?
streamEntryId String?
publishedAt DateTime?
lastError String?
createdAt DateTime @default(now())
updatedAt DateTime @updatedAt
@@index([submitId, status])
@@index([messageRecordId])
}
model DailyReconciliationReport {
id String @id @default(cuid())
reportDate DateTime @db.Date