Bug 64318 - DNS Cache Manager - custom DNS resolver doesn't use system resolver by default
Summary: DNS Cache Manager - custom DNS resolver doesn't use system resolver by default
Alias: None
Product: JMeter - Now in Github
Classification: Unclassified
Component: HTTP (show other bugs)
Version: 5.2.1
Hardware: PC All
: P2 minor (vote)
Target Milestone: JMETER_5.3.0
Assignee: JMeter issues mailing list
Keywords: FixedInTrunk
Depends on:
Reported: 2020-04-07 07:45 UTC by Konstantin Kalinin
Modified: 2021-10-16 11:58 UTC (History)
0 users

Example configuration (28.46 KB, image/png)
2020-04-07 07:45 UTC, Konstantin Kalinin

Note You need to log in before you can comment on or make changes to this bug.
Description Konstantin Kalinin 2020-04-07 07:45:07 UTC
Created attachment 37151 [details]
Example configuration

Imagine we have the component config like on the screenshot in attachment.
According to documentation (https://jmeter.apache.org/usermanual/component_reference.html#DNS_Cache_Manager), the component should use system DNS servers for everything except hosts listed in the static table.

In fact, the component returns `null` for every hostname not present in the table.

P.S. If the community confirms the bug, I can try fixing it.
Comment 1 Felix Schumacher 2021-01-02 20:18:33 UTC
I think you are right and it should fallback to the system DNS resolver.

Patches are welcome (sorry for the late reply)
Comment 2 Felix Schumacher 2021-01-26 17:21:52 UTC
@Konstantin, could you test the next build from trunk or nightly?

commit da5fb8319b02666062e415f4823ee4bcde2a8639
Author: Felix Schumacher <felix.schumacher@internetallee.de>
AuthorDate: Sat Jan 2 21:26:44 2021 +0100

    DNS Cache Manager - custom DNS resolver does not use system resolver by default
    Bugzilla Id: 64318
 .../apache/jmeter/protocol/http/control/DNSCacheManager.java   |  7 +++----
 .../jmeter/protocol/http/control/DNSCacheManagerSpec.groovy    | 10 ++++++++++
 xdocs/changes.xml                                              |  1 +
 3 files changed, 14 insertions(+), 4 deletions(-)
Comment 3 Felix Schumacher 2021-10-16 11:58:08 UTC
Closed, as no feedback probably means, it works.
Comment 4 The ASF infrastructure team 2022-09-24 20:38:19 UTC
This issue has been migrated to GitHub: https://github.com/apache/jmeter/issues/5287