update
This commit is contained in:
parent
2ff2758fc8
commit
d6c78a28bd
@ -7,13 +7,13 @@ const sleepUtils = require('../utils/sleepUtils');
|
||||
// 数据库连接池
|
||||
dbUtils.create({
|
||||
database: "neteaseMusic", // 指定数据库
|
||||
connectionLimit: 10, // 设置数据库连接池数量
|
||||
connectionLimit: global.connectionLimit || 10, // 设置数据库连接池数量
|
||||
});
|
||||
global.dbUtils = dbUtils;
|
||||
console.log("global.useMysqlPool:", !!global.useMysqlPool);
|
||||
|
||||
// 两次请求之间停顿时间
|
||||
global.sleepTime = 100;
|
||||
global.sleepTime = 500;
|
||||
|
||||
// 引入utils
|
||||
const songInfoUtils = require('./src/getInfo/songInfoUtils');
|
||||
@ -52,7 +52,7 @@ async function main() {
|
||||
console.log(`删除脏数据 affectRows:`, affectRows1.affectedRows, affectRows2.affectedRows);
|
||||
|
||||
await songInfoUtils.fetchAll();
|
||||
await albumInfoUtils.fetchAll();
|
||||
await albumInfoUtils.fetchAll({});
|
||||
await artistInfoUtils.fetchAll();
|
||||
await lyricInfoUtils.fetchAll();
|
||||
await sleepUtils.sleep(2000);
|
||||
|
Loading…
Reference in New Issue
Block a user