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

feat(NODE-6451): retry SRV and TXT lookup for DNS timeout errors #4375

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

nbbeeken
Copy link
Contributor

Description

What is changing?

  • When the dns.TIMEOUT error is detected when resolving SRV and TXT the driver will try those look ups again.
Is there new documentation needed for these changes?

Yes API updated

What is the motivation for this change?

In some environments (possibly FAAS?) it has been observed that DNS look ups can fail transiently. The driver can attempt to mitigate these with a retry.

Release Highlight

DNS SRV & TXT look up timeouts are retried

To mitigate the potentially transient DNS timeout error, the driver now catches and retries the DNS lookups upon resolving a mongodb+srv:// style connection string.

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

@nbbeeken nbbeeken force-pushed the NODE-6451-retry-dns branch from 84809c7 to 35f723b Compare January 21, 2025 19:32
@nbbeeken nbbeeken marked this pull request as ready for review January 21, 2025 20:24
@aditi-khare-mongoDB aditi-khare-mongoDB self-assigned this Jan 22, 2025
@aditi-khare-mongoDB aditi-khare-mongoDB added the Primary Review In Review with primary reviewer, not yet ready for team's eyes label Jan 22, 2025
Copy link
Contributor

@aditi-khare-mongoDB aditi-khare-mongoDB left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, putting in team review!

@aditi-khare-mongoDB aditi-khare-mongoDB added Team Review Needs review from team and removed Primary Review In Review with primary reviewer, not yet ready for team's eyes labels Jan 22, 2025
@baileympearson baileympearson changed the title feat(NODE-6451): retry DNS timeout on SRV and TXT lookup feat(NODE-6451): retry SRV and TXT lookup for DNS timeout errors Jan 23, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Team Review Needs review from team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants