Re: [Rails] Re: Ruby-ldap timeout

2010-04-04 Thread Marcelo de Moraes Serpa
*bump* Does anyone have any idea on why it fails? Marcelo. On Fri, Apr 2, 2010 at 8:50 PM, Marcelo de Moraes Serpa wrote: > Correction. SystemTimer works when binding, but *does not work* with the > search / search2 method(s). If the LDAP server hangs for any reason, > SystemTimer fails to kil

Re: [Rails] Re: Ruby-ldap timeout

2010-04-02 Thread Marcelo de Moraes Serpa
Correction. SystemTimer works when binding, but *does not work* with the search / search2 method(s). If the LDAP server hangs for any reason, SystemTimer fails to kill the thread, and even though the Timeout::Error exception is thrown, it is only after much more time than what you define in the tim

Re: [Rails] Re: Ruby-ldap timeout

2010-04-01 Thread Marcelo de Moraes Serpa
Hi Jeff, Thanks! Every single day I'm amazed by what's possible with Ruby, the more I learn, the less I know, but I guess that's good :) This led me to the SystemTimer gem. The Timeout class was failing, I guess because it is external call that "cross the barriers", as explained here: http://ph7s

[Rails] Re: Ruby-ldap timeout

2010-04-01 Thread Jeff Lewis
Hi Marcelo, If that ldap lib doesn't include any timeout settings/params for timing out long-running ldap calls (which if you're talking about ruby- net-ldap, it doesn't at this time), then one way would be to wrap those potentially-long-running calls in ruby's timeout (http://ruby- doc.org/core/c