httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dean Gaudet <dgau...@arctic.org>
Subject Re: hstrerror() and herror() (fwd)
Date Mon, 30 Nov 1998 03:26:43 GMT
FYI: thread-safe DNS on the horizon. 

Doesn't mean that gethostbyname() will be thread-safe -- consider all the
ninnies that run NIS and other crap like that.

I suspect that for threaded apache, it'd be worthwhile having two options
-- do name lookups in an external (pre-forking) daemon using
gethostbyname() (most portable, essentially works for all systems, this is
the solution squid uses); or use bind 8.1.2++.

Dean

---------- Forwarded message ----------
To: bind-workers@isc.org
Subject: Re: hstrerror() and herror()
From: Paul Vixie <paul@vix.com>
Date: 23 Nov 1998 22:12:50 -0800

> Is it fair to assume that these two interfaces, as currently
> implemented in herror.c, are fairly stable and hence exportable and
> can be used by other applications.
> 
> They are currently exported in Solaris 7, but I have had requests
> to confirm that they are indeed stable interfaces. Thanks. Best wishes.

Neither one will be removed, but 8.1.2++ has made your question more
complex.  We've got a new resolver that allows "struct __res_state"'s
to be created and destroyed, so that a thread aware program can have
more than one query outstanding at any given time.  The old _res is
now thread-specific-data on systems which have threads.  Each resolver
context has its own h_errno.  So while herror() and hstrerror() will
still do "the right thing", a new interface will ultimately arise so
that the context-specific h_errno can be used where it's needed.
-- 
Paul Vixie <paul@vix.com>



Mime
View raw message