lib/sapience/configuration.rb in sapience-2.10 vs lib/sapience/configuration.rb in sapience-2.11

- old
+ new

@@ -6,11 +6,12 @@ # rubocop:disable ClassVars class Configuration attr_reader :default_level, :backtrace_level, :backtrace_level_index attr_writer :host attr_accessor :app_name, :ap_options, :appenders, :log_executor, :filter_parameters, - :metrics, :error_handler, :silent_active_record, :silent_rails, :silent_rack + :metrics, :error_handler, :silent_active_record, :silent_rails, :silent_rack, + :rails_ac_metrics SUPPORTED_EXECUTORS = %i(single_thread_executor immediate_executor).freeze DEFAULT = { log_level: :info, host: nil, @@ -21,10 +22,11 @@ error_handler: { silent: {} }, filter_parameters: %w(password password_confirmation), silent_active_record: false, silent_rails: false, silent_rack: false, + rails_ac_metrics: true, }.freeze # Initial default Level for all new instances of Sapience::Logger def initialize(options = {}) # rubocop:disable AbcSize fail ArgumentError, "options need to be a hash #{options.inspect}" unless options.is_a?(Hash) @@ -42,9 +44,10 @@ self.metrics = @options[:metrics] self.error_handler = @options[:error_handler] self.silent_active_record = @options[:silent_active_record] self.silent_rails = @options[:silent_rails] self.silent_rack = @options[:silent_rack] + self.rails_ac_metrics = @options[:rails_ac_metrics] end # Sets the global default log level def default_level=(level) @default_level = level