-
Type: Bug
-
Resolution: Duplicate
-
Priority: Major - P3
-
None
-
Affects Version/s: 2.6.0
-
Component/s: None
-
ALL
-
MongoDB 2.6 will throw an error in the following situations:
- Someone tries to use hinting with a $text index. I understand you don't support it, but in the past, features that were incompatible with hinting (like "count" until somewhere in 2.5.x) just caused it to be ignored. No need to break working code over it.
- An empty $set clause is used. Why force developers to add code to specifically not supply an empty $set clause when it's easily ignored by the server and it was valid in 2.4.x?
- An empty $unset clause is used. See above.
All three of these are a hassle to avoid when building queries dynamically.
Perhaps an error log level for "linting" would be a more appropriate place to report this kind of thing.
- * *
The move to 2.6 has been worth it for us due to the availability of text searches as part of normal queries, which is a big improvement in the ease of writing query builder code. Thank you for that change.
- is related to
-
SERVER-12266 Update no longer allows empty modifier objects
- Closed
-
SERVER-13884 $set: {} is now rejected by the update framework, but worked as a noop prior to 2.6
- Closed
- related to
-
SERVER-13883 findAndModify() cannot take an empty update object, but update() can
- Closed