From bc461429f687ab6c625cde68aacfa9d5434a5aec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fahri=20Can=20Se=C3=A7er?= Date: Sun, 26 Apr 2026 17:04:46 +0300 Subject: [PATCH] debug: add checkpoint timestamps to processDate for hang diagnosis --- src/modules/feeder/feeder.service.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/modules/feeder/feeder.service.ts b/src/modules/feeder/feeder.service.ts index 01274a5..76e8d9c 100755 --- a/src/modules/feeder/feeder.service.ts +++ b/src/modules/feeder/feeder.service.ts @@ -337,6 +337,7 @@ export class FeederService { const apiReturnedCount = allMatches.length; const afterDateFilterCount = dateFilteredMatches.length; + this.logger.warn(`[${sport}] [${dateString}] ⏱️ CHECKPOINT-1: dateFilter done. API=${apiReturnedCount}, filtered=${afterDateFilterCount}`); if (apiReturnedCount > 0 && afterDateFilterCount === 0) { this.logger.log( @@ -387,13 +388,17 @@ export class FeederService { // 2. Filter out already existing matches & patch incomplete ones const allIds = matchesToProcess.map((m) => m.id); + this.logger.warn(`[${sport}] [${dateString}] ⏱️ CHECKPOINT-2: pre-getExistingMatchIds, ${allIds.length} IDs`); const existingIds = await this.persistenceService.getExistingMatchIds(allIds); + this.logger.warn(`[${sport}] [${dateString}] ⏱️ CHECKPOINT-3: getExistingMatchIds done, ${existingIds.length} existing`); const totalCount = matchesToProcess.length; // ── Patch incomplete existing matches ────────────────────── // Find matches that ARE in DB but have missing data scopes + this.logger.warn(`[${sport}] [${dateString}] ⏱️ CHECKPOINT-4: pre-getMissingScopes`); const allExistingInDb = await this.persistenceService.getMissingScopes(allIds); + this.logger.warn(`[${sport}] [${dateString}] ⏱️ CHECKPOINT-5: getMissingScopes done, ${allExistingInDb.size} incomplete`); if (allExistingInDb.size > 0) { this.logger.log( `[${sport}] [${dateString}] 🔧 Found ${allExistingInDb.size} existing matches with missing data. Patching...`,