upstreamWithStats is a wrapper around the [upstream.Upstream] interface that gathers statistics.
| 11 | // upstreamWithStats is a wrapper around the [upstream.Upstream] interface that |
| 12 | // gathers statistics. |
| 13 | type upstreamWithStats struct { |
| 14 | // upstream is the upstream DNS resolver. |
| 15 | upstream upstream.Upstream |
| 16 | |
| 17 | // err is the DNS lookup error, if any. |
| 18 | err error |
| 19 | |
| 20 | // queryDuration is the duration of the successful DNS lookup. |
| 21 | queryDuration time.Duration |
| 22 | } |
| 23 | |
| 24 | // type check |
| 25 | var _ upstream.Upstream = (*upstreamWithStats)(nil) |
nothing calls this directly
no outgoing calls
no test coverage detected