Skip to content

Commit

Permalink
Merge pull request #2962 from newrelic/dev
Browse files Browse the repository at this point in the history
Release 9.16.0
  • Loading branch information
kaylareopelle authored Nov 19, 2024
2 parents da5529b + 8cb06d2 commit 221c000
Show file tree
Hide file tree
Showing 81 changed files with 1,168 additions and 248 deletions.
1 change: 1 addition & 0 deletions .build_ignore
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ lefthook.yml
log/
README.md
test/
trivy.yaml
lib/tasks/bump_version.rb
lib/tasks/coverage_report.rb
lib/tasks/multiverse.rake
Expand Down
4 changes: 2 additions & 2 deletions .github/versions.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
# This file is consumed by lib/tasks/gha.rake
ruby/setup-ruby:
:tag: v1.196.0
:sha: f26937343756480a8cb3ae1f623b9c8d89ed6984
:tag: v1.202.0
:sha: a2bbe5b1b236842c1cb7dd11e8e3b51e0a616acc
actions/checkout:
:tag: v4.1.7
:sha: 692973e3d937129bcbf40652eb9f2f61becf3332
Expand Down
20 changes: 10 additions & 10 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
- name: Configure git
run: 'git config --global init.defaultBranch main'
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # tag v4.1.7
- uses: ruby/setup-ruby@f26937343756480a8cb3ae1f623b9c8d89ed6984 # tag v1.196.0
- uses: ruby/setup-ruby@a2bbe5b1b236842c1cb7dd11e8e3b51e0a616acc # tag v1.202.0
with:
ruby-version: '3.3'
- run: bundle
Expand All @@ -36,7 +36,7 @@ jobs:
strategy:
fail-fast: false
matrix:
ruby-version: [2.4.10, 3.3.5]
ruby-version: [2.4.10, 3.3.6]
steps:
- name: Configure git
run: 'git config --global init.defaultBranch main'
Expand All @@ -49,9 +49,9 @@ jobs:
run: sudo apt-get update; sudo apt-get install -y --no-install-recommends libcurl4-nss-dev libsasl2-dev libxslt1-dev

- name: Install Ruby ${{ matrix.ruby-version }}
uses: ruby/setup-ruby@f26937343756480a8cb3ae1f623b9c8d89ed6984 # tag v1.196.0
uses: ruby/setup-ruby@a2bbe5b1b236842c1cb7dd11e8e3b51e0a616acc # tag v1.202.0
with:
ruby-version: ${{ matrix.ruby-version }}
ruby-version: ${{ matrix.ruby-version }}

- name: Set up mini-envs for ruby version
uses: ./.github/actions/variable-mapper
Expand All @@ -62,7 +62,7 @@ jobs:
"2.4.10": {
"rails": "norails,rails42,rails52"
},
"3.3.5": {
"3.3.6": {
"rails": "norails,rails61,rails72"
}
}
Expand Down Expand Up @@ -217,7 +217,7 @@ jobs:
fail-fast: false
matrix:
multiverse: [agent, ai, background, background_2, kafka, database, frameworks, httpclients, httpclients_2, rails, rest]
ruby-version: [2.4.10, 3.3.5]
ruby-version: [2.4.10, 3.3.6]

steps:
- name: Configure git
Expand All @@ -231,7 +231,7 @@ jobs:
run: sudo apt-get update; sudo apt-get install -y --no-install-recommends libcurl4-nss-dev libsasl2-dev libxslt1-dev

- name: Install Ruby ${{ matrix.ruby-version }}
uses: ruby/setup-ruby@f26937343756480a8cb3ae1f623b9c8d89ed6984 # tag v1.196.0
uses: ruby/setup-ruby@a2bbe5b1b236842c1cb7dd11e8e3b51e0a616acc # tag v1.202.0
with:
ruby-version: ${{ matrix.ruby-version }}

Expand Down Expand Up @@ -317,14 +317,14 @@ jobs:
strategy:
fail-fast: false
matrix:
ruby-version: [2.7.8, 3.3.5]
ruby-version: [2.7.8, 3.3.6]
steps:
- name: Configure git
run: 'git config --global init.defaultBranch main'
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # tag v4.1.7

- name: Install Ruby ${{ matrix.ruby-version }}
uses: ruby/setup-ruby@f26937343756480a8cb3ae1f623b9c8d89ed6984 # tag v1.196.0
uses: ruby/setup-ruby@a2bbe5b1b236842c1cb7dd11e8e3b51e0a616acc # tag v1.202.0
with:
ruby-version: ${{ matrix.ruby-version }}

Expand Down Expand Up @@ -364,7 +364,7 @@ jobs:
- name: Configure git
run: 'git config --global init.defaultBranch main'
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # tag v4.1.7
- uses: ruby/setup-ruby@f26937343756480a8cb3ae1f623b9c8d89ed6984 # tag v1.196.0
- uses: ruby/setup-ruby@a2bbe5b1b236842c1cb7dd11e8e3b51e0a616acc # tag v1.202.0
with:
ruby-version: '3.3'
- run: bundle
Expand Down
18 changes: 9 additions & 9 deletions .github/workflows/ci_cron.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
- name: Configure git
run: 'git config --global init.defaultBranch main'
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # tag v4.1.7
- uses: ruby/setup-ruby@f26937343756480a8cb3ae1f623b9c8d89ed6984 # tag v1.196.0
- uses: ruby/setup-ruby@a2bbe5b1b236842c1cb7dd11e8e3b51e0a616acc # tag v1.202.0
with:
ruby-version: '3.3'
- run: bundle
Expand All @@ -36,7 +36,7 @@ jobs:
strategy:
fail-fast: false
matrix:
ruby-version: [2.4.10, 2.5.9, 2.6.10, 2.7.8, 3.0.7, 3.1.6, 3.2.5, 3.3.5, 3.4.0-preview2]
ruby-version: [2.4.10, 2.5.9, 2.6.10, 2.7.8, 3.0.7, 3.1.6, 3.2.6, 3.3.6, 3.4.0-preview2]

steps:
- name: Configure git
Expand All @@ -50,7 +50,7 @@ jobs:
run: sudo apt-get update; sudo apt-get install -y --no-install-recommends libcurl4-nss-dev libsasl2-dev libxslt1-dev

- name: Install Ruby ${{ matrix.ruby-version }}
uses: ruby/setup-ruby@f26937343756480a8cb3ae1f623b9c8d89ed6984 # tag v1.196.0
uses: ruby/setup-ruby@a2bbe5b1b236842c1cb7dd11e8e3b51e0a616acc # tag v1.202.0
with:
ruby-version: ${{ matrix.ruby-version }}

Expand Down Expand Up @@ -78,10 +78,10 @@ jobs:
"3.1.6": {
"rails": "norails,rails61,rails70,rails71,rails72"
},
"3.2.5": {
"3.2.6": {
"rails": "norails,rails61,rails70,rails71,rails72,railsedge"
},
"3.3.5": {
"3.3.6": {
"rails": "norails,rails61,rails70,rails71,rails72,railsedge"
},
"3.4.0-preview2": {
Expand Down Expand Up @@ -230,7 +230,7 @@ jobs:
fail-fast: false
matrix:
multiverse: [agent, ai, background, background_2, database, kafka, frameworks, httpclients, httpclients_2, rails, rest]
ruby-version: [2.4.10, 2.5.9, 2.6.10, 2.7.8, 3.0.7, 3.1.6, 3.2.5, 3.3.5, 3.4.0-preview2]
ruby-version: [2.4.10, 2.5.9, 2.6.10, 2.7.8, 3.0.7, 3.1.6, 3.2.6, 3.3.6, 3.4.0-preview2]
steps:
- name: Configure git
run: 'git config --global init.defaultBranch main'
Expand All @@ -243,7 +243,7 @@ jobs:
run: sudo apt-get update; sudo apt-get install -y --no-install-recommends libcurl4-nss-dev libsasl2-dev libxslt1-dev

- name: Install Ruby ${{ matrix.ruby-version }}
uses: ruby/setup-ruby@f26937343756480a8cb3ae1f623b9c8d89ed6984 # tag v1.196.0
uses: ruby/setup-ruby@a2bbe5b1b236842c1cb7dd11e8e3b51e0a616acc # tag v1.202.0
with:
ruby-version: ${{ matrix.ruby-version }}

Expand Down Expand Up @@ -308,14 +308,14 @@ jobs:
strategy:
fail-fast: false
matrix:
ruby-version: [2.7.8, 3.0.7, 3.1.6, 3.2.5, 3.3.5, 3.4.0-preview2]
ruby-version: [2.7.8, 3.0.7, 3.1.6, 3.2.6, 3.3.6, 3.4.0-preview2]
steps:
- name: Configure git
run: 'git config --global init.defaultBranch main'
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # tag v4.1.7

- name: Install Ruby ${{ matrix.ruby-version }}
uses: ruby/setup-ruby@f26937343756480a8cb3ae1f623b9c8d89ed6984 # tag v1.196.0
uses: ruby/setup-ruby@a2bbe5b1b236842c1cb7dd11e8e3b51e0a616acc # tag v1.202.0
with:
ruby-version: ${{ matrix.ruby-version }}

Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/ci_jruby.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ jobs:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # tag v4.1.7

- name: Install JRuby
uses: ruby/setup-ruby@f26937343756480a8cb3ae1f623b9c8d89ed6984 # tag v1.196.0
uses: ruby/setup-ruby@a2bbe5b1b236842c1cb7dd11e8e3b51e0a616acc # tag v1.202.0
with:
ruby-version: jruby-9.4.8.0
ruby-version: jruby-9.4.9.0

- name: Bundle
run: bundle install
Expand Down Expand Up @@ -49,9 +49,9 @@ jobs:
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # tag v4.1.7

- name: Install JRuby
uses: ruby/setup-ruby@f26937343756480a8cb3ae1f623b9c8d89ed6984 # tag v1.196.0
uses: ruby/setup-ruby@a2bbe5b1b236842c1cb7dd11e8e3b51e0a616acc # tag v1.202.0
with:
ruby-version: jruby-9.4.8.0
ruby-version: jruby-9.4.9.0

- name: Bundle
run: bundle install
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ci_special.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
run: sudo apt-get update; sudo apt-get install -y --no-install-recommends libcurl4-nss-dev libsasl2-dev libxslt1-dev

- name: Install Ruby 3.4.0-preview2
uses: ruby/setup-ruby@f26937343756480a8cb3ae1f623b9c8d89ed6984 # tag v1.196.0
uses: ruby/setup-ruby@a2bbe5b1b236842c1cb7dd11e8e3b51e0a616acc # tag v1.202.0
with:
ruby-version: 3.4.0-preview2

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/config_docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
pull-requests: write
steps:
- name: Install Ruby 3.3
uses: ruby/setup-ruby@f26937343756480a8cb3ae1f623b9c8d89ed6984 # tag v1.196.0
uses: ruby/setup-ruby@a2bbe5b1b236842c1cb7dd11e8e3b51e0a616acc # tag v1.202.0
with:
ruby-version: 3.3

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/performance_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ jobs:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # tag v4.1.7
with:
ref: 'main'
- uses: ruby/setup-ruby@f26937343756480a8cb3ae1f623b9c8d89ed6984 # tag v1.196.0
- uses: ruby/setup-ruby@a2bbe5b1b236842c1cb7dd11e8e3b51e0a616acc # tag v1.202.0
with:
ruby-version: '3.3'
- run: bundle
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/prerelease.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
pull-requests: write
steps:
- name: Install Ruby 3.3
uses: ruby/setup-ruby@f26937343756480a8cb3ae1f623b9c8d89ed6984 # tag v1.196.0
uses: ruby/setup-ruby@a2bbe5b1b236842c1cb7dd11e8e3b51e0a616acc # tag v1.202.0
with:
ruby-version: 3.3

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
with:
fetch-depth: 0

- uses: ruby/setup-ruby@f26937343756480a8cb3ae1f623b9c8d89ed6984 # tag v1.196.0
- uses: ruby/setup-ruby@a2bbe5b1b236842c1cb7dd11e8e3b51e0a616acc # tag v1.202.0
with:
ruby-version: 3.3

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release_notes.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
contents: write
pull-requests: write
steps:
- uses: ruby/setup-ruby@f26937343756480a8cb3ae1f623b9c8d89ed6984 # tag v1.196.0
- uses: ruby/setup-ruby@a2bbe5b1b236842c1cb7dd11e8e3b51e0a616acc # tag v1.202.0
with:
ruby-version: 3.3
- name: Checkout code
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release_pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
pull-requests: write
steps:
- name: Install Ruby 3.3
uses: ruby/setup-ruby@f26937343756480a8cb3ae1f623b9c8d89ed6984 # tag v1.196.0
uses: ruby/setup-ruby@a2bbe5b1b236842c1cb7dd11e8e3b51e0a616acc # tag v1.202.0
with:
ruby-version: 3.3

Expand Down
16 changes: 9 additions & 7 deletions .github/workflows/security.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,11 @@ jobs:
build:
name: Trivy Scan
runs-on: ubuntu-latest
permissions:
security-events: write
steps:
- name: Install Ruby 3.3
uses: ruby/setup-ruby@f26937343756480a8cb3ae1f623b9c8d89ed6984 # tag v1.196.0
uses: ruby/setup-ruby@a2bbe5b1b236842c1cb7dd11e8e3b51e0a616acc # tag v1.202.0
with:
ruby-version: 3.3

Expand All @@ -25,24 +27,24 @@ jobs:
- name: Run Trivy in table mode
# Table output is only useful when running on a pull request or push.
if: contains(fromJSON('["push", "pull_request"]'), github.event_name)
uses: aquasecurity/trivy-action@915b19bbe73b92a6cf82a1bc12b087c9a19a5fe2 # tag v.0.28.0
uses: aquasecurity/trivy-action@915b19bbe73b92a6cf82a1bc12b087c9a19a5fe2 # tag v0.28.0
with:
scan-type: fs
scan-ref: .
trivy-config: trivy.yaml
format: table
exit-code: 1
ignore-unfixed: true
severity: CRITICAL,HIGH,MEDIUM,LOW

- name: Run Trivy in report mode
# Only generate sarif when running nightly on the dev branch.
if: ${{ github.event_name == 'schedule' }}
uses: aquasecurity/trivy-action@915b19bbe73b92a6cf82a1bc12b087c9a19a5fe2 # tag v.0.28.0
uses: aquasecurity/trivy-action@915b19bbe73b92a6cf82a1bc12b087c9a19a5fe2 # tag v0.28.0
with:
scan-type: fs
scan-ref: .
trivy-config: trivy.yaml
format: sarif
output: trivy-results.sarif
ignore-unfixed: true
severity: 'CRITICAL,HIGH,MEDIUM,LOW'

- name: Upload Trivy scan results to GitHub Security tab
# Only upload sarif when running nightly on the dev branch.
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/slack_notifications.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
gem_notifications:
runs-on: ubuntu-22.04
steps:
- uses: ruby/setup-ruby@f26937343756480a8cb3ae1f623b9c8d89ed6984 # tag v1.196.0
- uses: ruby/setup-ruby@a2bbe5b1b236842c1cb7dd11e8e3b51e0a616acc # tag v1.202.0
with:
ruby-version: 3.3
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # tag v4.1.7
Expand Down Expand Up @@ -47,7 +47,7 @@ jobs:
cve_notifications:
runs-on: ubuntu-22.04
steps:
- uses: ruby/setup-ruby@f26937343756480a8cb3ae1f623b9c8d89ed6984 # tag v1.196.0
- uses: ruby/setup-ruby@a2bbe5b1b236842c1cb7dd11e8e3b51e0a616acc # tag v1.202.0
with:
ruby-version: 3.3
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # tag v4.1.7
Expand Down
26 changes: 23 additions & 3 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,32 @@
# New Relic Ruby Agent Release Notes

## v9.16.0

Version 9.16.0 introduces instrumentation for the aws-sdk-lambda gem, allows users to opt-in to adding labels to logs, updates View Component instrumentation, and fixes a bug with explain plans on Rails 7.2+.

- **Feature: Instrumentation for aws-sdk-lambda**

If the aws-sdk-lambda gem is present and used to invoke remote AWS Lambda functions, timing and error details for the invocations will be reported to New Relic. [PR#2926](https://github.com/newrelic/newrelic-ruby-agent/pull/2926).

- **Feature: Add new configuration options to attach custom tags (labels) to logs**

The Ruby agent now allows you to opt-in to adding your custom tags (labels) to agent-forwarded logs. With custom tags on logs, platform engineers can easily filter, search, and correlate log data for faster and more efficient troubleshooting, improved performance, and optimized resource utilization. [PR#2925](https://github.com/newrelic/newrelic-ruby-agent/pull/2925)

- **Feature: Update View Component instrumentation+**

The `.identifier` method will be formally exposed as part of the View Component public API. The agent will now use this method for building metric names when available, ensuring ongoing compatibility with all View Component versions. [PR#2956](https://github.com/newrelic/newrelic-ruby-agent/pull/2956)

- **Bugfix: Record explain plan traces on Rails 7.2+**

Rails 7.2 removed adapter-specific connection methods (ex. `ActiveRecord::Base.postgresql_connection`) and replaced them with `ActiveRecord::Base.with_connection`. Our explain plan feature relies on making a connection to the database to create an explain plan trace. Due to a bug in our tests, we missed this regression. Now, the agent uses the new method to fetch explain plans on Rails 7.2+. Thank you, [@gsar](https://github.com/gsar) and [@gstark](https://github.com/gstark) for bringing this to our attention! [Issue#2922](https://github.com/newrelic/newrelic-ruby-agent/issues/2922) [PR#2940](https://github.com/newrelic/newrelic-ruby-agent/pull/2940)

## v9.15.0

Version 9.15.0 updates View Componment instrumentation to use a default metric name when one is unavailable, adds a configuration option to associate the AWS account ID with the DynamoDB calls from the AWS SDK, resolves a bug in rdkafka instrumentation when using the karafka-rdkafka gem, resolves a bug in the ruby-kafka instrumentation, fixes a bug with Grape instrumentation, and addresses a bug preventing the agent from running in serverless mode in an AWS Lambda layer.
Version 9.15.0 updates View Component instrumentation to use a default metric name when one is unavailable, adds a configuration option to associate the AWS account ID with the DynamoDB calls from the AWS SDK, resolves a bug in rdkafka instrumentation when using the karafka-rdkafka gem, resolves a bug in the ruby-kafka instrumentation, fixes a bug with Grape instrumentation, and addresses a bug preventing the agent from running in serverless mode in an AWS Lambda layer.

- **Feature: New configuration option cloud.aws.account_id**

A new configuration option has been added, `cloud.aws.account_id`, that will allow New Relic to provide more details about certain calls made using the AWS SDK. One example, is that relationships between AWS services instrumented with New Relic's CloudWatch Metric Streams will have relationships formed in the service map with APM applications. Currently, the DynamoDB instrumentation is the only instrumentation that will make use of this configuration option, but this will be used in future instrumentation as well. [PR#2904](https://github.com/newrelic/newrelic-ruby-agent/pull/2904)
A new configuration option has been added, `cloud.aws.account_id`, that will allow New Relic to provide more details about certain calls made using the AWS SDK. For example, relationships between AWS services instrumented with New Relic's CloudWatch Metric Streams will have relationships formed in the service map with APM applications. Currently, the DynamoDB instrumentation is the only instrumentation that will make use of this configuration option, but this will be used in future instrumentation as well. [PR#2904](https://github.com/newrelic/newrelic-ruby-agent/pull/2904)

- **Feature: Use default `View/component` metric name for unidentified View Components**

Expand Down
Loading

0 comments on commit 221c000

Please sign in to comment.