This commit is contained in:
SunSeekerX
2025-12-31 02:17:10 +08:00
parent 584fa8c9c1
commit b4233033a6
9 changed files with 50 additions and 42 deletions

View File

@@ -93,7 +93,13 @@ async function migrate() {
console.log('\n4. 迁移 usage:model:hourly 索引...')
cursor = '0'
do {
const [newCursor, keys] = await redis.scan(cursor, 'MATCH', 'usage:model:hourly:*', 'COUNT', 500)
const [newCursor, keys] = await redis.scan(
cursor,
'MATCH',
'usage:model:hourly:*',
'COUNT',
500
)
cursor = newCursor
const pipeline = redis.pipeline()