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-3541): allow unacknowledged write with hint #3415

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

LinusU
Copy link
Contributor

@LinusU LinusU commented Sep 15, 2022

Description

This is a replacement to #3409, from the knowledge I got there I could implement this properly instead of just improving the error message!

Now it actually fixes the entire ticket 🎉

What is changing?

The driver now allows unacknowledged writes when a hint is present in the following scenarios:

  • In update calls when the server is 4.2 or newer
  • In delete calls when the server is 4.4 or newer
Is there new documentation needed for these changes?

Not as far as I know, because I couldn't find any documentation on this limit in the first place.

What is the motivation for this change?

This allows us to submit a hint to an unacknowledged write. See more background in NODE-3541.

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>
  • Changes are covered by tests see below
  • New TODOs have a related JIRA ticket

I also need to update the tests here, but since this is my first contribution here I would love some guidance.

What I think we need to do is to update the test/spec/crud/unified/unacknowledged-*-hint-clientError.yml files and make them only test for the error on specific server versions, but expect success on others. If anyone could point me in the right direction here I would be grateful. Should we also rename the files to remove "clientError" from the name? Actually, the ticket mentions syncing unified CRUD tests, that might be what we should instead?

ping @baileympearson, thank you for reviewing my first PR, and giving me info to continue this!

@bajanam bajanam added the External Submission PR submitted from outside the team label Sep 16, 2022
@baileympearson
Copy link
Contributor

Hey @LinusU - thanks for this contribution. There are still some open questions about this ticket and at this time, it's not ready to be implemented. Our team will need to discuss the ticket in refinement to iron out some of the details.

We don't have the bandwidth to pick this up at the moment but we will put the ticket in our triage queue to revisit it when we get the chance and when we do implement it, we'll make sure you get credit for your contribution as well.

I think we can move forward with #3409 in the meantime though!

@LinusU
Copy link
Contributor Author

LinusU commented Sep 29, 2022

I understand, let me know if there is anything you want me to do here 👍

@dariakp dariakp added the tracked-in-jira Ticket filed in MongoDB's Jira system label Feb 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
External Submission PR submitted from outside the team tracked-in-jira Ticket filed in MongoDB's Jira system
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants