Uploaded image for project: 'Node.js Driver'
  1. Node.js Driver
  2. NODE-6451

Implement retry on DNS failure

    • Type: Icon: Improvement Improvement
    • Resolution: Fixed
    • Priority: Icon: Unknown Unknown
    • 6.13.0
    • Affects Version/s: None
    • Component/s: None
    • 2
    • Not Needed
    • Not Needed

      First implementation for DRIVERS-2757.

      Use Case

      As a... Node.js driver user
      I want... DNS lookup failures to be retried automatically on the driver side
      So that... I don't have to build retry logic into my application

      User Experience

      • Less frequent connection failure errors

      Dependencies

      • None

      Risks/Unknowns

      • What could go wrong while implementing this change? (e.g., performance, inadvertent behavioral changes in adjacent functionality, existing tech debt, etc)
      • Which actual errors should we retry? Only transient ones or all?
      • Is there an opportunity to improve existing documentation on this subject?
        • Users experience the DNS error at the call site for client.connect() so we'll update the API docs there. And there will be release notes for this.

      Acceptance Criteria

      Implementation Requirements

      • Retry the initial srv txt lookups once on failure: TIMEOUT

      Testing Requirements

      • Use the dns seedlist spec prose test SRV records to hit a real DNS record and use sinon to fake timeout errors.
        • Note: try to write the testing in a way that is potentially adaptable as a general drivers prose test. If drivers have a DNS stubbing system they can do this, otherwise, this isn't something that can be made common easily.

      Documentation Requirements

      • Update client.connect() API doc.

      Follow Up Requirements

            Assignee:
            neal.beeken@mongodb.com Neal Beeken
            Reporter:
            daria.pardue@mongodb.com Daria Pardue
            Aditi Khare (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: