File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed
Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -22,10 +22,10 @@ module.exports = () => {
2222 port : port || 3306 ,
2323 username : username || 'root' ,
2424 password : password || '' ,
25- // 设置连接池
25+ // 设置连接池,连接数会乘以进程数 (`lsof -i:7001` 得到 pid,`ps -ef | grep ${pid} | wc -l` 可以查看进程数)
2626 pool : {
27- max : 100 , //最大连接个数
28- min : 20 ,
27+ max : 50 , //最大连接个数
28+ min : 0 ,
2929 acquire : 40000 , // 从连接池获取连接的最长等待时间(毫秒)
3030 idle : 15000 // 连接池中空闲连接的最长存活时间(毫秒)
3131 }
Original file line number Diff line number Diff line change 1010 "dev" : " egg-bin dev --daemon" ,
1111 "start" : " bash start.sh" ,
1212 "start:test" : " bash start.sh -t" ,
13- "server" : " egg-scripts start --daemon" ,
14- "server:test" : " egg-scripts start --port=7002 --env=test --daemon" ,
13+ "server" : " egg-scripts start --daemon --workers=4 " ,
14+ "server:test" : " egg-scripts start --port=7002 --env=test --daemon --workers=2 " ,
1515 "dingBot" : " node DingBot.js" ,
1616 "stop" : " egg-scripts stop" ,
1717 "lint" : " eslint ." ,
You can’t perform that action at this time.
0 commit comments