Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(NODE-5706): make findOne() close implicit session to avoid memory leak #3897

Merged
merged 1 commit into from
Oct 18, 2023

Conversation

nbbeeken
Copy link
Contributor

Description

What is changing?

A forward port of #3889

Is there new documentation needed for these changes?

No

What is the motivation for this change?

Ensures the cursor created for findOne is always cleaned up

Release Highlight

Fixed leak in findOne() under specific conditions

When running a findOne against a time series collection due to the way the server returns the resulting cursor information the driver left the implicit session for the cursor un-ended. Now the cursor will always be cleaned up regardless of the outcome of the find operation.

Double check the following

  • Ran npm run check:lint script
  • Self-review completed using the steps outlined here
  • PR title follows the correct format: type(NODE-xxxx)[!]: description
    • Example: feat(NODE-1234)!: rewriting everything in coffeescript
  • Changes are covered by tests
  • New TODOs have a related JIRA ticket

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants