mirror of
https://github.com/labring/FastGPT.git
synced 2025-07-23 05:12:39 +00:00
4.6.4-alpha (#569)
This commit is contained in:
@@ -26,9 +26,13 @@ export async function connectMongo({
|
||||
bufferCommands: true,
|
||||
maxConnecting: Number(process.env.DB_MAX_LINK || 5),
|
||||
maxPoolSize: Number(process.env.DB_MAX_LINK || 5),
|
||||
minPoolSize: Number(process.env.DB_MAX_LINK || 10) * 0.5,
|
||||
minPoolSize: Math.min(10, Number(process.env.DB_MAX_LINK || 10)),
|
||||
connectTimeoutMS: 60000,
|
||||
waitQueueTimeoutMS: 60000
|
||||
waitQueueTimeoutMS: 60000,
|
||||
socketTimeoutMS: 60000,
|
||||
maxIdleTimeMS: 300000,
|
||||
retryWrites: true,
|
||||
retryReads: true
|
||||
});
|
||||
|
||||
console.log('mongo connected');
|
||||
|
Reference in New Issue
Block a user