[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
dns and software, was Re: Reliable Cloud host ?
- Subject: dns and software, was Re: Reliable Cloud host ?
- From: mysidia at gmail.com (Jimmy Hess)
- Date: Thu, 1 Mar 2012 00:15:54 -0600
- In-reply-to: <6252359949770844391@unknownmsgid>
- References: <[email protected]> <[email protected]> <CAP-guGV++cqRfNs9aC0zxRB0rLP4LgCAOTA+55ehELQP3QiFUA@mail.gmail.com> <[email protected]> <CAP-guGVq=OPwZP7Fdyzv0_Ety4_5zDvBqXwSY1sUMpJGXDiGug@mail.gmail.com> <[email protected]> <CAP-guGVA4eHv0K=U=x2B-WPYDy2RQ7ZE1Di2AHc+dmA_huyGzA@mail.gmail.com> <[email protected]> <6252359949770844391@unknownmsgid>
On Mon, Feb 27, 2012 at 10:57 PM, Matt Addison
<matt.addison at lists.evilgeni.us> wrote:
> gai/gni do not return TTL values on any platforms I'm aware of, the
> only way to get TTL currently is to use a non standard resolver (e.g.
> lwres). The issue is application developers not calling gai every time
GAI/GNI do not return TTL values, but this should not be a problem.
If they were to return anything, it should not be a TTL, but a time()
value, after which
the result may no longer be used.
One way to achieve that would be for GAI to return an opaque structure
that contained the IP and such a value, in a manner consumable by the
sockets API, and adjust connect() to return an error if passed a
structure containing a ' returned time + TTL' in the past.
TTL values are a DNS resolver function; the application consuming the
sockets API
should not be concerned about details of the DNS protocol.
All the application developer should need to know is that you invoke
GAI/GNI and wait for a response.
Once you have that response, it is permissible to use the value immediately,
but you may not store or re-use that value for more than a few seconds.
If you require that value again later, then you invoke GAI/GNI again;
any caching details
are the concern of the resolver library developer who has implemented GAI/GNI.
--
-JH