Module: Scales::Worker::Application::Rails

Defined in:
lib/scales-worker/application/rails.rb

Constant Summary collapse

@@app =
nil

Class Method Summary collapse

Class Method Details

.initialize_app!Object Also known as: app, initialize_environment!



11
12
13
14
15
# File 'lib/scales-worker/application/rails.rb', line 11

def initialize_app!
  @@app ||= load_application.initialize!
  raise "Could not load Rails Application" if @@app.nil?
  @@app
end

.nameObject



19
20
21
# File 'lib/scales-worker/application/rails.rb', line 19

def name
  "Rails #{app.class.to_s.split("::").first} (#{ENV['RAILS_ENV']})"
end