[CDRIVER-1551] Collation: Raise error for command helpers, and support aggregate and createindex Created: 20/Sep/16 Updated: 19/Oct/16 Resolved: 23/Sep/16 |
|
| Status: | Closed |
| Project: | C Driver |
| Component/s: | None |
| Affects Version/s: | 1.5.0 |
| Fix Version/s: | 1.5.0 |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Hannes Magnusson | Assignee: | A. Jesse Jiryu Davis |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||||||
| Epic Link: | Flexible opts | ||||||||||||||||||||
| Description |
|
Talking with rassi on how collation worked in mongoc.. We don't actually raise error when command helpers using _mongoc_client_command_with_opts hit a server that doesn't support collation. Furthermore, it seems the aggregate helper only picks out options it knows from the opts argument, rather then bson_concat ing the entire bson_t. And, mongoc_collection_create_index_with_opts needs an explicit support for the collation argument as its part of the "indexes" subdocument, not the command itself |
| Comments |
| Comment by Githook User [ 19/Oct/16 ] |
|
Author: {u'username': u'ajdavis', u'name': u'A. Jesse Jiryu Davis', u'email': u'jesse@mongodb.com'}Message: |
| Comment by A. Jesse Jiryu Davis [ 19/Oct/16 ] |
|
Our patches crossed and made some tests fail, I can fix it up. Let's set the error code to MONGOC_ERROR_PROTOCOL_BAD_WIRE_VERSION when the server's too old for collation, and MONGOC_ERROR_COMMAND_INVALID_ARG when collation is combined with w=0. I'll submit a patch momentarily. |
| Comment by Githook User [ 19/Oct/16 ] |
|
Author: {u'username': u'ajdavis', u'name': u'A. Jesse Jiryu Davis', u'email': u'jesse@mongodb.com'}Message: |
| Comment by Githook User [ 23/Sep/16 ] |
|
Author: {u'username': u'bjori', u'name': u'Hannes Magnusson', u'email': u'bjori@php.net'}Message: Also raise error when the server doesn't support collation |