One my MongoDB client program has been working well for a MongoDB 3.2 master-slave cluster for a long time. But now, a problem shows up when it connects to a MongoDB 3.0.2 sharding cluster.
When the program creates a new user for a new database, the error "$queryOptions is not a valid argument to updateUser" is always returned at the following code:
err = newdb.UpsertUser(&mgo.User{
Username: newusername,
Password: newpassword,
Roles: []mgo.Role{
mgo.RoleReadWrite,
},
})
Can anyone provide some hints?
btw, the mgo package is the latest one.