fixed up qm tasks and shutdown sequence

This commit is contained in:
Boki 2025-06-21 09:39:09 -04:00
parent 5929612e36
commit 1bb2380a28
4 changed files with 37 additions and 7 deletions

View file

@ -1,5 +1,5 @@
import { Collection, Db, MongoClient, OptionalUnlessRequiredId } from 'mongodb';
import { getLogger } from '@stock-bot/logger';
import { Collection, Db, MongoClient, OptionalUnlessRequiredId } from 'mongodb';
import type { DocumentBase, MongoDBClientConfig } from './types';
/**
@ -149,7 +149,7 @@ export class MongoDBClient {
let totalUpdated = 0;
const errors: unknown[] = [];
this.logger.info(`Starting batch upsert operation [${operationId}]`, {
this.logger.info(`Starting batch upsert operation [${collectionName}-${documents.length}][${operationId}]`, {
database: dbName,
collection: collectionName,
totalDocuments: documents.length,