Sha256: 1a24552f5deb90710438e592702dc66794bee6d8cde84e6ac5657748bd92e826
Contents?: true
Size: 559 Bytes
Versions: 5
Compression:
Stored size: 559 Bytes
Contents
module AppPerfAgent module Plugin class << self def load_plugins pattern = File.join(File.dirname(__FILE__), 'plugin', '**', '*.rb') Dir.glob(pattern) do |f| begin require f rescue => e AppPerfAgent.logger.info "Error loading plugin '#{f}' : #{e}" AppPerfAgent.logger.info "#{e.backtrace.first}" end end end def plugins @plugins ||= ::AppPerfAgent::Plugin::Base .descendants .map(&:new) end end end end
Version data entries
5 entries across 5 versions & 1 rubygems