newrelic_rpm 9.10.2 → 9.12.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +91 -1
- data/README.md +1 -1
- data/lib/new_relic/agent/agent_logger.rb +1 -0
- data/lib/new_relic/agent/configuration/default_source.rb +114 -3
- data/lib/new_relic/agent/database/obfuscator.rb +1 -0
- data/lib/new_relic/agent/error_collector.rb +14 -10
- data/lib/new_relic/agent/instrumentation/aws_sqs/chain.rb +37 -0
- data/lib/new_relic/agent/instrumentation/aws_sqs/instrumentation.rb +67 -0
- data/lib/new_relic/agent/instrumentation/aws_sqs/prepend.rb +21 -0
- data/lib/new_relic/agent/instrumentation/aws_sqs.rb +25 -0
- data/lib/new_relic/agent/instrumentation/bunny/instrumentation.rb +14 -0
- data/lib/new_relic/agent/instrumentation/elasticsearch/instrumentation.rb +1 -1
- data/lib/new_relic/agent/instrumentation/logstasher/chain.rb +21 -0
- data/lib/new_relic/agent/instrumentation/logstasher/instrumentation.rb +24 -0
- data/lib/new_relic/agent/instrumentation/logstasher/prepend.rb +13 -0
- data/lib/new_relic/agent/instrumentation/logstasher.rb +27 -0
- data/lib/new_relic/agent/instrumentation/rack/instrumentation.rb +3 -0
- data/lib/new_relic/agent/instrumentation/rails_notifications/action_controller.rb +9 -5
- data/lib/new_relic/agent/instrumentation/redis/cluster_middleware.rb +26 -0
- data/lib/new_relic/agent/instrumentation/redis/instrumentation.rb +14 -11
- data/lib/new_relic/agent/instrumentation/redis/middleware.rb +3 -0
- data/lib/new_relic/agent/instrumentation/redis.rb +5 -0
- data/lib/new_relic/agent/instrumentation/stripe_subscriber.rb +22 -1
- data/lib/new_relic/agent/local_log_decorator.rb +8 -1
- data/lib/new_relic/agent/log_event_aggregator.rb +91 -26
- data/lib/new_relic/control/instance_methods.rb +1 -0
- data/lib/new_relic/control/private_instance_methods.rb +4 -0
- data/lib/new_relic/control/security_interface.rb +57 -0
- data/lib/new_relic/control.rb +1 -1
- data/lib/new_relic/rack/browser_monitoring.rb +11 -7
- data/lib/new_relic/version.rb +2 -2
- data/lib/tasks/config.rake +5 -2
- data/lib/tasks/gha.rake +31 -0
- data/lib/tasks/helpers/config.html.erb +1 -1
- data/lib/tasks/helpers/format.rb +1 -1
- data/lib/tasks/helpers/newrelicyml.rb +3 -2
- data/lib/tasks/instrumentation_generator/instrumentation.thor +1 -0
- data/newrelic.yml +202 -135
- data/newrelic_rpm.gemspec +2 -0
- data/test/agent_helper.rb +9 -0
- metadata +42 -3
data/lib/tasks/gha.rake
ADDED
@@ -0,0 +1,31 @@
|
|
1
|
+
# This file is distributed under New Relic's license terms.
|
2
|
+
# See https://github.com/newrelic/newrelic-ruby-agent/blob/main/LICENSE for complete details.
|
3
|
+
# frozen_string_literal: true
|
4
|
+
|
5
|
+
require 'yaml'
|
6
|
+
require_relative 'helpers/version_bump'
|
7
|
+
|
8
|
+
# gha = GitHub Actions
|
9
|
+
namespace :gha do
|
10
|
+
# See .github/versions.yml
|
11
|
+
desc 'Update 3rd party action versions across all workflows'
|
12
|
+
task :update_versions do
|
13
|
+
gh_dir = File.expand_path('../../../.github', __FILE__)
|
14
|
+
info = YAML.load_file(File.join(gh_dir, 'versions.yml'))
|
15
|
+
workflows = Dir.glob(File.join(gh_dir, 'workflows', '*.yml'))
|
16
|
+
workflows.each do |workflow|
|
17
|
+
original = File.read(workflow)
|
18
|
+
modified = original.dup
|
19
|
+
info.each do |action, settings|
|
20
|
+
modified.gsub!(/uses: #{action}.*$/, "uses: #{action}@#{settings[:sha]} # tag #{settings[:tag]}")
|
21
|
+
end
|
22
|
+
|
23
|
+
if original != modified
|
24
|
+
File.open(workflow, 'w') { |f| f.puts modified }
|
25
|
+
puts "Updated #{workflow} with changes"
|
26
|
+
else
|
27
|
+
puts "#{workflow} remains unchanged"
|
28
|
+
end
|
29
|
+
end
|
30
|
+
end
|
31
|
+
end
|
@@ -76,7 +76,7 @@ When running the Ruby agent in a Rails app, the agent first looks for the `NEW_R
|
|
76
76
|
When you edit the config file, be sure to:
|
77
77
|
|
78
78
|
* Indent only with two spaces.
|
79
|
-
* Indent only where relevant, in sections such as
|
79
|
+
* Indent only where relevant, in sections such as **`error_collector`**.
|
80
80
|
|
81
81
|
If you do not indent correctly, the agent may throw an `Unable to parse configuration file` error on startup.
|
82
82
|
|
data/lib/tasks/helpers/format.rb
CHANGED
@@ -69,7 +69,7 @@ module Format
|
|
69
69
|
|
70
70
|
def format_description(value)
|
71
71
|
description = ''
|
72
|
-
description += '<
|
72
|
+
description += '<DNT>**DEPRECATED**</DNT> ' if value[:deprecated]
|
73
73
|
description += value[:description]
|
74
74
|
description
|
75
75
|
end
|
@@ -105,8 +105,9 @@ module NewRelicYML
|
|
105
105
|
def self.format_description(description)
|
106
106
|
# remove leading and trailing whitespace
|
107
107
|
description.strip!
|
108
|
-
# wrap text after 80 characters
|
109
|
-
|
108
|
+
# wrap text after 80 characters, assuming we're at one tabstop's (two
|
109
|
+
# spaces') level of indentation already
|
110
|
+
description.gsub!(/(.{1,78})(\s+|\Z)/, "\\1\n")
|
110
111
|
# add hashtags to lines
|
111
112
|
description = description.split("\n").map { |line| " # #{line}" }.join("\n")
|
112
113
|
|