[英]MongooseError: Operation `domains.insertOne()` buffering timed out after 10000ms
[英]Error: insertOne()` buffering timed out after 10000ms
我剛開始學習 ZCCADCDEDB567ABAE643E15DCF0974E503Z,我無法將此 model 保存到我的數據庫並不斷收到錯誤:insertOne()` 緩沖在 10000 毫秒后超時
這是我的代碼:
我怎樣才能找到解決方案?
const options = { autoIndex: false, // Don't build indexes maxPoolSize: 10, // Maintain up to 10 socket connections serverSelectionTimeoutMS: 5000, // Keep trying to send operations for 5 seconds socketTimeoutMS: 45000, // Close sockets after 45 seconds of inactivity family: 4 // Use IPv4, skip trying IPv6 }; mongoose.connect(uri, options);
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.