summaryrefslogtreecommitdiffstats
path: root/lib/puppet/defaults.rb
diff options
context:
space:
mode:
authorBrice Figureau <brice-puppet@daysofwonder.com>2010-07-30 22:12:46 +0200
committermarkus <markus@AVA-351181.(none)>2010-08-03 15:19:22 -0700
commitf54d843e4e585274f724c97f1b10288d8798a63b (patch)
tree9d7a583f68518c3163d064c1f8821a12793dcc72 /lib/puppet/defaults.rb
parent2c21faec04f0029bfef381dfa4341a916ee28967 (diff)
downloadpuppet-f54d843e4e585274f724c97f1b10288d8798a63b.tar.gz
puppet-f54d843e4e585274f724c97f1b10288d8798a63b.tar.xz
puppet-f54d843e4e585274f724c97f1b10288d8798a63b.zip
Fix #4461 - attempt to fix another performance issue
During a profiling of a 2.6.1rc1 puppet master, I found that we spend a lot of time and efforts in Puppet::Util::Autoload#module_directories. Since this method is doing a bunch of filesystem access, this process is slow. In fact each time we were evaluating a resource or trying to find if a given resource was a builtin type we ended up scanning the whole module directories for the given environment. This patch attempts to fix this performance issue by caching the module_directories output for the either the time of the compilation or an agent configurer run (since this stuff looks like to be shared for both compilation and catalog evaluation). With this patch, my compilation time for 2k resources went from 5.91s to 3.71s (second run each time to allievate parsing time).. Signed-off-by: Brice Figureau <brice-puppet@daysofwonder.com> Edited to fix a typo [#4434] Signed-off-by: Jesse Wolfe <jes5199@gmail.com>
Diffstat (limited to 'lib/puppet/defaults.rb')
0 files changed, 0 insertions, 0 deletions