Baoyuantop commented on issue #10505: URL: https://github.com/apache/apisix/issues/10505#issuecomment-3317305846
> Here is a minimal reproduction: https://github.com/perry2of5/apisix-docker > > `git clone [email protected]:perry2of5/apisix-docker.git` `cd apisix-docker` `docker build -t apisix-demo .` `docker run -p 8080:8080 apisix-demo` > > ## route with variable not in hostname works without errors > In a separate window, works without errors: > > ``` > % curl http://localhost:8080/api/supabase-config/v1 > {"supabase_url":"https://somehashvalue.supabase.co", "supabase_publishable_key":"blah-blah-blah"} > ``` > > accompanying apisix log: > > ``` > 192.168.65.1 - - [16/Sep/2025:05:05:49 +0000] localhost:8080 "GET /api/supabase-config/v1 HTTP/1.1" 200 108 0.000 "-" "curl/8.7.1" - - - "http://localhost:8080" > ``` > > ## hostname shows errors > ``` > % curl http://localhost:8080/api/somename/v1/always/there/look/ma > { > "args": {}, > "data": "", > "files": {}, > "form": {}, > "headers": { > "Accept": "*/*", > "Host": "httpbin.org", > "User-Agent": "curl/8.7.1", > "X-Amzn-Trace-Id": "Root=1-68c8f042-5a6cd9265f935e2b422a46eb", > "X-Forwarded-Host": "localhost" > }, > "json": null, > "method": "GET", > "origin": "192.168.65.1, 108.204.120.162", > "url": "http://localhost/anything/always/there/look/ma" > } > ``` > > And the apisix logs with the misleading errors: > > ``` > 2025/09/16 05:06:09 [error] 52#52: *2855 [lua] resolver.lua:80: parse_domain(): failed to parse domain: ${{HTTPBIN_SERVER}}, error: failed to query the DNS server: dns server error: 3 name error, client: 192.168.65.1, server: _, request: "GET /api/somename/v1/always/there/look/ma HTTP/1.1", host: "localhost:8080" > 2025/09/16 05:06:09 [error] 52#52: *2855 [lua] upstream.lua:97: parse_domain_for_nodes(): dns resolver domain: ${{HTTPBIN_SERVER}} error: failed to query the DNS server: dns server error: 3 name error, client: 192.168.65.1, server: _, request: "GET /api/somename/v1/always/there/look/ma HTTP/1.1", host: "localhost:8080" > 192.168.65.1 - - [16/Sep/2025:05:06:10 +0000] localhost:8080 "GET /api/somename/v1/always/there/look/ma HTTP/1.1" 200 414 1.038 "-" "curl/8.7.1" 54.227.118.219:80 200 0.930 "http://httpbin.org/anything/always/there/look/ma" > ``` It's a bit strange that I didn't see the expected error log after following the steps here. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
