[GODRIVER-1547] BatchCursor panic on clearBatch and Close Created: 26/Mar/20  Updated: 27/Oct/23  Resolved: 23/May/22

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

Type: Bug Priority: Major - P3
Reporter: Eric Daniels (Inactive) Assignee: Unassigned
Resolution: Gone away Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends

 Description   

Trace in dev comment

First panic is in (*BatchCursor).clearBatch(...) (inlined)
Second is after we panic there and in a defer try to close the cursor (*BatchCursor).Close at bc.currentBatch.Data = nil
Seems like currentBatch somehow became nil and panicked twice accessing it

I'm thinking there's some condition where (cs *ChangeStream) executeOperation( calls NewBatchCursor but there's no error which puts it in a bad state for the next Next/TryNext.


Generated at Thu Feb 08 08:36:37 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.