lib/elastic_apm/config.rb in elastic-apm-3.9.0 vs lib/elastic_apm/config.rb in elastic-apm-3.10.0

- old
+ new

@@ -85,10 +85,11 @@ option :source_lines_error_library_frames, type: :int, default: 0 option :source_lines_span_app_frames, type: :int, default: 5 option :source_lines_span_library_frames, type: :int, default: 0 option :span_frames_min_duration, type: :float, default: '5ms', converter: Duration.new(default_unit: 'ms') option :stack_trace_limit, type: :int, default: 999_999 + option :transaction_ignore_urls, type: :list, default: [], converter: WildcardPatternList.new option :transaction_max_spans, type: :int, default: 500 option :transaction_sample_rate, type: :float, default: 1.0 option :use_elastic_traceparent_header, type: :bool, default: true option :use_legacy_sql_parser, type: :bool, default: false option :verify_server_cert, type: :bool, default: true @@ -232,10 +233,17 @@ warn '[DEPRECATED] The option default_tags has been renamed to ' \ 'default_labels.' self.default_labels = value end + def ignore_url_patterns=(value) + warn '[DEPRECATED] The option ignore_url_patterns is being removed. ' \ + 'Consider using transaction_ignore_urls instead.' + + set(:ignore_url_patterns, value) + end + def custom_key_filters=(value) unless value == self.class.schema[:custom_key_filters][:default] warn '[DEPRECATED] The option custom_key_filters is being removed. ' \ 'See sanitize_field_names for an alternative.' end @@ -316,10 +324,10 @@ self.framework_name ||= 'Ruby on Rails' self.framework_version ||= ::Rails::VERSION::STRING self.logger ||= ::Rails.logger self.__root_path = ::Rails.root.to_s - self.__view_paths = ::ActionController::Base.view_paths.map(&:to_s) + self.__view_paths = app.config.paths['app/views'].existent + [::Rails.root.to_s] end def rails_app_name(app) if ::Rails::VERSION::MAJOR >= 6 app.class.module_parent_name