module RubyRabbitmqJanus::Tools::ConfigGem
Subclass for Config
Options about Gem
Public Instance Methods
cluster()
click to toggle source
@return [Boolean] Read option file for a janus cluster section
# File lib/rrj/tools/gem/config/gem.rb, line 14 def cluster @options['gem']['cluster']['enabled'].to_s.match?('true') || false end
environment()
click to toggle source
@return [String] Environment gem executed.
# File lib/rrj/tools/gem/config/gem.rb, line 47 def environment @options['gem']['environment'].to_s || 'development' end
Also aliased as: env
listener_admin_path()
click to toggle source
@return [String] Get path to classes in project calling this gem.
# File lib/rrj/tools/gem/config/gem.rb, line 41 def listener_admin_path @options['gem']['listener']['admin'].to_s || 'app/ruby_rabbitmq_janus/action_admin_events' end
listener_path()
click to toggle source
@return [String] Get path to classes in project calling this gem.
# File lib/rrj/tools/gem/config/gem.rb, line 35 def listener_path @options['gem']['listener']['public'].to_s || 'app/ruby_rabbitmq_janus/action_events' end
log_level()
click to toggle source
@return [Symbol] read configuration for log level used in this gem
# File lib/rrj/tools/gem/config/gem.rb, line 19 def log_level @options['gem']['log']['level'].upcase.to_sym || :INFO end
log_option()
click to toggle source
@return [String] read configuration for log option
# File lib/rrj/tools/gem/config/gem.rb, line 29 def log_option option = @options['gem']['log']['option'] option.empty? ? nil : option end
log_type()
click to toggle source
@return [Symbol] Read level to log
# File lib/rrj/tools/gem/config/gem.rb, line 24 def log_type @options['gem']['log']['type'].downcase.to_sym || :stdout end
object_relational_mapping()
click to toggle source
@return [String] Get orm used (mongoid or active_record)
# File lib/rrj/tools/gem/config/gem.rb, line 52 def object_relational_mapping @options['gem']['orm'].to_s || 'mongoid' end
Also aliased as: orm
program_name()
click to toggle source
@return [String] Get program name or GEM_NAME
# File lib/rrj/tools/gem/config/gem.rb, line 57 def program_name ENV['PROGRAM_NAME'] || RubyRabbitmqJanus::GEM_NAME end
Also aliased as: pg
public_queue_process()
click to toggle source
@return [Integer] get number of thread created for listen public queues
# File lib/rrj/tools/gem/config/gem.rb, line 67 def public_queue_process @options['gem']['process'] || 1 end
rspec_response()
click to toggle source
@return [String] Get path for json files contains a Janus
response
# File lib/rrj/tools/gem/config/gem.rb, line 62 def rspec_response @options['gem']['response_path'] || 'spec/responses' end