From da1af3a535bdabcf56a340e48c602346cd55a45d Mon Sep 17 00:00:00 2001 From: Zach Leslie Date: Tue, 10 Nov 2015 21:07:00 +0000 Subject: [PATCH] Add additional information in the search debug Adds information about the number of results returned for the given search. --- lib/puppet_x/ldapquery.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/puppet_x/ldapquery.rb b/lib/puppet_x/ldapquery.rb index 6b3ca37..aeadf22 100644 --- a/lib/puppet_x/ldapquery.rb +++ b/lib/puppet_x/ldapquery.rb @@ -88,7 +88,7 @@ module PuppetX end_time = Time.now time_delta = sprintf('%.3f', end_time - start_time) - Puppet.debug("Searching #{@base} for #{@attributes} using #{@filter} took #{time_delta} seconds") + Puppet.debug("Searching #{@base} for #{@attributes} using #{@filter} took #{time_delta} seconds and returned #{entries.length} results") return entries rescue Exception => e Puppet.debug('There was an error searching LDAP #{e.message}')