chore: update redis adaptor

Signed-off-by: Innei <i@innei.in>
This commit is contained in:
Innei
2023-12-22 19:38:14 +08:00
parent 2da44b0b6e
commit 826803c273
6 changed files with 352 additions and 208 deletions

View File

@@ -48,7 +48,7 @@
"changelog": true
},
"dependencies": {
"@algolia/client-search": "^4.21.1",
"@algolia/client-search": "^4.22.0",
"@babel/core": "7.23.6",
"@babel/plugin-transform-modules-commonjs": "7.23.3",
"@babel/plugin-transform-typescript": "7.23.6",
@@ -70,8 +70,8 @@
"@nestjs/throttler": "5.1.1",
"@nestjs/websockets": "10.3.0",
"@simplewebauthn/server": "8.3.5",
"@socket.io/redis-adapter": "7.2.0",
"@socket.io/redis-emitter": "4.1.1",
"@socket.io/redis-adapter": "8.2.1",
"@socket.io/redis-emitter": "5.1.0",
"@typegoose/auto-increment": "4.0.0",
"@typegoose/typegoose": "12.0.0",
"@types/jsonwebtoken": "9.0.5",

View File

@@ -163,7 +163,6 @@ class TaskQueuePool<T> {
private async batchInsert() {
if (this.pool.length === 0) return
console.log('batch all', this.pool)
await this.collection.insertMany(this.pool)
await this.onBatch(this.pool.length)
// 清空任务池,准备下一次批量插入

View File

@@ -10,7 +10,7 @@ export abstract class BaseGateway {
) {
return {
type,
data: message,
data: JSON.parse(JSON.stringify(message)),
code,
}
}

View File

@@ -38,7 +38,7 @@
"@innei/prettier": "0.12.0",
"@types/node": "20.10.5",
"cross-env": "7.0.3",
"eslint": "^8.55.0",
"eslint": "^8.56.0",
"eslint-plugin-unused-imports": "3.0.0",
"husky": "8.0.3",
"lint-staged": "15.2.0",

View File

@@ -57,7 +57,7 @@
"lodash": "4.17.21",
"tsup": "8.0.1",
"umi-request": "1.4.0",
"vite": "^5.0.8",
"vite": "^5.0.10",
"vitest": "^1.0.4"
}
}

547
pnpm-lock.yaml generated

File diff suppressed because it is too large Load Diff