[CDRIVER-1084] bson_reader_reset() Created: 08/Feb/16  Updated: 10/Aug/16  Resolved: 09/Feb/16

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

Type: New Feature Priority: Major - P3
Reporter: A. Jesse Jiryu Davis 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:
Related
is related to CDRIVER-769 APM Internal API Closed

 Description   

According to the APM spec, server replies to OP_QUERY and OP_GETMORE must be converted into simulated replies to the "find" and "getMore" commands before reporting to the APM listener.

This requires reading the server reply twice: once to convert it to a find / getMore reply, once again while iterating the cursor normally with mongoc_cursor_next.

Add a public libbson function bson_reader_reset() to the cursor can re-read the server reply without a malloc.



 Comments   
Comment by Githook User [ 09/Feb/16 ]

Author:

{u'username': u'ajdavis', u'name': u'A. Jesse Jiryu Davis', u'email': u'jesse@mongodb.com'}

Message: CDRIVER-1084 new function bson_reader_reset
Branch: master
https://github.com/mongodb/libbson/commit/50342ca0810910629709e7d86fefe5a7d5f7394a

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