think-orm icon indicating copy to clipboard operation
think-orm copied to clipboard

关于mongdb 使用model 的问题

Open SRCAM opened this issue 4 years ago • 1 comments

1.mongdb 未填写dsn的情况下,无法指定某个数据库 Snipaste_2021-10-20_18-09-51 2.部署方式为单一服务器模式一下,保存数据会出现 MongoDB\Driver\Exception\BulkWriteException : Transaction numbers are only allowed on a replica set member or mongos 建议在think\db\connector\Mongo 类的 transaction 方法判断是否为单一服务器模式 如果是单一模式 不生成相关事务

SRCAM avatar Oct 20 '21 10:10 SRCAM

@liu21st

SRCAM avatar Oct 20 '21 10:10 SRCAM