newrelic_rpm 3.6.7.159 → 3.6.8.164
Sign up to get free protection for your applications and to get access to all the features.
- data/CHANGELOG +14 -0
- data/lib/new_relic/agent/agent.rb +38 -35
- data/lib/new_relic/agent/agent_logger.rb +6 -47
- data/lib/new_relic/agent/beacon_configuration.rb +10 -4
- data/lib/new_relic/agent/browser_monitoring.rb +39 -33
- data/lib/new_relic/agent/commands/agent_command.rb +4 -4
- data/lib/new_relic/agent/commands/agent_command_router.rb +72 -10
- data/lib/new_relic/agent/commands/thread_profiler_session.rb +110 -0
- data/lib/new_relic/agent/commands/xray_session.rb +55 -0
- data/lib/new_relic/agent/commands/xray_session_collection.rb +158 -0
- data/lib/new_relic/agent/configuration/default_source.rb +61 -24
- data/lib/new_relic/agent/configuration/mask_defaults.rb +2 -2
- data/lib/new_relic/agent/configuration/server_source.rb +1 -1
- data/lib/new_relic/agent/instrumentation/action_controller_subscriber.rb +2 -0
- data/lib/new_relic/agent/instrumentation/controller_instrumentation.rb +4 -10
- data/lib/new_relic/agent/instrumentation/rails3/action_controller.rb +10 -11
- data/lib/new_relic/agent/memory_logger.rb +52 -0
- data/lib/new_relic/agent/new_relic_service.rb +4 -0
- data/lib/new_relic/agent/request_sampler.rb +32 -13
- data/lib/new_relic/agent/samplers/cpu_sampler.rb +6 -3
- data/lib/new_relic/agent/threading/agent_thread.rb +2 -1
- data/lib/new_relic/agent/threading/backtrace_node.rb +80 -27
- data/lib/new_relic/agent/threading/backtrace_service.rb +264 -0
- data/lib/new_relic/agent/threading/thread_profile.rb +79 -118
- data/lib/new_relic/agent/transaction/developer_mode_sample_buffer.rb +56 -0
- data/lib/new_relic/agent/transaction/force_persist_sample_buffer.rb +25 -0
- data/lib/new_relic/agent/transaction/slowest_sample_buffer.rb +25 -0
- data/lib/new_relic/agent/transaction/transaction_sample_buffer.rb +86 -0
- data/lib/new_relic/agent/transaction/xray_sample_buffer.rb +64 -0
- data/lib/new_relic/agent/transaction.rb +25 -4
- data/lib/new_relic/agent/transaction_sample_builder.rb +6 -10
- data/lib/new_relic/agent/transaction_sampler.rb +47 -202
- data/lib/new_relic/agent/worker_loop.rb +47 -39
- data/lib/new_relic/agent.rb +1 -1
- data/lib/new_relic/build.rb +2 -2
- data/lib/new_relic/coerce.rb +8 -0
- data/lib/new_relic/control/instance_methods.rb +1 -0
- data/lib/new_relic/rack/browser_monitoring.rb +15 -1
- data/lib/new_relic/rack/developer_mode.rb +1 -1
- data/lib/new_relic/transaction_sample.rb +20 -5
- data/lib/new_relic/version.rb +1 -1
- data/newrelic.yml +4 -6
- data/newrelic_rpm.gemspec +1 -1
- data/test/agent_helper.rb +11 -0
- data/test/environments/lib/environments/runner.rb +5 -1
- data/test/environments/rails21/Gemfile +2 -2
- data/test/environments/rails22/Gemfile +2 -2
- data/test/environments/rails23/Gemfile +2 -2
- data/test/environments/rails31/Gemfile +2 -2
- data/test/environments/rails32/Gemfile +2 -2
- data/test/multiverse/suites/agent_only/marshaling_test.rb +1 -1
- data/test/multiverse/suites/agent_only/testing_app.rb +6 -0
- data/test/multiverse/suites/agent_only/thread_profiling_test.rb +5 -5
- data/test/multiverse/suites/agent_only/xray_sessions_test.rb +163 -0
- data/test/multiverse/suites/rails/request_statistics_test.rb +2 -2
- data/test/multiverse/suites/rails/view_instrumentation_test.rb +20 -21
- data/test/new_relic/agent/agent/connect_test.rb +0 -10
- data/test/new_relic/agent/agent_test.rb +27 -44
- data/test/new_relic/agent/browser_monitoring_test.rb +0 -52
- data/test/new_relic/agent/commands/agent_command_router_test.rb +150 -12
- data/test/new_relic/agent/commands/{thread_profiler_test.rb → thread_profiler_session_test.rb} +58 -19
- data/test/new_relic/agent/commands/xray_session_collection_test.rb +332 -0
- data/test/new_relic/agent/commands/xray_session_test.rb +42 -0
- data/test/new_relic/agent/configuration/manager_test.rb +2 -1
- data/test/new_relic/agent/configuration/server_source_test.rb +10 -10
- data/test/new_relic/agent/cpu_sampler_test.rb +50 -0
- data/test/new_relic/agent/instrumentation/action_controller_subscriber_test.rb +31 -0
- data/test/new_relic/agent/instrumentation/queue_time_test.rb +0 -1
- data/test/new_relic/agent/instrumentation/sequel_test.rb +1 -1
- data/test/new_relic/agent/instrumentation/task_instrumentation_test.rb +0 -1
- data/test/new_relic/agent/memory_logger_test.rb +53 -0
- data/test/new_relic/agent/new_relic_service_test.rb +1 -1
- data/test/new_relic/agent/pipe_channel_manager_test.rb +4 -5
- data/test/new_relic/agent/request_sampler_test.rb +70 -20
- data/test/new_relic/agent/rules_engine_test.rb +6 -0
- data/test/new_relic/agent/threading/agent_thread_test.rb +2 -2
- data/test/new_relic/agent/threading/backtrace_node_test.rb +110 -17
- data/test/new_relic/agent/threading/backtrace_service_test.rb +567 -0
- data/test/new_relic/agent/threading/fake_thread.rb +4 -0
- data/test/new_relic/agent/threading/thread_profile_test.rb +141 -217
- data/test/new_relic/agent/threading/threaded_test_case.rb +3 -8
- data/test/new_relic/agent/transaction/developer_mode_sample_buffer_test.rb +69 -0
- data/test/new_relic/agent/transaction/force_persist_sample_buffer_test.rb +52 -0
- data/test/new_relic/agent/transaction/slowest_sample_buffer_test.rb +67 -0
- data/test/new_relic/agent/transaction/xray_sample_buffer_test.rb +71 -0
- data/test/new_relic/agent/transaction_sampler_test.rb +171 -307
- data/test/new_relic/agent/transaction_test.rb +33 -5
- data/test/new_relic/agent/worker_loop_test.rb +33 -11
- data/test/new_relic/coerce_test.rb +13 -0
- data/test/new_relic/fake_collector.rb +26 -3
- data/test/new_relic/multiverse_helpers.rb +2 -0
- data/test/new_relic/rack/browser_monitoring_test.rb +12 -0
- data/test/new_relic/rack/developer_mode_test.rb +2 -2
- data/test/new_relic/transaction_sample_test.rb +19 -2
- data/test/performance/lib/performance/console_reporter.rb +1 -1
- data/test/performance/lib/performance/test_case.rb +7 -3
- data/test/performance/script/runner +3 -0
- data/test/performance/suites/thread_profiling.rb +83 -0
- data/test/test_helper.rb +2 -2
- data.tar.gz.sig +0 -0
- metadata +32 -32
- metadata.gz.sig +1 -1
- data/lib/new_relic/agent/commands/thread_profiler.rb +0 -80
@@ -0,0 +1,110 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
# This file is distributed under New Relic's license terms.
|
3
|
+
# See https://github.com/newrelic/rpm/blob/master/LICENSE for complete details.
|
4
|
+
|
5
|
+
require 'new_relic/agent/threading/agent_thread'
|
6
|
+
require 'new_relic/agent/threading/backtrace_service'
|
7
|
+
require 'new_relic/agent/threading/thread_profile'
|
8
|
+
|
9
|
+
module NewRelic
|
10
|
+
module Agent
|
11
|
+
module Commands
|
12
|
+
|
13
|
+
class ThreadProfilerSession
|
14
|
+
|
15
|
+
def initialize(backtrace_service)
|
16
|
+
@backtrace_service = backtrace_service
|
17
|
+
end
|
18
|
+
|
19
|
+
def handle_start_command(agent_command)
|
20
|
+
raise_unsupported_error unless NewRelic::Agent::Threading::BacktraceService.is_supported?
|
21
|
+
raise_thread_profiler_disabled unless enabled?
|
22
|
+
raise_already_started_error if running?
|
23
|
+
start(agent_command)
|
24
|
+
end
|
25
|
+
|
26
|
+
def handle_stop_command(agent_command)
|
27
|
+
report_data = agent_command.arguments.fetch("report_data", true)
|
28
|
+
stop(report_data)
|
29
|
+
end
|
30
|
+
|
31
|
+
def start(agent_command)
|
32
|
+
NewRelic::Agent.logger.debug("Starting Thread Profiler.")
|
33
|
+
profile = @backtrace_service.subscribe(
|
34
|
+
NewRelic::Agent::Threading::BacktraceService::ALL_TRANSACTIONS,
|
35
|
+
agent_command.arguments
|
36
|
+
)
|
37
|
+
|
38
|
+
@started_at = Time.now
|
39
|
+
@duration = profile.duration if profile
|
40
|
+
end
|
41
|
+
|
42
|
+
def stop(report_data)
|
43
|
+
return unless running?
|
44
|
+
NewRelic::Agent.logger.debug("Stopping Thread Profiler.")
|
45
|
+
@finished_profile = @backtrace_service.harvest(NewRelic::Agent::Threading::BacktraceService::ALL_TRANSACTIONS)
|
46
|
+
@backtrace_service.unsubscribe(NewRelic::Agent::Threading::BacktraceService::ALL_TRANSACTIONS)
|
47
|
+
@finished_profile = nil if !report_data
|
48
|
+
end
|
49
|
+
|
50
|
+
def harvest
|
51
|
+
NewRelic::Agent.logger.debug("Harvesting from Thread Profiler #{@finished_profile.to_log_description unless @finished_profile.nil?}")
|
52
|
+
profile = @finished_profile
|
53
|
+
@backtrace_service.profile_agent_code = false
|
54
|
+
@finished_profile = nil
|
55
|
+
@started_at = nil
|
56
|
+
profile
|
57
|
+
end
|
58
|
+
|
59
|
+
def enabled?
|
60
|
+
NewRelic::Agent.config[:'thread_profiler.enabled']
|
61
|
+
end
|
62
|
+
|
63
|
+
def running?
|
64
|
+
@backtrace_service.subscribed?(NewRelic::Agent::Threading::BacktraceService::ALL_TRANSACTIONS)
|
65
|
+
end
|
66
|
+
|
67
|
+
def ready_to_harvest?(disconnecting=false)
|
68
|
+
(running? && disconnecting) || past_time? || stopped?
|
69
|
+
end
|
70
|
+
|
71
|
+
def past_time?
|
72
|
+
@started_at && (Time.now > @started_at + @duration)
|
73
|
+
end
|
74
|
+
|
75
|
+
def stopped?
|
76
|
+
!!@finished_profile
|
77
|
+
end
|
78
|
+
|
79
|
+
private
|
80
|
+
|
81
|
+
def raise_command_error(msg)
|
82
|
+
raise NewRelic::Agent::Commands::AgentCommandRouter::AgentCommandError.new(msg)
|
83
|
+
end
|
84
|
+
|
85
|
+
def raise_unsupported_error
|
86
|
+
msg = <<-EOF
|
87
|
+
Thread profiling is only supported on 1.9.2 and greater versions of Ruby.
|
88
|
+
We detected running agents capable of profiling, but the profile started with
|
89
|
+
an agent running Ruby #{RUBY_VERSION}.
|
90
|
+
|
91
|
+
Profiling again might select an appropriate agent, but we recommend running a
|
92
|
+
consistent version of Ruby across your application for better results.
|
93
|
+
EOF
|
94
|
+
raise_command_error(msg)
|
95
|
+
end
|
96
|
+
|
97
|
+
def raise_thread_profiler_disabled
|
98
|
+
msg = "Not starting Thread Profiler because of config 'thread_profiler.enabled' = #{enabled?}"
|
99
|
+
raise_command_error(msg)
|
100
|
+
end
|
101
|
+
|
102
|
+
def raise_already_started_error
|
103
|
+
msg = "Profile already in progress. Ignoring agent command to start another."
|
104
|
+
raise_command_error(msg)
|
105
|
+
end
|
106
|
+
|
107
|
+
end
|
108
|
+
end
|
109
|
+
end
|
110
|
+
end
|
@@ -0,0 +1,55 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
# This file is distributed under New Relic's license terms.
|
3
|
+
# See https://github.com/newrelic/rpm/blob/master/LICENSE for complete details.
|
4
|
+
|
5
|
+
require 'forwardable'
|
6
|
+
|
7
|
+
module NewRelic
|
8
|
+
module Agent
|
9
|
+
module Commands
|
10
|
+
class XraySession
|
11
|
+
extend Forwardable
|
12
|
+
|
13
|
+
attr_reader :id, :command_arguments
|
14
|
+
attr_reader :xray_session_name, :key_transaction_name,
|
15
|
+
:requested_trace_count, :duration, :sample_period
|
16
|
+
|
17
|
+
def initialize(command_arguments)
|
18
|
+
@command_arguments = command_arguments
|
19
|
+
@id = command_arguments.fetch("x_ray_id", nil)
|
20
|
+
@xray_session_name = command_arguments.fetch("xray_session_name", "")
|
21
|
+
@key_transaction_name = command_arguments.fetch("key_transaction_name", "")
|
22
|
+
@requested_trace_count = command_arguments.fetch("requested_trace_count", 100)
|
23
|
+
@duration = command_arguments.fetch("duration", 86400)
|
24
|
+
@sample_period = command_arguments.fetch("sample_period", 0.1)
|
25
|
+
@run_profiler = command_arguments.fetch("run_profiler", true)
|
26
|
+
end
|
27
|
+
|
28
|
+
def active?
|
29
|
+
@active
|
30
|
+
end
|
31
|
+
|
32
|
+
def run_profiler?
|
33
|
+
@run_profiler && NewRelic::Agent.config[:'xray_session.allow_profiles']
|
34
|
+
end
|
35
|
+
|
36
|
+
def activate
|
37
|
+
@active = true
|
38
|
+
@start_time = Time.now
|
39
|
+
end
|
40
|
+
|
41
|
+
def deactivate
|
42
|
+
@active = false
|
43
|
+
end
|
44
|
+
|
45
|
+
def requested_period
|
46
|
+
@sample_period
|
47
|
+
end
|
48
|
+
|
49
|
+
def finished?
|
50
|
+
@start_time + @duration < Time.now
|
51
|
+
end
|
52
|
+
end
|
53
|
+
end
|
54
|
+
end
|
55
|
+
end
|
@@ -0,0 +1,158 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
# This file is distributed under New Relic's license terms.
|
3
|
+
# See https://github.com/newrelic/rpm/blob/master/LICENSE for complete details.
|
4
|
+
|
5
|
+
require 'forwardable'
|
6
|
+
require 'thread'
|
7
|
+
require 'new_relic/agent/commands/xray_session'
|
8
|
+
|
9
|
+
module NewRelic
|
10
|
+
module Agent
|
11
|
+
module Commands
|
12
|
+
class XraySessionCollection
|
13
|
+
extend Forwardable
|
14
|
+
|
15
|
+
def initialize(backtrace_service, event_listener)
|
16
|
+
@backtrace_service = backtrace_service
|
17
|
+
|
18
|
+
# This lock protects access to the sessions hash, but it's expected
|
19
|
+
# that individual session objects within the hash will be manipulated
|
20
|
+
# outside the lock. This is safe because manipulation of the session
|
21
|
+
# objects is expected from only a single thread (the harvest thread)
|
22
|
+
@sessions_lock = Mutex.new
|
23
|
+
@sessions = {}
|
24
|
+
|
25
|
+
if event_listener
|
26
|
+
event_listener.subscribe(:before_harvest, &method(:cleanup_finished_sessions))
|
27
|
+
end
|
28
|
+
end
|
29
|
+
|
30
|
+
def handle_active_xray_sessions(agent_command)
|
31
|
+
# If X-Rays are disabled, just be quiet about it and don't start the
|
32
|
+
# command. Other hosts might be running the X-Ray, so we don't need
|
33
|
+
# to bark on every get_agent_commands.
|
34
|
+
if !NewRelic::Agent.config[:'xray_session.enabled']
|
35
|
+
NewRelic::Agent.logger.debug("Not responding to X-Ray command because of config 'xray_session.enabled' = #{NewRelic::Agent.config[:'xray_session.enabled']}")
|
36
|
+
return
|
37
|
+
end
|
38
|
+
|
39
|
+
incoming_ids = agent_command.arguments["xray_ids"]
|
40
|
+
deactivate_for_incoming_sessions(incoming_ids)
|
41
|
+
activate_sessions(incoming_ids)
|
42
|
+
end
|
43
|
+
|
44
|
+
def session_id_for_transaction_name(name)
|
45
|
+
@sessions_lock.synchronize do
|
46
|
+
@sessions.keys.find { |id| @sessions[id].key_transaction_name == name }
|
47
|
+
end
|
48
|
+
end
|
49
|
+
|
50
|
+
NO_PROFILES = [].freeze
|
51
|
+
|
52
|
+
def harvest_thread_profiles
|
53
|
+
return NO_PROFILES unless NewRelic::Agent::Threading::BacktraceService.is_supported?
|
54
|
+
|
55
|
+
profiles = active_thread_profiling_sessions.map do |session|
|
56
|
+
NewRelic::Agent.logger.debug("Harvesting profile for X-Ray session #{session.inspect}")
|
57
|
+
@backtrace_service.harvest(session.key_transaction_name)
|
58
|
+
end
|
59
|
+
profiles.reject! {|p| p.empty?}
|
60
|
+
profiles.compact
|
61
|
+
end
|
62
|
+
|
63
|
+
def stop_all_sessions
|
64
|
+
deactivate_for_incoming_sessions([])
|
65
|
+
end
|
66
|
+
|
67
|
+
def cleanup_finished_sessions
|
68
|
+
finished_session_ids.each do |id|
|
69
|
+
NewRelic::Agent.logger.debug("Finished X-Ray session #{id} by duration. Removing it from active sessions.")
|
70
|
+
remove_session_by_id(id)
|
71
|
+
end
|
72
|
+
end
|
73
|
+
|
74
|
+
|
75
|
+
### Internals
|
76
|
+
|
77
|
+
def new_relic_service
|
78
|
+
NewRelic::Agent.instance.service
|
79
|
+
end
|
80
|
+
|
81
|
+
# These are unsynchonized and should only be used for testing
|
82
|
+
def_delegators :@sessions, :[], :include?
|
83
|
+
|
84
|
+
def active_thread_profiling_sessions
|
85
|
+
@sessions_lock.synchronize do
|
86
|
+
@sessions.values.select { |s| s.active? && s.run_profiler? }
|
87
|
+
end
|
88
|
+
end
|
89
|
+
|
90
|
+
### Session activation
|
91
|
+
|
92
|
+
def activate_sessions(incoming_ids)
|
93
|
+
lookup_metadata_for(ids_to_activate(incoming_ids)).each do |raw|
|
94
|
+
add_session(XraySession.new(raw))
|
95
|
+
end
|
96
|
+
end
|
97
|
+
|
98
|
+
def ids_to_activate(incoming_ids)
|
99
|
+
@sessions_lock.synchronize { incoming_ids - @sessions.keys }
|
100
|
+
end
|
101
|
+
|
102
|
+
# Please don't hold the @sessions_lock across me! Calling the service
|
103
|
+
# is time-consuming, and will block request threads. Which is rude.
|
104
|
+
def lookup_metadata_for(ids_to_activate)
|
105
|
+
return [] if ids_to_activate.empty?
|
106
|
+
|
107
|
+
NewRelic::Agent.logger.debug("Retrieving metadata for X-Ray sessions #{ids_to_activate.inspect}")
|
108
|
+
new_relic_service.get_xray_metadata(ids_to_activate)
|
109
|
+
end
|
110
|
+
|
111
|
+
def add_session(session)
|
112
|
+
NewRelic::Agent.logger.debug("Adding X-Ray session #{session.inspect}")
|
113
|
+
NewRelic::Agent.increment_metric("Supportability/XraySessions/Starts")
|
114
|
+
|
115
|
+
@sessions_lock.synchronize { @sessions[session.id] = session }
|
116
|
+
|
117
|
+
session.activate
|
118
|
+
if session.run_profiler?
|
119
|
+
@backtrace_service.subscribe(session.key_transaction_name, session.command_arguments)
|
120
|
+
end
|
121
|
+
end
|
122
|
+
|
123
|
+
### Session deactivation
|
124
|
+
|
125
|
+
def deactivate_for_incoming_sessions(incoming_ids)
|
126
|
+
ids_to_remove(incoming_ids).each do |session_id|
|
127
|
+
remove_session_by_id(session_id)
|
128
|
+
end
|
129
|
+
end
|
130
|
+
|
131
|
+
def ids_to_remove(incoming_ids)
|
132
|
+
@sessions_lock.synchronize { @sessions.keys - incoming_ids }
|
133
|
+
end
|
134
|
+
|
135
|
+
def remove_session_by_id(id)
|
136
|
+
session = @sessions_lock.synchronize { @sessions.delete(id) }
|
137
|
+
|
138
|
+
if session
|
139
|
+
NewRelic::Agent.logger.debug("Removing X-Ray session #{session.inspect}")
|
140
|
+
NewRelic::Agent.increment_metric("Supportability/XraySessions/Stops")
|
141
|
+
|
142
|
+
if session.run_profiler?
|
143
|
+
@backtrace_service.unsubscribe(session.key_transaction_name)
|
144
|
+
end
|
145
|
+
session.deactivate
|
146
|
+
end
|
147
|
+
end
|
148
|
+
|
149
|
+
def finished_session_ids
|
150
|
+
@sessions_lock.synchronize do
|
151
|
+
@sessions.map{|k, s| k if s.finished?}.compact
|
152
|
+
end
|
153
|
+
end
|
154
|
+
|
155
|
+
end
|
156
|
+
end
|
157
|
+
end
|
158
|
+
end
|
@@ -91,7 +91,7 @@ module NewRelic
|
|
91
91
|
end
|
92
92
|
|
93
93
|
def self.thread_profiler_enabled
|
94
|
-
Proc.new { NewRelic::Agent::
|
94
|
+
Proc.new { NewRelic::Agent::Threading::BacktraceService.is_supported? }
|
95
95
|
end
|
96
96
|
|
97
97
|
def self.browser_monitoring_auto_instrument
|
@@ -153,6 +153,7 @@ module NewRelic
|
|
153
153
|
'assets:clobber',
|
154
154
|
'assets:environment',
|
155
155
|
'assets:precompile',
|
156
|
+
'assets:precompile:all',
|
156
157
|
'db:create',
|
157
158
|
'db:drop',
|
158
159
|
'db:fixtures:load',
|
@@ -245,7 +246,7 @@ module NewRelic
|
|
245
246
|
},
|
246
247
|
:monitor_mode => {
|
247
248
|
:default => DefaultSource.monitor_mode,
|
248
|
-
:public =>
|
249
|
+
:public => true,
|
249
250
|
:type => Boolean,
|
250
251
|
:description => 'Enable or disable transmission of data to the New Relic data collection service.'
|
251
252
|
},
|
@@ -513,12 +514,6 @@ module NewRelic
|
|
513
514
|
:type => Boolean,
|
514
515
|
:description => 'Enable or disable memcache instrumentation.'
|
515
516
|
},
|
516
|
-
:disable_mobile_headers => {
|
517
|
-
:default => true,
|
518
|
-
:public => false,
|
519
|
-
:type => Boolean,
|
520
|
-
:description => 'Enable or disable injection of mobile response headers when mobile headers are present in the incoming request.'
|
521
|
-
},
|
522
517
|
:capture_params => {
|
523
518
|
:default => false,
|
524
519
|
:public => true,
|
@@ -579,18 +574,6 @@ module NewRelic
|
|
579
574
|
:type => Fixnum,
|
580
575
|
:description => 'Maximum number of transaction trace segments to record in a single transaction trace.'
|
581
576
|
},
|
582
|
-
:'transaction_tracer.random_sample' => {
|
583
|
-
:default => false,
|
584
|
-
:public => false,
|
585
|
-
:type => Boolean,
|
586
|
-
:description => 'Enable or disable the collection of a random transaction trace during each harvest cycle in addition to the longest transaction trace.'
|
587
|
-
},
|
588
|
-
:sample_rate => {
|
589
|
-
:default => 10,
|
590
|
-
:public => false,
|
591
|
-
:type => Fixnum,
|
592
|
-
:description => 'Number of harvests between random transaction trace samples in the transaction sampler.'
|
593
|
-
},
|
594
577
|
:'slow_sql.enabled' => {
|
595
578
|
:default => DefaultSource.slow_sql_enabled,
|
596
579
|
:public => true,
|
@@ -663,6 +646,24 @@ module NewRelic
|
|
663
646
|
:type => Boolean,
|
664
647
|
:description => 'Enable or disable automatic insertion of the real user monitoring header and footer into outgoing responses.'
|
665
648
|
},
|
649
|
+
:'js_agent_loader_version' => {
|
650
|
+
:default => '',
|
651
|
+
:public => false,
|
652
|
+
:type => String,
|
653
|
+
:description => 'Version of the JavaScript agent loader retrieved by the collector. This is only informational, setting the value does nothing.'
|
654
|
+
},
|
655
|
+
:'js_agent_loader' => {
|
656
|
+
:default => '',
|
657
|
+
:public => false,
|
658
|
+
:type => String,
|
659
|
+
:description => 'JavaScript agent loader content.'
|
660
|
+
},
|
661
|
+
:'js_errors_beta' => {
|
662
|
+
:default => false,
|
663
|
+
:public => false,
|
664
|
+
:type => Boolean,
|
665
|
+
:description => 'Enable or disable beta JavaScript error reporting.'
|
666
|
+
},
|
666
667
|
:trusted_account_ids => {
|
667
668
|
:default => [],
|
668
669
|
:public => false,
|
@@ -681,23 +682,59 @@ module NewRelic
|
|
681
682
|
:type => Boolean,
|
682
683
|
:description => 'Enable or disable the thread profiler.'
|
683
684
|
},
|
685
|
+
:'xray_session.enabled' => {
|
686
|
+
:default => true,
|
687
|
+
:public => true,
|
688
|
+
:type => Boolean,
|
689
|
+
:description => 'Enable or disable X-Ray sessions.'
|
690
|
+
},
|
691
|
+
:'xray_session.allow_traces' => {
|
692
|
+
:default => true,
|
693
|
+
:public => false,
|
694
|
+
:type => Boolean,
|
695
|
+
:description => 'Enable or disable X-Ray sessions recording transaction traces.'
|
696
|
+
},
|
697
|
+
:'xray_session.allow_profiles' => {
|
698
|
+
:default => true,
|
699
|
+
:public => false,
|
700
|
+
:type => Boolean,
|
701
|
+
:description => 'Enable or disable X-Ray sessions taking thread profiles.'
|
702
|
+
},
|
703
|
+
:'xray_session.max_samples' => {
|
704
|
+
:default => 10,
|
705
|
+
:public => false,
|
706
|
+
:type => Fixnum,
|
707
|
+
:description => 'Maximum number of transaction traces to buffer for active X-Ray sessions'
|
708
|
+
},
|
709
|
+
:'xray_session.max_profile_overhead' => {
|
710
|
+
:default => 0.05,
|
711
|
+
:public => false,
|
712
|
+
:type => Float,
|
713
|
+
:description => 'Maximum overhead percentage for thread profiling before agent reduces polling frequency'
|
714
|
+
},
|
684
715
|
:marshaller => {
|
685
716
|
:default => DefaultSource.marshaller,
|
686
717
|
:public => true,
|
687
718
|
:type => String,
|
688
719
|
:description => 'Marshaller to use when marshalling data for transmission to the New Relic data collection service (e.g json, pruby).'
|
689
720
|
},
|
690
|
-
:'
|
721
|
+
:'analytics_events.enabled' => {
|
722
|
+
:default => true,
|
723
|
+
:public => true,
|
724
|
+
:type => Boolean,
|
725
|
+
:description => 'Enable or disable the analytics event sampling.'
|
726
|
+
},
|
727
|
+
:'analytics_events.transactions.enabled' => {
|
691
728
|
:default => true,
|
692
729
|
:public => true,
|
693
730
|
:type => Boolean,
|
694
|
-
:description => 'Enable or disable the
|
731
|
+
:description => 'Enable or disable the analytics event sampling for transactions.'
|
695
732
|
},
|
696
|
-
:'
|
733
|
+
:'analytics_events.max_samples_stored' => {
|
697
734
|
:default => 1200,
|
698
735
|
:public => false,
|
699
736
|
:type => Fixnum,
|
700
|
-
:description => 'Maximum number of request events recorded by the
|
737
|
+
:description => 'Maximum number of request events recorded by the analytics event sampling in a single harvest.'
|
701
738
|
},
|
702
739
|
}.freeze
|
703
740
|
|