[DOCS-10777] 3.2 users reading 3.4 version of createIndex should be warned specifying collation is a silent, but upgrade-blocking, error. Created: 12/Sep/17 Updated: 29/Oct/23 Resolved: 12/Sep/17 |
|
| Status: | Closed |
| Project: | Documentation |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Task | Priority: | Critical - P2 |
| Reporter: | Akira Kurogane | Assignee: | Kay Kim (Inactive) |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||
| Participants: | |||||
| Days since reply: | 5 years, 27 weeks, 1 day ago | ||||
| Description |
|
A 3.2 user can create an index with a "collation" option. It succeeds, even though collation is not supported in 3.2. I.e. it seems to be silently ignored.
The problem is when they upgrade 3.4. As they do an in-place, binary-version only upgrade the 3.4 mongod will not be running in "3.4" feature compatibility mode at first. In this mode it strictly checks that indexes are 3.2 compatible, and exits with "Fatal Assertion 28782" when it finds the index with the collation:
I think we should add a warning, in only the 3.4 version of documentation, at the following section. https://docs.mongodb.com/manual/reference/method/db.collection.createIndex/#option-for-collation E.g. 'Warning: 3.2 users should not specify collation option - it will be silently accepted but then block the upgrade to 3.4' |
| Comments |
| Comment by Daniele Graziani [ 07/Aug/18 ] |
|
Also, if you create a collection in 3.2 such as: db.createCollection("testCollation",{collation: {"invalid": "this is an invalid collation document"}}) { "ok" : 1 }It will succeed but upon upgrading to 3.4 it will fail. |
| Comment by Kay Kim (Inactive) [ 12/Sep/17 ] |
|
|
| Comment by Akira Kurogane [ 12/Sep/17 ] |
|
Thanks Kim! |
| Comment by Kay Kim (Inactive) [ 12/Sep/17 ] |
|
[master] https://github.com/mongodb/docs/commit/d35c7619c8d0a9c624c8e51bf14eebc2dd6b9061 [v3.4] |