Update load-cluster.js

This commit is contained in:
Aleksandr Statciuk 2022-01-15 18:21:48 +03:00
parent 198110aa54
commit a19ebb96ad

View file

@ -26,6 +26,7 @@ async function main() {
logger.info(`Loading cluster: ${options.clusterId}`)
logger.info(`Creating '${clusterLog}'...`)
await file.create(clusterLog)
await db.channels.load()
const channels = await db.channels.find({ cluster_id: options.clusterId })
const total = options.days * channels.length
logger.info(`Total ${total} requests`)