Varnish only resolve the ip on startup

Guillaume Quintard guillaume.quintard at gmail.com
Mon Oct 4 17:15:47 UTC 2021


On Mon, Oct 4, 2021 at 9:49 AM Dridi Boukelmoune <dridi at varni.sh> wrote:

> One problem I have (and that you should be familiar with) is that
> portable interfaces we have that *respect* the system configuration
> (hosts file, nsswitch configuration etc) are not providing enough
> information. For example it becomes cumbersome to resolve SRV records
> or even get the TTL of individual records for a DNS resolution in a
> *portable* fashion.
>
> When you put it like this, it sounds simple enough (dare I say
> simplistic?) but what I see is a sizeable can of worms.
>

That sounds like a bit of a strawman to me. getaddrinfo and connect are
standard, and that's about all we should need. Applications are supposed
(in general) to just use whatever gai give them. We can call them every
time we need a new connection so we don't worry about TTL, and we just
disregard SRV records.
The vast majority of users don't need SRV (yet?), and don't expect the
application to optimize DNS calls, but they do complain that giving a
hostname to VCL doesn't work.

Let's just provide basic, expected functionality out of the box, and leave
the fancier features to vmod_goto and vmod_dynamic.

--
Guillaume Quintard
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.varnish-cache.org/lists/pipermail/varnish-misc/attachments/20211004/3ce9c519/attachment-0001.html>


More information about the varnish-misc mailing list