4 files changed
+14
-7
No files matched your search
Generated
+2
-2
@@ -1,12 +1,12 @@
|
||||
{
|
||||
"name": "client",
|
||||
"version": "3.9.0",
|
||||
"version": "3.9.1",
|
||||
"lockfileVersion": 3,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "client",
|
||||
"version": "3.9.0",
|
||||
"version": "3.9.1",
|
||||
"dependencies": {
|
||||
"@csstools/css-tokenizer": "^3.0.4",
|
||||
"@emotion/react": "^11.13.3",
|
||||
|
||||
+1
-1
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "client",
|
||||
"private": true,
|
||||
"version": "3.9.0",
|
||||
"version": "3.9.1",
|
||||
"type": "module",
|
||||
"scripts": {
|
||||
"dev": "vite",
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import mongoose from "mongoose";
|
||||
import type { Document, AnyBulkWriteOperation } from "mongodb";
|
||||
import type { Document } from "mongodb";
|
||||
|
||||
const CHECKS_COLLECTION = "checks";
|
||||
const BACKUP_COLLECTION = "checks_backup";
|
||||
@@ -144,7 +144,11 @@ const migrateBackupData = async (backedUp: boolean): Promise<MigrationStats> =>
|
||||
|
||||
stats.totalSource = await source.countDocuments();
|
||||
const cursor = source.find();
|
||||
const operations: AnyBulkWriteOperation<Document>[] = [];
|
||||
// Derive the op type from the exact bulkWrite we call so it matches whichever `mongodb` copy
|
||||
// Mongoose resolves (a fresh Docker/multiarch install nests its own under mongoose/node_modules,
|
||||
// distinct from the top-level one — importing AnyBulkWriteOperation from "mongodb" picks the wrong copy).
|
||||
type BulkOp = Parameters<typeof target.bulkWrite>[0][number];
|
||||
const operations: BulkOp[] = [];
|
||||
const invalidDocs: Document[] = [];
|
||||
|
||||
while (await cursor.hasNext()) {
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
import mongoose from "mongoose";
|
||||
import type { AnyBulkWriteOperation, Document } from "mongodb";
|
||||
import type { ILogger } from "@/utils/logger.js";
|
||||
import MaintenanceWindowModel from "../../domain/maintenance-windows/maintenance-window.model.js";
|
||||
|
||||
@@ -65,7 +64,11 @@ export async function migrateMaintenanceWindowMonitorIdToArray(logger: ILogger):
|
||||
return;
|
||||
}
|
||||
|
||||
const bulkOps: AnyBulkWriteOperation<Document>[] = [];
|
||||
// Derive the op type from the exact bulkWrite we call, so it always matches whichever `mongodb`
|
||||
// copy Mongoose resolves (a fresh Docker install nests its own under mongoose/node_modules,
|
||||
// distinct from the top-level one — importing the type from "mongodb" picks the wrong copy).
|
||||
type BulkOp = Parameters<typeof MaintenanceWindowModel.collection.bulkWrite>[0][number];
|
||||
const bulkOps: BulkOp[] = [];
|
||||
let originalDocCount = 0;
|
||||
|
||||
for (const group of groups) {
|
||||
|
||||
Reference in new issue
Block a user