Hello Community

I have question regarding native golang DNS lookup as my app is compiled 
statically (CGO_ENABLED=0). For some reason this solution behaves 
unpredictable, having sometimes (few times a day) dns lookup >2s. I am 
using http-trace to get this number. I have tried to look into code whether 
there is possibility to drill-down to these 2s (no luck right now). My 
usecase is making quick http call to integration (optimal request total 
time < 500ms).

using
GODEBUG="netdns=2"
CGO_ENABLED=0
GOOS=linux
GOARCH=amd64

running in docker debian bookworm as k8s pod

logs:
go package net: confVal.netCgo = false  netGo = false                       
                                         go package net: cgo resolver not 
supported; using Go's DNS resolver      

I have checked the source code I have not seen much tracing information 
into why sometimes dns spikes occurs. Did I missed some option to get 
insights why dns lookup takes so long ? I cannot distinguish whether it is 
waiting for network call or some internal timeout.

Thank you

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
To view this discussion visit 
https://groups.google.com/d/msgid/golang-nuts/abce106d-27d4-42ed-91b5-72c4c6651206n%40googlegroups.com.

Reply via email to