ruby-activeldap-debug 0.7.3 → 0.7.4
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/activeldap.rb +1 -1
- data/lib/activeldap/base.rb +4 -20
- data/lib/activeldap/ldap.rb +1 -1
- metadata +2 -2
data/lib/activeldap.rb
CHANGED
data/lib/activeldap/base.rb
CHANGED
@@ -273,7 +273,7 @@ module ActiveLDAP
|
|
273
273
|
yield @@conn
|
274
274
|
rescue => e
|
275
275
|
# Raise an LDAP error instead of RuntimeError or whatever
|
276
|
-
@@logger.debug("Converting #{e} to useful exception")
|
276
|
+
@@logger.debug("Converting '#{e.inspect}' to useful exception")
|
277
277
|
raise *LDAP::err2exception(@@conn.err) if @@conn.err != 0
|
278
278
|
# Else reraise
|
279
279
|
@@logger.debug('Reraising')
|
@@ -287,23 +287,7 @@ module ActiveLDAP
|
|
287
287
|
message = exc.message unless exc.nil?
|
288
288
|
@@logger.error(message)
|
289
289
|
raise TimeoutError, message
|
290
|
-
rescue RuntimeError => e
|
291
|
-
@@logger.error("#{e.class} exception occurred in connection block")
|
292
|
-
@@logger.error("Exception message: #{e.message}")
|
293
|
-
@@logger.error("Exception backtrace: #{e.backtrace}")
|
294
|
-
@@logger.error(exc.message) unless exc.nil?
|
295
|
-
retry if try_reconnect and Base.reconnect()
|
296
|
-
raise exc unless exc.nil?
|
297
|
-
return nil
|
298
|
-
rescue LDAP::ServerDown => e
|
299
|
-
@@logger.error("#{e.class} exception occurred in connection block")
|
300
|
-
@@logger.error("Exception message: #{e.message}")
|
301
|
-
@@logger.error("Exception backtrace: #{e.backtrace}")
|
302
|
-
@@logger.error(exc.message) unless exc.nil?
|
303
|
-
retry if try_reconnect and Base.reconnect()
|
304
|
-
raise exc unless exc.nil?
|
305
|
-
return nil
|
306
|
-
rescue LDAP::ResultError => e
|
290
|
+
rescue LDAP::ServerDown, LDAP::ResultError, RuntimeError => e
|
307
291
|
@@logger.error("#{e.class} exception occurred in connection block")
|
308
292
|
@@logger.error("Exception message: #{e.message}")
|
309
293
|
@@logger.error("Exception backtrace: #{e.backtrace}")
|
@@ -452,7 +436,7 @@ module ActiveLDAP
|
|
452
436
|
if config.respond_to?(:has_key?)
|
453
437
|
attr = config[:attribute] || dnattr()
|
454
438
|
val = config[:value] || '*'
|
455
|
-
objects = config[:objects]
|
439
|
+
objects = config[:objects] unless config[:objects].nil?
|
456
440
|
end
|
457
441
|
|
458
442
|
Base.connection(ConnectionError.new("Failed in #{self.class}#find(#{config.inspect})")) do |conn|
|
@@ -494,7 +478,7 @@ module ActiveLDAP
|
|
494
478
|
if config.respond_to?(:has_key?)
|
495
479
|
val = config[:value] || '*'
|
496
480
|
attr = config[:attribute] || dnattr()
|
497
|
-
objects = config[:objects]
|
481
|
+
objects = config[:objects] unless config[:objects].nil?
|
498
482
|
end
|
499
483
|
|
500
484
|
matches = []
|
data/lib/activeldap/ldap.rb
CHANGED
metadata
CHANGED
@@ -3,8 +3,8 @@ rubygems_version: 0.8.11
|
|
3
3
|
specification_version: 1
|
4
4
|
name: ruby-activeldap-debug
|
5
5
|
version: !ruby/object:Gem::Version
|
6
|
-
version: 0.7.
|
7
|
-
date: 2006-05
|
6
|
+
version: 0.7.4
|
7
|
+
date: 2006-06-05 00:00:00 +01:00
|
8
8
|
summary: Ruby/ActiveLDAP is a object-oriented API to LDAP
|
9
9
|
require_paths:
|
10
10
|
- lib
|