Uploaded image for project: 'Java Driver'
  1. Java Driver
  2. JAVA-4423

DefaultDnsResolver should conditionally set Context.PROVIDER_URL to "dns:"

    • Type: Icon: Improvement Improvement
    • Resolution: Fixed
    • Priority: Icon: Minor - P4 Minor - P4
    • 4.5.0
    • Affects Version/s: None
    • Component/s: Connection Management
    • None
    • Minor Change
    • Not Needed

      Based on Oracle documentation on DNS Service Provider for the JNDI, Context.PROVIDER_URL ("java.naming.provider.url") may be used to specify a set of DNS servers to use. Currently, our DefaultDnsResolver always sets this environment property to "dns:" when creating InitialDirContext. This means that if a user specifies a URI with the dns scheme as a value of this property to override the set of DNS servers, the driver ignores that. Maybe we should only set Context.PROVIDER_URL if its value is not already a URI with the dns scheme.

            Assignee:
            jeff.yemin@mongodb.com Jeffrey Yemin
            Reporter:
            valentin.kovalenko@mongodb.com Valentin Kavalenka
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: