class AppInsights::BaseInstaller
Attributes
app[RW]
filename[RW]
logger[RW]
root[RW]
Public Class Methods
new(app, root, filename = nil, logger = nil)
click to toggle source
# File lib/appinsights/installers/base.rb, line 5 def initialize(app, root, filename = nil, logger = nil) @app, @root, @filename, @logger = app, root, filename, logger end
Public Instance Methods
install()
click to toggle source
# File lib/appinsights/installers/base.rb, line 9 def install AppInsights::ConfigLoader.new @root, @filename AppInsights::Middlewares.enabled.each do |middleware, args| @app.use middleware, *args.values end rescue AppInsights::ConfigFileNotFound => e logger.error e.message logger.info config_file_not_found_message end
Private Instance Methods
config_file_not_found_message()
click to toggle source
# File lib/appinsights/installers/base.rb, line 26 def config_file_not_found_message <<-EOS Place your config file `application_insights.toml` under the `config` or root directory of your application. Check the README for manual installation. EOS end