[CDRIVER-2106] Refactor code to not assume OP_REPLY is the only reply opcode Created: 31/Mar/17  Updated: 03/May/17  Resolved: 07/Apr/17

Status: Closed
Project: C Driver
Component/s: None
Affects Version/s: None
Fix Version/s: 1.7.0

Type: Task Priority: Major - P3
Reporter: Hannes Magnusson Assignee: Hannes Magnusson
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Epic Link: Wire protocol changes

 Description   

The cursors, and most of command infrastructure, has liberal assumption that the opcode they are working with is OP_REPLY.

Aside from the OP_REPLY sanitychecks, it accesses the rpc structure in a intimate way rather then through a layer that abstracts the actual opcodes.

There are also aggressive optimizations in the command infrastructure that instead of expecting a cursor it allocates the entire reply as a command reply, rather then reading the reply into buffer and present it as a bson, like the cursors do.

These assumptions are no longer true for other opcdoes.



 Comments   
Comment by Githook User [ 07/Apr/17 ]

Author:

{u'username': u'bjori', u'name': u'Hannes Magnusson', u'email': u'bjori@php.net'}

Message: CDRIVER-2106 Fix counter description
Branch: master
https://github.com/mongodb/mongo-c-driver/commit/886db037fd10a218b7b552089d6ea8d86c4f772b

Comment by Githook User [ 07/Apr/17 ]

Author:

{u'username': u'bjori', u'name': u'Hannes Magnusson', u'email': u'bjori@php.net'}

Message: CDRIVER-2106 Missing counters for commands
Branch: master
https://github.com/mongodb/mongo-c-driver/commit/832818df3df634480c11dc12bbacc8dcd5fe969e

Comment by Githook User [ 07/Apr/17 ]

Author:

{u'username': u'bjori', u'name': u'Hannes Magnusson', u'email': u'bjori@php.net'}

Message: CDRIVER-2106 Minor refactoring to make accommodating new opcode easier
Branch: master
https://github.com/mongodb/mongo-c-driver/commit/236d3dff4e237274a66f291a60bf534375055268

Generated at Wed Feb 07 21:14:12 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.