perf: hapus semua cooldown/backoff delay — retry tanpa bottleneck
Semua retry sekarang instant (retries=0, minTimeout=0, maxTimeout=0): - retry.ts (kedua) — default minTimeout/maxTimeout 0, factor 1 - config.ts (kedua) — DECODER_COOLDOWN_MS=0, AI_ANALYSIS_ERROR_COOLDOWN_MS=0 - llmModerationClient.ts (kedua) — retries 0 tanpa delay - aiAnalyzer.ts (kedua) — retries 0, AI_ANALYSIS_ERROR_COOLDOWN jadi 0 - indonesianTextNormalizer.ts (kedua) — semua rate limit cooldown 0 - recorder.ts (kedua), teleUpload (3 files), uploader (2 files) — retry instant - attachmentUploader (kedua) — retries 0 - syncRoutes.ts — BACKLOG_SYNC_COOLDOWN 0 20 files changed. Semua cooldown bottleneck dihapus. Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.8
parent
62d7d19b53
commit
64643bb066
@@ -41,15 +41,17 @@ function getModerationBroadcaster(): ModerationBroadcaster | undefined {
|
||||
function scheduleAutoDelete(row: MessageRecord): void {
|
||||
if (row.ai_status !== "flagged" && row.ai_status !== "warn") return;
|
||||
const run = () => {
|
||||
attemptAutoDeleteFlaggedMessage(moderationClient, row).catch((error: unknown) => {
|
||||
logger.error(
|
||||
{
|
||||
messageId: row.id,
|
||||
error: error instanceof Error ? error.message : String(error),
|
||||
},
|
||||
"Unexpected auto-delete error",
|
||||
);
|
||||
});
|
||||
attemptAutoDeleteFlaggedMessage(moderationClient, row).catch(
|
||||
(error: unknown) => {
|
||||
logger.error(
|
||||
{
|
||||
messageId: row.id,
|
||||
error: error instanceof Error ? error.message : String(error),
|
||||
},
|
||||
"Unexpected auto-delete error",
|
||||
);
|
||||
},
|
||||
);
|
||||
};
|
||||
|
||||
if (config.AUTO_DELETE_FLAGGED_DELAY_MS > 0) {
|
||||
@@ -349,9 +351,9 @@ async function processIndividualFallback(
|
||||
}
|
||||
},
|
||||
{
|
||||
retries: 2,
|
||||
minTimeout: 2000,
|
||||
maxTimeout: 15000,
|
||||
retries: 0,
|
||||
minTimeout: 0,
|
||||
maxTimeout: 0,
|
||||
logger,
|
||||
},
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user