newrelic_rpm 9.23.0 → 10.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +136 -0
- data/README.md +0 -7
- data/lib/new_relic/agent/agent.rb +9 -4
- data/lib/new_relic/agent/configuration/default_source.rb +103 -181
- data/lib/new_relic/agent/configuration/environment_source.rb +7 -38
- data/lib/new_relic/agent/configuration/manager.rb +141 -59
- data/lib/new_relic/agent/configuration/sampler_config_validator.rb +54 -0
- data/lib/new_relic/agent/configuration/server_source.rb +0 -1
- data/lib/new_relic/agent/connect/response_handler.rb +0 -11
- data/lib/new_relic/agent/datastores.rb +13 -17
- data/lib/new_relic/agent/distributed_tracing.rb +0 -3
- data/lib/new_relic/agent/health_check.rb +1 -0
- data/lib/new_relic/agent/instrumentation/active_job.rb +1 -1
- data/lib/new_relic/agent/instrumentation/active_job_subscriber.rb +2 -1
- data/lib/new_relic/agent/instrumentation/active_record_helper.rb +1 -4
- data/lib/new_relic/agent/instrumentation/active_support.rb +8 -1
- data/lib/new_relic/agent/instrumentation/active_support_subscriber.rb +22 -14
- data/lib/new_relic/agent/instrumentation/bunny/instrumentation.rb +1 -4
- data/lib/new_relic/agent/instrumentation/bunny.rb +0 -1
- data/lib/new_relic/agent/instrumentation/curb/chain.rb +2 -2
- data/lib/new_relic/agent/instrumentation/curb/instrumentation.rb +2 -3
- data/lib/new_relic/agent/instrumentation/curb.rb +0 -1
- data/lib/new_relic/agent/instrumentation/excon/middleware.rb +1 -1
- data/lib/new_relic/agent/instrumentation/excon.rb +2 -3
- data/lib/new_relic/agent/instrumentation/grpc/client/instrumentation.rb +1 -2
- data/lib/new_relic/agent/instrumentation/httpclient.rb +0 -1
- data/lib/new_relic/agent/instrumentation/httprb.rb +0 -1
- data/lib/new_relic/agent/instrumentation/memcache/dalli.rb +0 -2
- data/lib/new_relic/agent/instrumentation/memcache/prepend.rb +0 -2
- data/lib/new_relic/agent/instrumentation/rack/helpers.rb +1 -3
- data/lib/new_relic/agent/instrumentation/typhoeus.rb +0 -1
- data/lib/new_relic/agent/llm/chat_completion_summary.rb +1 -8
- data/lib/new_relic/agent/llm/embedding.rb +1 -8
- data/lib/new_relic/agent/messaging.rb +12 -5
- data/lib/new_relic/agent/monitors/inbound_request_monitor.rb +1 -2
- data/lib/new_relic/agent/monitors/synthetics_monitor.rb +2 -1
- data/lib/new_relic/agent/monitors.rb +0 -3
- data/lib/new_relic/agent/new_relic_service/encoders.rb +0 -14
- data/lib/new_relic/agent/new_relic_service.rb +11 -49
- data/lib/new_relic/agent/opentelemetry/trace/span.rb +41 -0
- data/lib/new_relic/agent/opentelemetry/trace/tracer.rb +16 -7
- data/lib/new_relic/agent/opentelemetry_bridge.rb +9 -5
- data/lib/new_relic/agent/serverless_handler.rb +2 -2
- data/lib/new_relic/agent/span_event_primitive.rb +1 -1
- data/lib/new_relic/agent/sql_sampler.rb +0 -31
- data/lib/new_relic/agent/stats_engine.rb +1 -0
- data/lib/new_relic/agent/transaction/distributed_tracer.rb +12 -56
- data/lib/new_relic/agent/transaction/distributed_tracing.rb +11 -19
- data/lib/new_relic/agent/transaction/external_request_segment.rb +1 -131
- data/lib/new_relic/agent/transaction/message_broker_segment.rb +0 -2
- data/lib/new_relic/agent/transaction/trace_context.rb +33 -11
- data/lib/new_relic/agent/transaction.rb +35 -4
- data/lib/new_relic/agent/transaction_error_primitive.rb +0 -8
- data/lib/new_relic/agent/transaction_event_primitive.rb +0 -14
- data/lib/new_relic/agent/utilization/gcp.rb +2 -0
- data/lib/new_relic/agent.rb +11 -3
- data/lib/new_relic/cli/command.rb +2 -11
- data/lib/new_relic/control/instance_methods.rb +2 -15
- data/lib/new_relic/control/private_instance_methods.rb +2 -4
- data/lib/new_relic/control/server_methods.rb +0 -6
- data/lib/new_relic/helper.rb +21 -2
- data/lib/new_relic/language_support.rb +3 -34
- data/lib/new_relic/supportability_helper.rb +0 -4
- data/lib/new_relic/version.rb +2 -2
- data/lib/tasks/helpers/newrelicyml.rb +2 -2
- data/lib/tasks/helpers/version_bump.rb +1 -2
- data/newrelic.yml +25 -28
- data/newrelic_rpm.gemspec +10 -9
- metadata +27 -26
- data/bin/newrelic +0 -8
- data/lib/new_relic/agent/configuration/security_policy_source.rb +0 -246
- data/lib/new_relic/agent/distributed_tracing/cross_app_payload.rb +0 -44
- data/lib/new_relic/agent/distributed_tracing/cross_app_tracing.rb +0 -253
- data/lib/new_relic/agent/external.rb +0 -112
- data/lib/new_relic/agent/monitors/cross_app_monitor.rb +0 -117
- data/lib/new_relic/agent/new_relic_service/security_policy_settings.rb +0 -61
- data/lib/new_relic/cli/commands/deployments.rb +0 -206
- data/lib/new_relic/recipes/capistrano3.rb +0 -23
- data/lib/new_relic/recipes/capistrano_legacy.rb +0 -95
- data/lib/new_relic/recipes/helpers/send_deployment.rb +0 -70
- data/lib/new_relic/recipes.rb +0 -24
- data/recipes/newrelic.rb +0 -10
|
@@ -4,6 +4,8 @@
|
|
|
4
4
|
|
|
5
5
|
require 'forwardable'
|
|
6
6
|
require_relative '../../constants'
|
|
7
|
+
require_relative '../instrumentation/active_support_subscriber'
|
|
8
|
+
require_relative 'sampler_config_validator'
|
|
7
9
|
|
|
8
10
|
module NewRelic
|
|
9
11
|
module Agent
|
|
@@ -35,15 +37,6 @@ module NewRelic
|
|
|
35
37
|
end
|
|
36
38
|
|
|
37
39
|
class DefaultSource
|
|
38
|
-
BOOLEAN_MAP = {
|
|
39
|
-
'true' => true,
|
|
40
|
-
'yes' => true,
|
|
41
|
-
'on' => true,
|
|
42
|
-
'false' => false,
|
|
43
|
-
'no' => false,
|
|
44
|
-
'off' => false
|
|
45
|
-
}.freeze
|
|
46
|
-
|
|
47
40
|
attr_reader :defaults
|
|
48
41
|
|
|
49
42
|
extend Forwardable
|
|
@@ -73,12 +66,6 @@ module NewRelic
|
|
|
73
66
|
value_from_defaults(key, :allowlist)
|
|
74
67
|
end
|
|
75
68
|
|
|
76
|
-
def self.boolean_for(key, value)
|
|
77
|
-
string_value = (value.respond_to?(:call) ? value.call : value).to_s
|
|
78
|
-
|
|
79
|
-
BOOLEAN_MAP.fetch(string_value, nil)
|
|
80
|
-
end
|
|
81
|
-
|
|
82
69
|
def self.default_for(key)
|
|
83
70
|
value_from_defaults(key, :default)
|
|
84
71
|
end
|
|
@@ -213,84 +200,21 @@ module NewRelic
|
|
|
213
200
|
end
|
|
214
201
|
end
|
|
215
202
|
|
|
216
|
-
def self.
|
|
217
|
-
|
|
218
|
-
proc do
|
|
219
|
-
api_version = if NewRelic::Agent.config[:api_key].nil? || NewRelic::Agent.config[:api_key].empty?
|
|
220
|
-
'rpm'
|
|
221
|
-
else
|
|
222
|
-
'api'
|
|
223
|
-
end
|
|
224
|
-
api_region = 'eu.' if String(NewRelic::Agent.config[:license_key]).start_with?('eu')
|
|
225
|
-
|
|
226
|
-
"#{api_version}.#{api_region}newrelic.com"
|
|
227
|
-
end
|
|
228
|
-
end
|
|
229
|
-
|
|
230
|
-
def self.convert_to_regexp_list(raw_value)
|
|
231
|
-
value_list = convert_to_list(raw_value)
|
|
232
|
-
value_list.map do |value|
|
|
233
|
-
/#{value}/
|
|
234
|
-
end
|
|
235
|
-
end
|
|
236
|
-
|
|
237
|
-
def self.convert_to_list(value)
|
|
238
|
-
case value
|
|
239
|
-
when String
|
|
240
|
-
value.split(/\s*,\s*/)
|
|
241
|
-
when Array
|
|
242
|
-
value
|
|
243
|
-
else
|
|
244
|
-
raise ArgumentError.new("Config value '#{value}' couldn't be turned into a list.")
|
|
245
|
-
end
|
|
246
|
-
end
|
|
247
|
-
|
|
248
|
-
def self.convert_to_hash(value)
|
|
249
|
-
return value if value.is_a?(Hash)
|
|
250
|
-
|
|
251
|
-
if value.is_a?(String)
|
|
252
|
-
return value.split(',').each_with_object({}) do |item, hash|
|
|
253
|
-
key, value = item.split('=')
|
|
254
|
-
hash[key] = value
|
|
255
|
-
end
|
|
256
|
-
end
|
|
257
|
-
|
|
258
|
-
raise ArgumentError.new(
|
|
259
|
-
"Config value '#{value}' of " \
|
|
260
|
-
"class #{value.class} couldn't be turned into a Hash."
|
|
261
|
-
)
|
|
262
|
-
end
|
|
263
|
-
|
|
264
|
-
SEMICOLON = ';'.freeze
|
|
265
|
-
def self.convert_to_list_on_semicolon(value)
|
|
266
|
-
case value
|
|
267
|
-
when Array then value
|
|
268
|
-
when String then value.split(SEMICOLON)
|
|
269
|
-
else NewRelic::EMPTY_ARRAY
|
|
270
|
-
end
|
|
203
|
+
def self.convert_to_regexp_list(string_array)
|
|
204
|
+
string_array.map { |value| /#{value}/ }
|
|
271
205
|
end
|
|
272
206
|
|
|
273
|
-
def self.convert_to_constant_list(
|
|
274
|
-
return
|
|
207
|
+
def self.convert_to_constant_list(string_array)
|
|
208
|
+
return string_array if string_array.empty?
|
|
275
209
|
|
|
276
|
-
constants =
|
|
210
|
+
constants = string_array.map! do |class_name|
|
|
277
211
|
const = ::NewRelic::LanguageSupport.constantize(class_name)
|
|
278
|
-
NewRelic::Agent.logger.warn("Ignoring invalid constant '#{class_name}' in #{
|
|
212
|
+
NewRelic::Agent.logger.warn("Ignoring invalid constant '#{class_name}' in #{string_array}") unless const
|
|
279
213
|
const
|
|
280
214
|
end
|
|
281
215
|
constants.compact!
|
|
282
216
|
constants
|
|
283
217
|
end
|
|
284
|
-
|
|
285
|
-
def self.enforce_fallback(allowed_values: nil, fallback: nil)
|
|
286
|
-
proc do |configured_value|
|
|
287
|
-
if allowed_values.any? { |v| v =~ /#{configured_value}/i }
|
|
288
|
-
configured_value
|
|
289
|
-
else
|
|
290
|
-
fallback
|
|
291
|
-
end
|
|
292
|
-
end
|
|
293
|
-
end
|
|
294
218
|
end
|
|
295
219
|
|
|
296
220
|
AUTOSTART_DENYLISTED_RAKE_TASKS = [
|
|
@@ -361,7 +285,8 @@ module NewRelic
|
|
|
361
285
|
:public => true,
|
|
362
286
|
:type => String,
|
|
363
287
|
:allowed_from_server => false,
|
|
364
|
-
:transform =>
|
|
288
|
+
:transform => proc { |v| v.is_a?(String) ? v.split(';') : v },
|
|
289
|
+
:transformed_type => Array,
|
|
365
290
|
:description => 'Specify the [application name](/docs/apm/new-relic-apm/installation-configuration/name-your-application) used to aggregate data in the New Relic UI. To report data to [multiple apps at the same time](/docs/apm/new-relic-apm/installation-configuration/using-multiple-names-app), specify a list of names separated by a semicolon `;`. For example, `MyApp` or `MyStagingApp;Instance1`.'
|
|
366
291
|
},
|
|
367
292
|
:license_key => {
|
|
@@ -422,14 +347,6 @@ module NewRelic
|
|
|
422
347
|
:allowed_from_server => true,
|
|
423
348
|
:description => 'For agent versions 3.5.0 or higher, [set your Apdex T via the New Relic UI](/docs/apm/new-relic-apm/apdex/changing-your-apdex-settings).'
|
|
424
349
|
},
|
|
425
|
-
:api_key => {
|
|
426
|
-
:default => '',
|
|
427
|
-
:public => true,
|
|
428
|
-
:type => String,
|
|
429
|
-
:allowed_from_server => false,
|
|
430
|
-
:exclude_from_reported_settings => true,
|
|
431
|
-
:description => '# DEPRECATED: The `api_key` config setting is now deprecated. Its only use was for the `newrelic deployments` command, which is being removed in agent version 10.0.0.'
|
|
432
|
-
},
|
|
433
350
|
:backport_fast_active_record_connection_lookup => {
|
|
434
351
|
:default => false,
|
|
435
352
|
:public => true,
|
|
@@ -526,6 +443,7 @@ module NewRelic
|
|
|
526
443
|
:public => true,
|
|
527
444
|
:type => String,
|
|
528
445
|
:allowed_from_server => false,
|
|
446
|
+
:transformed_type => Hash, # NOTE: :labels is a special case and transformed in manager.rb without a :transform key
|
|
529
447
|
:description => 'A dictionary of [label names](/docs/data-analysis/user-interface-functions/labels-categories-organize-your-apps-servers) and values that will be applied to the data sent from this agent. May also be expressed as a semicolon-delimited `;` string of colon-separated `:` pairs. For example, `Server:One;Data Center:Primary`.'
|
|
530
448
|
},
|
|
531
449
|
:log_file_name => {
|
|
@@ -598,13 +516,6 @@ module NewRelic
|
|
|
598
516
|
:exclude_from_reported_settings => true,
|
|
599
517
|
:description => 'Defines a user for communicating with the New Relic [collector](/docs/using-new-relic/welcome-new-relic/get-started/glossary/#collector) via a proxy server.'
|
|
600
518
|
},
|
|
601
|
-
:security_policies_token => {
|
|
602
|
-
:default => '',
|
|
603
|
-
:public => true,
|
|
604
|
-
:type => String,
|
|
605
|
-
:allowed_from_server => false,
|
|
606
|
-
:description => 'Applies Language Agent Security Policy settings.'
|
|
607
|
-
},
|
|
608
519
|
:send_data_on_exit => {
|
|
609
520
|
:default => true,
|
|
610
521
|
:public => true,
|
|
@@ -877,7 +788,6 @@ module NewRelic
|
|
|
877
788
|
:default => {},
|
|
878
789
|
:public => true,
|
|
879
790
|
:type => Hash,
|
|
880
|
-
:transform => DefaultSource.method(:convert_to_hash),
|
|
881
791
|
:allowed_from_server => false,
|
|
882
792
|
:description => 'A hash with key/value pairs to add as custom attributes to all log events forwarded to New Relic. If sending using an environment variable, the value must be formatted like: "key1=value1,key2=value2"'
|
|
883
793
|
},
|
|
@@ -892,7 +802,6 @@ module NewRelic
|
|
|
892
802
|
:default => [],
|
|
893
803
|
:public => true,
|
|
894
804
|
:type => Array,
|
|
895
|
-
:transform => DefaultSource.method(:convert_to_list),
|
|
896
805
|
:allowed_from_server => false,
|
|
897
806
|
:description => 'A case-insensitive array or comma-delimited string containing the labels to exclude from log records.'
|
|
898
807
|
},
|
|
@@ -938,7 +847,6 @@ module NewRelic
|
|
|
938
847
|
:public => true,
|
|
939
848
|
:type => Array,
|
|
940
849
|
:allowed_from_server => false,
|
|
941
|
-
:transform => DefaultSource.method(:convert_to_list),
|
|
942
850
|
:description => 'Prefix of attributes to exclude from all destinations. Allows `*` as wildcard at end.'
|
|
943
851
|
},
|
|
944
852
|
:'attributes.include' => {
|
|
@@ -946,7 +854,6 @@ module NewRelic
|
|
|
946
854
|
:public => true,
|
|
947
855
|
:type => Array,
|
|
948
856
|
:allowed_from_server => false,
|
|
949
|
-
:transform => DefaultSource.method(:convert_to_list),
|
|
950
857
|
:description => 'Prefix of attributes to include in all destinations. Allows `*` as wildcard at end.'
|
|
951
858
|
},
|
|
952
859
|
:'browser_monitoring.attributes.enabled' => {
|
|
@@ -961,7 +868,6 @@ module NewRelic
|
|
|
961
868
|
:public => true,
|
|
962
869
|
:type => Array,
|
|
963
870
|
:allowed_from_server => false,
|
|
964
|
-
:transform => DefaultSource.method(:convert_to_list),
|
|
965
871
|
:description => 'Prefix of attributes to exclude from browser monitoring. Allows `*` as wildcard at end.'
|
|
966
872
|
},
|
|
967
873
|
:'browser_monitoring.attributes.include' => {
|
|
@@ -969,7 +875,6 @@ module NewRelic
|
|
|
969
875
|
:public => true,
|
|
970
876
|
:type => Array,
|
|
971
877
|
:allowed_from_server => false,
|
|
972
|
-
:transform => DefaultSource.method(:convert_to_list),
|
|
973
878
|
:description => 'Prefix of attributes to include in browser monitoring. Allows `*` as wildcard at end.'
|
|
974
879
|
},
|
|
975
880
|
:'error_collector.attributes.enabled' => {
|
|
@@ -984,7 +889,6 @@ module NewRelic
|
|
|
984
889
|
:public => true,
|
|
985
890
|
:type => Array,
|
|
986
891
|
:allowed_from_server => false,
|
|
987
|
-
:transform => DefaultSource.method(:convert_to_list),
|
|
988
892
|
:description => 'Prefix of attributes to exclude from error collection. Allows `*` as wildcard at end.'
|
|
989
893
|
},
|
|
990
894
|
:'error_collector.attributes.include' => {
|
|
@@ -992,7 +896,6 @@ module NewRelic
|
|
|
992
896
|
:public => true,
|
|
993
897
|
:type => Array,
|
|
994
898
|
:allowed_from_server => false,
|
|
995
|
-
:transform => DefaultSource.method(:convert_to_list),
|
|
996
899
|
:description => 'Prefix of attributes to include in error collection. Allows `*` as wildcard at end.'
|
|
997
900
|
},
|
|
998
901
|
:'span_events.attributes.enabled' => {
|
|
@@ -1007,7 +910,6 @@ module NewRelic
|
|
|
1007
910
|
:public => true,
|
|
1008
911
|
:type => Array,
|
|
1009
912
|
:allowed_from_server => false,
|
|
1010
|
-
:transform => DefaultSource.method(:convert_to_list),
|
|
1011
913
|
:description => 'Prefix of attributes to exclude from span events. Allows `*` as wildcard at end.'
|
|
1012
914
|
},
|
|
1013
915
|
:'span_events.attributes.include' => {
|
|
@@ -1015,7 +917,6 @@ module NewRelic
|
|
|
1015
917
|
:public => true,
|
|
1016
918
|
:type => Array,
|
|
1017
919
|
:allowed_from_server => false,
|
|
1018
|
-
:transform => DefaultSource.method(:convert_to_list),
|
|
1019
920
|
:description => 'Prefix of attributes to include on span events. Allows `*` as wildcard at end.'
|
|
1020
921
|
},
|
|
1021
922
|
:'transaction_events.attributes.enabled' => {
|
|
@@ -1030,7 +931,6 @@ module NewRelic
|
|
|
1030
931
|
:public => true,
|
|
1031
932
|
:type => Array,
|
|
1032
933
|
:allowed_from_server => false,
|
|
1033
|
-
:transform => DefaultSource.method(:convert_to_list),
|
|
1034
934
|
:description => 'Prefix of attributes to exclude from transaction events. Allows `*` as wildcard at end.'
|
|
1035
935
|
},
|
|
1036
936
|
:'transaction_events.attributes.include' => {
|
|
@@ -1038,7 +938,6 @@ module NewRelic
|
|
|
1038
938
|
:public => true,
|
|
1039
939
|
:type => Array,
|
|
1040
940
|
:allowed_from_server => false,
|
|
1041
|
-
:transform => DefaultSource.method(:convert_to_list),
|
|
1042
941
|
:description => 'Prefix of attributes to include in transaction events. Allows `*` as wildcard at end.'
|
|
1043
942
|
},
|
|
1044
943
|
:'transaction_segments.attributes.enabled' => {
|
|
@@ -1053,7 +952,6 @@ module NewRelic
|
|
|
1053
952
|
:public => true,
|
|
1054
953
|
:type => Array,
|
|
1055
954
|
:allowed_from_server => false,
|
|
1056
|
-
:transform => DefaultSource.method(:convert_to_list),
|
|
1057
955
|
:description => 'Prefix of attributes to exclude from transaction segments. Allows `*` as wildcard at end.'
|
|
1058
956
|
},
|
|
1059
957
|
:'transaction_segments.attributes.include' => {
|
|
@@ -1061,7 +959,6 @@ module NewRelic
|
|
|
1061
959
|
:public => true,
|
|
1062
960
|
:type => Array,
|
|
1063
961
|
:allowed_from_server => false,
|
|
1064
|
-
:transform => DefaultSource.method(:convert_to_list),
|
|
1065
962
|
:description => 'Prefix of attributes to include on transaction segments. Allows `*` as wildcard at end.'
|
|
1066
963
|
},
|
|
1067
964
|
:'transaction_tracer.attributes.enabled' => {
|
|
@@ -1076,7 +973,6 @@ module NewRelic
|
|
|
1076
973
|
:public => true,
|
|
1077
974
|
:type => Array,
|
|
1078
975
|
:allowed_from_server => false,
|
|
1079
|
-
:transform => DefaultSource.method(:convert_to_list),
|
|
1080
976
|
:description => 'Prefix of attributes to exclude from transaction traces. Allows `*` as wildcard at end.'
|
|
1081
977
|
},
|
|
1082
978
|
:'transaction_tracer.attributes.include' => {
|
|
@@ -1084,7 +980,6 @@ module NewRelic
|
|
|
1084
980
|
:public => true,
|
|
1085
981
|
:type => Array,
|
|
1086
982
|
:allowed_from_server => false,
|
|
1087
|
-
:transform => DefaultSource.method(:convert_to_list),
|
|
1088
983
|
:description => 'Prefix of attributes to include in transaction traces. Allows `*` as wildcard at end.'
|
|
1089
984
|
},
|
|
1090
985
|
# Audit log
|
|
@@ -1101,6 +996,7 @@ module NewRelic
|
|
|
1101
996
|
:type => Array,
|
|
1102
997
|
:allowed_from_server => false,
|
|
1103
998
|
:transform => DefaultSource.method(:convert_to_regexp_list),
|
|
999
|
+
:transformed_type => Array,
|
|
1104
1000
|
:description => 'List of allowed endpoints to include in audit log.'
|
|
1105
1001
|
},
|
|
1106
1002
|
:'audit_log.path' => {
|
|
@@ -1156,18 +1052,6 @@ module NewRelic
|
|
|
1156
1052
|
:description => "If `true`, the agent will report source code level metrics for traced methods.\n\tSee: " \
|
|
1157
1053
|
'https://docs.newrelic.com/docs/apm/agents/ruby-agent/features/ruby-codestream-integration/'
|
|
1158
1054
|
},
|
|
1159
|
-
# Cross application tracer
|
|
1160
|
-
:"cross_application_tracer.enabled" => {
|
|
1161
|
-
:default => false,
|
|
1162
|
-
:public => true,
|
|
1163
|
-
:type => Boolean,
|
|
1164
|
-
:allowed_from_server => true,
|
|
1165
|
-
:deprecated => true,
|
|
1166
|
-
:description => deprecated_description(
|
|
1167
|
-
:'distributed_tracing.enabled',
|
|
1168
|
-
' If `true`, enables [cross-application tracing](/docs/agents/ruby-agent/features/cross-application-tracing-ruby/) when `distributed_tracing.enabled` is set to `false`.'
|
|
1169
|
-
)
|
|
1170
|
-
},
|
|
1171
1055
|
# Custom attributes
|
|
1172
1056
|
:'custom_attributes.enabled' => {
|
|
1173
1057
|
:default => true,
|
|
@@ -1182,6 +1066,7 @@ module NewRelic
|
|
|
1182
1066
|
:type => Array,
|
|
1183
1067
|
:allowed_from_server => false,
|
|
1184
1068
|
:transform => proc { |arr| NewRelic::Agent.add_automatic_method_tracers(arr) },
|
|
1069
|
+
:transformed_type => Array,
|
|
1185
1070
|
:description => <<~DESCRIPTION
|
|
1186
1071
|
An array of `CLASS#METHOD` (for instance methods) and/or `CLASS.METHOD` (for class methods) strings representing Ruby methods that the agent can automatically add custom instrumentation to. This doesn't require any modifications of the source code that defines the methods.
|
|
1187
1072
|
|
|
@@ -1424,20 +1309,7 @@ module NewRelic
|
|
|
1424
1309
|
:type => Boolean,
|
|
1425
1310
|
:allowed_from_server => false,
|
|
1426
1311
|
:description => <<~DESCRIPTION
|
|
1427
|
-
If `true`, disables agent middleware for Sinatra. This middleware is responsible for advanced feature support such as [
|
|
1428
|
-
|
|
1429
|
-
\t<Callout variant="important">
|
|
1430
|
-
\t\tCross application tracing is deprecated in favor of [distributed tracing](/docs/apm/distributed-tracing/getting-started/introduction-distributed-tracing). Distributed tracing is on by default for Ruby agent versions 8.0.0 and above. Middlewares are not required to support distributed tracing.
|
|
1431
|
-
|
|
1432
|
-
\t\tTo continue using cross application tracing, update the following options in your `newrelic.yml` configuration file:
|
|
1433
|
-
|
|
1434
|
-
\t\t```yaml
|
|
1435
|
-
\t\t\tcross_application_tracer:
|
|
1436
|
-
\t\t\t\tenabled: true
|
|
1437
|
-
\t\t\tdistributed_tracing:
|
|
1438
|
-
\t\t\t\tenabled: false
|
|
1439
|
-
\t\t```
|
|
1440
|
-
\t</Callout>
|
|
1312
|
+
If `true`, disables agent middleware for Sinatra. This middleware is responsible for advanced feature support such as [distributed tracing](/docs/apm/distributed-tracing/getting-started/introduction-distributed-tracing), [page load timing](/docs/browser/new-relic-browser/getting-started/new-relic-browser), and [error collection](/docs/apm/applications-menu/events/view-apm-error-analytics).
|
|
1441
1313
|
DESCRIPTION
|
|
1442
1314
|
},
|
|
1443
1315
|
:disable_view_instrumentation => {
|
|
@@ -1463,19 +1335,68 @@ module NewRelic
|
|
|
1463
1335
|
:allowed_from_server => true,
|
|
1464
1336
|
:description => 'Distributed tracing lets you see the path that a request takes through your distributed system. Enabling distributed tracing changes the behavior of some New Relic features, so carefully consult the [transition guide](/docs/transition-guide-distributed-tracing) before you enable this feature.'
|
|
1465
1337
|
},
|
|
1338
|
+
:'distributed_tracing.sampler.root' => {
|
|
1339
|
+
:default => 'adaptive',
|
|
1340
|
+
:public => true,
|
|
1341
|
+
:type => String,
|
|
1342
|
+
:allowed_from_server => false,
|
|
1343
|
+
:allowlist => %w[adaptive always_on always_off trace_id_ratio_based],
|
|
1344
|
+
:transform => SamplerConfigValidator.validate_sampler_strategy_with_ratio(
|
|
1345
|
+
:'distributed_tracing.sampler.root',
|
|
1346
|
+
:'distributed_tracing.sampler.root.trace_id_ratio_based.ratio'
|
|
1347
|
+
),
|
|
1348
|
+
:description => 'This setting controls the behavior of transaction sampling for transactions without a remote parent, traces that originate within this instance of the New Relic agent. Available values are `adaptive` (the default), `always_on`, `always_off`, and `trace_id_ratio_based`.'
|
|
1349
|
+
},
|
|
1466
1350
|
:'distributed_tracing.sampler.remote_parent_sampled' => {
|
|
1467
|
-
:default => '
|
|
1351
|
+
:default => 'adaptive',
|
|
1468
1352
|
:public => true,
|
|
1469
1353
|
:type => String,
|
|
1470
|
-
:allowed_from_server =>
|
|
1471
|
-
:
|
|
1354
|
+
:allowed_from_server => false,
|
|
1355
|
+
:allowlist => %w[adaptive always_on always_off trace_id_ratio_based],
|
|
1356
|
+
:transform => SamplerConfigValidator.validate_sampler_strategy_with_ratio(
|
|
1357
|
+
:'distributed_tracing.sampler.remote_parent_sampled',
|
|
1358
|
+
:'distributed_tracing.sampler.remote_parent_sampled.trace_id_ratio_based.ratio'
|
|
1359
|
+
),
|
|
1360
|
+
:description => 'This setting controls the behavior of transaction sampling when a remote parent is sampled. Available values are `adaptive` (the default), `always_on`, `always_off`, and `trace_id_ratio_based`.'
|
|
1472
1361
|
},
|
|
1473
1362
|
:'distributed_tracing.sampler.remote_parent_not_sampled' => {
|
|
1474
|
-
:default => '
|
|
1363
|
+
:default => 'adaptive',
|
|
1475
1364
|
:public => true,
|
|
1476
1365
|
:type => String,
|
|
1477
|
-
:allowed_from_server =>
|
|
1478
|
-
:
|
|
1366
|
+
:allowed_from_server => false,
|
|
1367
|
+
:allowlist => %w[adaptive always_on always_off trace_id_ratio_based],
|
|
1368
|
+
:transform => SamplerConfigValidator.validate_sampler_strategy_with_ratio(
|
|
1369
|
+
:'distributed_tracing.sampler.remote_parent_not_sampled',
|
|
1370
|
+
:'distributed_tracing.sampler.remote_parent_not_sampled.trace_id_ratio_based.ratio'
|
|
1371
|
+
),
|
|
1372
|
+
:description => 'This setting controls the behavior of transaction sampling when a remote parent is not sampled. Available values are `adaptive` (the default), `always_on`, `always_off`, and `trace_id_ratio_based`.'
|
|
1373
|
+
},
|
|
1374
|
+
:'distributed_tracing.sampler.root.trace_id_ratio_based.ratio' => {
|
|
1375
|
+
:default => nil,
|
|
1376
|
+
:public => false,
|
|
1377
|
+
:type => Float,
|
|
1378
|
+
:allow_nil => true,
|
|
1379
|
+
:allowed_from_server => false,
|
|
1380
|
+
:transform => SamplerConfigValidator.method(:validate_sampling_ratio),
|
|
1381
|
+
:description => 'The ratio used for the trace_id_ratio_based sampling decision for the root sampler. This must be a float between 0.0 and 1.0. If you provide an invalid value, the sampler will not use the trace_id_ratio_based sampler and will return to the default behavior. If you do not provide a value, the sampler will not use the trace_id_ratio_based_sampler and fall back to the default sampler.'
|
|
1382
|
+
},
|
|
1383
|
+
:'distributed_tracing.sampler.remote_parent_sampled.trace_id_ratio_based.ratio' => {
|
|
1384
|
+
:default => nil,
|
|
1385
|
+
:public => false,
|
|
1386
|
+
:type => Float,
|
|
1387
|
+
:allow_nil => true,
|
|
1388
|
+
:allowed_from_server => false,
|
|
1389
|
+
:transform => SamplerConfigValidator.method(:validate_sampling_ratio),
|
|
1390
|
+
:description => 'The ratio used for the trace_id_ratio_based sampling decision for the remote parent sampled sampler. This must be a float between 0.0 and 1.0. If you provide an invalid value, the sampler will not use the trace_id_ratio_based sampler and will return to the default behavior. If you do not provide a value, the sampler will not use the trace_id_ratio_based_sampler and fall back to the default sampler.'
|
|
1391
|
+
},
|
|
1392
|
+
:'distributed_tracing.sampler.remote_parent_not_sampled.trace_id_ratio_based.ratio' => {
|
|
1393
|
+
:default => nil,
|
|
1394
|
+
:public => false,
|
|
1395
|
+
:type => Float,
|
|
1396
|
+
:allow_nil => true,
|
|
1397
|
+
:allowed_from_server => false,
|
|
1398
|
+
:transform => SamplerConfigValidator.method(:validate_sampling_ratio),
|
|
1399
|
+
:description => 'The ratio used for the trace_id_ratio_based sampling decision for the remote parent not sampled sampler. This must be a float between 0.0 and 1.0. If you provide an invalid value or do not provide a value, the sampler will not use the trace_id_ratio_based_sampler and fall back to the default sampler.'
|
|
1479
1400
|
},
|
|
1480
1401
|
# Elasticsearch
|
|
1481
1402
|
:'elasticsearch.capture_cluster_name' => {
|
|
@@ -1512,7 +1433,6 @@ module NewRelic
|
|
|
1512
1433
|
:public => true,
|
|
1513
1434
|
:type => Array,
|
|
1514
1435
|
:allowed_from_server => false,
|
|
1515
|
-
:transform => DefaultSource.method(:convert_to_list),
|
|
1516
1436
|
:description => 'Ordinarily the agent reports dyno names with a trailing dot and process ID (for example, `worker.3`). You can remove this trailing data by specifying the prefixes you want to report without trailing data (for example, `worker`).'
|
|
1517
1437
|
},
|
|
1518
1438
|
# Infinite tracing
|
|
@@ -1536,6 +1456,24 @@ module NewRelic
|
|
|
1536
1456
|
:description => 'Configures the TCP/IP port for the trace observer Host'
|
|
1537
1457
|
},
|
|
1538
1458
|
# Instrumentation
|
|
1459
|
+
:'instrumentation.active_support_notifications.active_support_events' => {
|
|
1460
|
+
:default => NewRelic::Agent::Instrumentation::ActiveSupportSubscriber::EVENT_NAME_TO_METHOD_NAME.keys,
|
|
1461
|
+
:public => true,
|
|
1462
|
+
:type => Array,
|
|
1463
|
+
:allowed_from_server => false,
|
|
1464
|
+
:description => <<~ACTIVE_SUPPORT_EVENTS.chomp.tr("\n", ' ')
|
|
1465
|
+
An allowlist array of Active Support notifications events specific to the Active Support library
|
|
1466
|
+
itself that the agent should subscribe to. The Active Support library specific events focus primarily
|
|
1467
|
+
on caching. Any event name not included in this list will be ignored by the agent. Provide complete event
|
|
1468
|
+
names such as 'cache_fetch_hit.active_support'. Do not provide asterisks or regex patterns, and do not
|
|
1469
|
+
escape any characters with backslashes.
|
|
1470
|
+
|
|
1471
|
+
For a complete list of all possible Active Support event names, see the
|
|
1472
|
+
[list of caching names](https://edgeguides.rubyonrails.org/active_support_instrumentation.html#active-support-caching)
|
|
1473
|
+
and the [list of messages names](https://edgeguides.rubyonrails.org/active_support_instrumentation.html#active-support-messages)
|
|
1474
|
+
from the official Rails documentation.
|
|
1475
|
+
ACTIVE_SUPPORT_EVENTS
|
|
1476
|
+
},
|
|
1539
1477
|
:'instrumentation.active_support_broadcast_logger' => {
|
|
1540
1478
|
:default => instrumentation_value_from_boolean(:'application_logging.enabled'),
|
|
1541
1479
|
:documentation_default => 'auto',
|
|
@@ -1728,6 +1666,7 @@ module NewRelic
|
|
|
1728
1666
|
:type => Array,
|
|
1729
1667
|
:allowed_from_server => false,
|
|
1730
1668
|
:transform => DefaultSource.method(:convert_to_regexp_list),
|
|
1669
|
+
:transformed_type => Array,
|
|
1731
1670
|
:description => %Q(Specifies a list of hostname patterns separated by commas that will match gRPC hostnames that traffic is to be ignored by New Relic for. New Relic's gRPC client instrumentation will ignore traffic streamed to a host matching any of these patterns, and New Relic's gRPC server instrumentation will ignore traffic for a server running on a host whose hostname matches any of these patterns. By default, no traffic is ignored when gRPC instrumentation is itself enabled. For example, `"private.com$,exception.*"`)
|
|
1732
1671
|
},
|
|
1733
1672
|
:'instrumentation.grpc_server' => {
|
|
@@ -1945,7 +1884,6 @@ module NewRelic
|
|
|
1945
1884
|
type: Array,
|
|
1946
1885
|
dynamic_name: true,
|
|
1947
1886
|
allowed_from_server: false,
|
|
1948
|
-
:transform => DefaultSource.method(:convert_to_list),
|
|
1949
1887
|
:description => <<~DESCRIPTION
|
|
1950
1888
|
An array of strings to specify which keys inside a Stripe event's `user_data` hash should be reported
|
|
1951
1889
|
to New Relic. Each string in this array will be turned into a regular expression via `Regexp.new` to
|
|
@@ -1958,7 +1896,6 @@ module NewRelic
|
|
|
1958
1896
|
type: Array,
|
|
1959
1897
|
dynamic_name: true,
|
|
1960
1898
|
allowed_from_server: false,
|
|
1961
|
-
:transform => DefaultSource.method(:convert_to_list),
|
|
1962
1899
|
:description => <<~DESCRIPTION
|
|
1963
1900
|
An array of strings to specify which keys and/or values inside a Stripe event's `user_data` hash should
|
|
1964
1901
|
\tnot be reported to New Relic. Each string in this array will be turned into a regular expression via
|
|
@@ -2076,6 +2013,7 @@ module NewRelic
|
|
|
2076
2013
|
:type => Array,
|
|
2077
2014
|
:allowed_from_server => false,
|
|
2078
2015
|
:transform => DefaultSource.method(:convert_to_regexp_list),
|
|
2016
|
+
:transformed_type => Array,
|
|
2079
2017
|
:description => 'Specify an Array of Rake tasks to automatically instrument. ' \
|
|
2080
2018
|
'This configuration option converts the Array to a RegEx list. If you\'d like ' \
|
|
2081
2019
|
'to allow all tasks by default, use `rake.tasks: [.+]`. No rake tasks will be ' \
|
|
@@ -2096,6 +2034,7 @@ module NewRelic
|
|
|
2096
2034
|
:type => Array,
|
|
2097
2035
|
:allowed_from_server => true,
|
|
2098
2036
|
:transform => DefaultSource.method(:convert_to_regexp_list),
|
|
2037
|
+
:transformed_type => Array,
|
|
2099
2038
|
:description => 'Define transactions you want the agent to ignore, by specifying a list of patterns matching the URI you want to ignore. For more detail, see [the docs on ignoring specific transactions](/docs/agents/ruby-agent/api-guides/ignoring-specific-transactions/#config-ignoring).'
|
|
2100
2039
|
},
|
|
2101
2040
|
# Serverless
|
|
@@ -2105,6 +2044,7 @@ module NewRelic
|
|
|
2105
2044
|
:type => Boolean,
|
|
2106
2045
|
:allowed_from_server => false,
|
|
2107
2046
|
:transform => proc { |bool| NewRelic::Agent::ServerlessHandler.env_var_set? || bool },
|
|
2047
|
+
:transformed_type => Boolean,
|
|
2108
2048
|
:description => 'If `true`, the agent will operate in a streamlined mode suitable for use with short-lived ' \
|
|
2109
2049
|
'serverless functions. NOTE: Only AWS Lambda functions are supported currently and this ' \
|
|
2110
2050
|
"option isn't intended for use without [New Relic's Ruby Lambda layer](https://docs.newrelic.com/docs/serverless-function-monitoring/aws-lambda-monitoring/get-started/monitoring-aws-lambda-serverless-monitoring/) offering."
|
|
@@ -2225,11 +2165,12 @@ module NewRelic
|
|
|
2225
2165
|
:description => 'If true, the agent strips messages from all exceptions except those in the [allowed classes list](#strip_exception_messages-allowed_classes). Enabled automatically in [high security mode](/docs/accounts-partnerships/accounts/security/high-security).'
|
|
2226
2166
|
},
|
|
2227
2167
|
:'strip_exception_messages.allowed_classes' => {
|
|
2228
|
-
:default =>
|
|
2168
|
+
:default => NewRelic::EMPTY_ARRAY,
|
|
2229
2169
|
:public => true,
|
|
2230
|
-
:type =>
|
|
2170
|
+
:type => Array,
|
|
2231
2171
|
:allowed_from_server => false,
|
|
2232
2172
|
:transform => DefaultSource.method(:convert_to_constant_list),
|
|
2173
|
+
:transformed_type => Array,
|
|
2233
2174
|
:description => 'Specify a list of exceptions you do not want the agent to strip when [strip_exception_messages](#strip_exception_messages-enabled) is `true`. Separate exceptions with a comma. For example, `"ImportantException,PreserveMessageException"`.'
|
|
2234
2175
|
},
|
|
2235
2176
|
# Agent Control
|
|
@@ -2326,20 +2267,6 @@ module NewRelic
|
|
|
2326
2267
|
:allowed_from_server => true,
|
|
2327
2268
|
:description => 'If true, attempt to keep the TCP connection to the collector alive between harvests.'
|
|
2328
2269
|
},
|
|
2329
|
-
:api_host => {
|
|
2330
|
-
:default => DefaultSource.api_host,
|
|
2331
|
-
:public => false,
|
|
2332
|
-
:type => String,
|
|
2333
|
-
:allowed_from_server => false,
|
|
2334
|
-
:description => 'API host for New Relic.'
|
|
2335
|
-
},
|
|
2336
|
-
:api_port => {
|
|
2337
|
-
:default => value_of(:port),
|
|
2338
|
-
:public => false,
|
|
2339
|
-
:type => Integer,
|
|
2340
|
-
:allowed_from_server => false,
|
|
2341
|
-
:description => 'Port for the New Relic API host.'
|
|
2342
|
-
},
|
|
2343
2270
|
:application_id => {
|
|
2344
2271
|
:default => '',
|
|
2345
2272
|
:public => false,
|
|
@@ -2404,13 +2331,6 @@ module NewRelic
|
|
|
2404
2331
|
:allowed_from_server => false,
|
|
2405
2332
|
:description => "An array of candidate locations for the agent's configuration file."
|
|
2406
2333
|
},
|
|
2407
|
-
:cross_process_id => {
|
|
2408
|
-
:default => '',
|
|
2409
|
-
:public => false,
|
|
2410
|
-
:type => String,
|
|
2411
|
-
:allowed_from_server => true,
|
|
2412
|
-
:description => 'Cross process ID for cross-application tracing.'
|
|
2413
|
-
},
|
|
2414
2334
|
:data_report_period => {
|
|
2415
2335
|
:default => 60,
|
|
2416
2336
|
:public => false,
|
|
@@ -2452,7 +2372,7 @@ module NewRelic
|
|
|
2452
2372
|
:public => false,
|
|
2453
2373
|
:type => String,
|
|
2454
2374
|
:allowed_from_server => true,
|
|
2455
|
-
:description => 'Encoding key for
|
|
2375
|
+
:description => 'Encoding key for obfuscating/deobfuscating data sent to/from New Relic.'
|
|
2456
2376
|
},
|
|
2457
2377
|
:entity_guid => {
|
|
2458
2378
|
:default => nil,
|
|
@@ -2516,8 +2436,14 @@ module NewRelic
|
|
|
2516
2436
|
:allowed_from_server => true,
|
|
2517
2437
|
:description => 'Number of seconds betwixt connections to the New Relic span event collection services.'
|
|
2518
2438
|
},
|
|
2519
|
-
# TODO: Sync with the other agents to see what the config should be named, how it should be enabled, how it should be described
|
|
2520
2439
|
:'opentelemetry.enabled' => {
|
|
2440
|
+
:default => false,
|
|
2441
|
+
:public => false,
|
|
2442
|
+
:type => Boolean,
|
|
2443
|
+
:allowed_from_server => false,
|
|
2444
|
+
:description => 'A global configuration option for disabling all OpenTelemetry signals sent through New Relic. If false, no OpenTelemetry signals will be sent to New Relic. If true, the signal-specific enabled config option (e.g. opentelemetry.traces.enabled) determines whether telemetry of that signal type will be reported to New Relic.'
|
|
2445
|
+
},
|
|
2446
|
+
:'opentelemetry.traces.enabled' => {
|
|
2521
2447
|
:default => false,
|
|
2522
2448
|
:public => false,
|
|
2523
2449
|
:type => Boolean,
|
|
@@ -2721,7 +2647,7 @@ module NewRelic
|
|
|
2721
2647
|
:public => false,
|
|
2722
2648
|
:type => Array,
|
|
2723
2649
|
:allowed_from_server => true,
|
|
2724
|
-
:description => 'List of trusted New Relic account IDs for
|
|
2650
|
+
:description => 'List of trusted New Relic account IDs for validating Synthetics monitor requests. This is set by the server.'
|
|
2725
2651
|
},
|
|
2726
2652
|
:trusted_account_key => {
|
|
2727
2653
|
:default => nil,
|
|
@@ -2806,7 +2732,6 @@ module NewRelic
|
|
|
2806
2732
|
:type => Array,
|
|
2807
2733
|
:external => true,
|
|
2808
2734
|
:allowed_from_server => true,
|
|
2809
|
-
:transform => DefaultSource.method(:convert_to_list),
|
|
2810
2735
|
:description => 'Defines API paths the security agent should ignore in IAST scans. Accepts an array of regex patterns matching the URI to ignore. The regex pattern should find a complete match for the URL without the endpoint. For example, `[".*account.*"], [".*/\api\/v1\/.*?\/login"]`'
|
|
2811
2736
|
},
|
|
2812
2737
|
:'security.exclude_from_iast_scan.http_request_parameters.header' => {
|
|
@@ -2815,7 +2740,6 @@ module NewRelic
|
|
|
2815
2740
|
:type => Array,
|
|
2816
2741
|
:external => true,
|
|
2817
2742
|
:allowed_from_server => true,
|
|
2818
|
-
:transform => DefaultSource.method(:convert_to_list),
|
|
2819
2743
|
:description => 'An array of HTTP request headers the security agent should ignore in IAST scans. The array should specify a list of patterns matching the headers to ignore.'
|
|
2820
2744
|
},
|
|
2821
2745
|
:'security.exclude_from_iast_scan.http_request_parameters.query' => {
|
|
@@ -2824,7 +2748,6 @@ module NewRelic
|
|
|
2824
2748
|
:type => Array,
|
|
2825
2749
|
:external => true,
|
|
2826
2750
|
:allowed_from_server => true,
|
|
2827
|
-
:transform => DefaultSource.method(:convert_to_list),
|
|
2828
2751
|
:description => 'An array of HTTP request query parameters the security agent should ignore in IAST scans. The array should specify a list of patterns matching the HTTP request query parameters to ignore.'
|
|
2829
2752
|
},
|
|
2830
2753
|
:'security.exclude_from_iast_scan.http_request_parameters.body' => {
|
|
@@ -2833,7 +2756,6 @@ module NewRelic
|
|
|
2833
2756
|
:type => Array,
|
|
2834
2757
|
:external => true,
|
|
2835
2758
|
:allowed_from_server => true,
|
|
2836
|
-
:transform => DefaultSource.method(:convert_to_list),
|
|
2837
2759
|
:description => 'An array of HTTP request body keys the security agent should ignore in IAST scans.'
|
|
2838
2760
|
},
|
|
2839
2761
|
:'security.exclude_from_iast_scan.iast_detection_category.insecure_settings' => {
|