我正在使用MongoUpdateBatch
$batch = new \MongoUpdateBatch($collection, ['ordered' => false, 'wtimeout' => 500000]);
偶尔会收到以下错误:
Read timed out after reading 0 bytes, waited for 30.000000 seconds
Trace:
#8 MongoCursorTimeoutException in /var/app/current/src/Model/Campaign.php:286
#7 MongoWriteBatch:execute in /var/app/current/src/Model/Campaign.php:286
#6 ...
MongoWriteBatch:execute()
抛出MongoCursorTimeoutException
的原因是什么?如何避免?