apr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bill Stoddard" <b...@wstoddard.com>
Subject Re: [PATCH] LDAP support for apr-util
Date Tue, 31 Jul 2001 14:04:24 GMT
> For reliability reasons, you probably want to use asynchronous bindings.
>
> Do:
> ldap_init
> ldap_simple_bind
> ldap_result
>
> If the LDAP server is unreachable, you'll block waiting for the server
> to respond.  It's really preferable to use asynchronous bindings (I've
> used 1 second timeouts in the past).
>
> What I've typically done (see above URL) is to do the connection to the
> server asynchronously and then everything else synchronously.  If the
> server dies in the middle, you are screwed.  But, to be done "right,"
> you probably want to use asynchronous everywhere.  Something like the
> timeout values in APR for sockets.  I dunno - it's a thought.
>
>

Isn't this only useful if your application is able to support event driven (or async) I/O?
The connect to the LDAP server definitely needs to have a timeout, regardless.

Bill


Mime
View raw message