[JAVA-4018] Driver should ignore NXDomain DNS errors for TXT record lookup Created: 17/Feb/21 Updated: 28/Oct/23 Resolved: 15/Mar/22 |
|
| Status: | Closed |
| Project: | Java Driver |
| Component/s: | Configuration |
| Affects Version/s: | None |
| Fix Version/s: | 4.5.1 |
| Type: | Improvement | Priority: | Major - P3 |
| Reporter: | Jeffrey Yemin | Assignee: | Jeffrey Yemin |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||
| Case: | (copied to CRM) | ||||||||
| Backwards Compatibility: | Minor Change | ||||||||
| Documentation Changes: | Needed | ||||||||
| Description |
|
When presented with a mongodb+srv-schemed connection string, the driver looks up in DNS any TXT records associated with the host. If none are found, the driver correctly does not throw an exception. However, if the DNS server returns an NXDomain error (error code 3, "Non-Existent Domain), JNDI throws a java.naming.NameNotFoundException, the driver catches it, and throws a com.mongodb.MongoConfigurationException. The expected behavior is that NXDomain errors are also ignored. |
| Comments |
| Comment by Jeffrey Yemin [ 23/Mar/22 ] |
|
FYI, 4.5.1 has been released with a fix for this issue. |
| Comment by Githook User [ 15/Mar/22 ] |
|
Author: {'name': 'Jeff Yemin', 'email': 'jeff.yemin@mongodb.com', 'username': 'jyemin'}Message: Ignore NXDomain errors when looking up a TXT record (#890)
|
| Comment by Githook User [ 15/Mar/22 ] |
|
Author: {'name': 'Jeff Yemin', 'email': 'jeff.yemin@mongodb.com', 'username': 'jyemin'}Message: Ignore NXDomain errors when looking up a TXT record (#890)
|