udns questions

Michael Tokarev mjt at corpit.ru
Fri Apr 22 20:07:25 MSD 2005


Markus,

I've released 0.0.7 version a few days ago, which, among other things,
contains some preparation and simplifications (together with small but
noticeable change in query submitting API - it become a bit easier to
use without one extra parameter), to allow usage of eg per-query
timeouts if one wants to.

Now I'm thinking whenever more per-query customisation is really
necessary, including the timeouts.

I *guess* (not sure, but just really guessing) that you will want,
say, two "types" of queries - "fast" ones and "slow", or "normal"
ones.  Maybe more than two, but I don't think it's the case.
And for that, having two contexts (the "big" ones -- remember
the context is where multiple queries can be executed in parallel),
looks like a way to go.  Depends on the usage pattern still, --
maybe i'm wrong.

Right now it's a matter of changing about 5 lines of code and
adding a routine to have per-request timeouts.  And ofcourse
extending struct dns_query to hold the two new variables
(timeout and number of retries).  But I think that per-request
timeout is somewhat overkill for most if not all usages,
probably even including yours.

How do you think?

Thanks.

/mjt


More information about the udns mailing list