From f944d78847084658251d6754c814066fe35f3f51 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 9 Aug 2024 15:40:35 -0700 Subject: [PATCH 01/58] chore: update rubocop requirement from ~> 1.64.0 to ~> 1.65.1 (#1101) Updates the requirements on [rubocop](https://github.com/rubocop/rubocop) to permit the latest version. - [Release notes](https://github.com/rubocop/rubocop/releases) - [Changelog](https://github.com/rubocop/rubocop/blob/master/CHANGELOG.md) - [Commits](https://github.com/rubocop/rubocop/compare/v1.64.0...v1.65.1) --- updated-dependencies: - dependency-name: rubocop dependency-type: direct:production ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com> --- Gemfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Gemfile b/Gemfile index bbd1188ad..93039be61 100644 --- a/Gemfile +++ b/Gemfile @@ -7,5 +7,5 @@ source 'https://rubygems.org' gem 'rake', '~> 13.0' -gem 'rubocop', '~> 1.64.0' +gem 'rubocop', '~> 1.65.1' gem 'rubocop-performance', '~> 1.21.0' From a9e6e1a898f89ac6574a85f3f64429fbf4b457db Mon Sep 17 00:00:00 2001 From: "Ben Sheldon [he/him]" Date: Mon, 12 Aug 2024 09:27:45 -0700 Subject: [PATCH 02/58] fix: Use Active Support Lazy Load Hooks to avoid prematurely initializing ActiveRecord::Base and ActiveJob::Base (#1104) Co-authored-by: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com> --- .../active_job/instrumentation.rb | 7 +++- .../active_record/instrumentation.rb | 40 +++++++++---------- 2 files changed, 24 insertions(+), 23 deletions(-) diff --git a/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/instrumentation.rb b/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/instrumentation.rb index d9c6063c5..d4f5dfe3c 100644 --- a/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/instrumentation.rb +++ b/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/instrumentation.rb @@ -63,14 +63,17 @@ def gem_version end def require_dependencies + require 'active_support/lazy_load_hooks' require_relative 'patches/base' require_relative 'handlers' end def patch_activejob - ::ActiveJob::Base.prepend(Patches::Base) unless ::ActiveJob::Base <= Patches::Base - Handlers.subscribe + + ActiveSupport.on_load(:active_job) do + ::ActiveJob::Base.prepend(Patches::Base) unless ::ActiveJob::Base <= Patches::Base + end end end end diff --git a/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/instrumentation.rb b/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/instrumentation.rb index e0d319704..1de788ab0 100644 --- a/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/instrumentation.rb +++ b/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/instrumentation.rb @@ -13,7 +13,7 @@ class Instrumentation < OpenTelemetry::Instrumentation::Base install do |_config| require_dependencies - patch + patch_activerecord end present do @@ -30,27 +30,8 @@ def gem_version ::ActiveRecord.version end - def patch - # The original approach taken here was to patch each individual module of interest. - # However the patches are applied too late in some applications and as a result the - # Active Record models will not have the instrumentation patches applied. - # Prepending the ActiveRecord::Base class is more consistent in applying - # the patches regardless of initialization order. - # - # Modules to prepend to ActiveRecord::Base are still grouped by the source - # module that they are defined in. - # Example: Patches::PersistenceClassMethods refers to https://github.com/rails/rails/blob/v6.1.0/activerecord/lib/active_record/persistence.rb#L10 - ::ActiveRecord::Base.prepend(Patches::Querying) - ::ActiveRecord::Base.prepend(Patches::Persistence) - ::ActiveRecord::Base.prepend(Patches::PersistenceClassMethods) - ::ActiveRecord::Base.prepend(Patches::PersistenceInsertClassMethods) - ::ActiveRecord::Base.prepend(Patches::TransactionsClassMethods) - ::ActiveRecord::Base.prepend(Patches::Validations) - - ::ActiveRecord::Relation.prepend(Patches::RelationPersistence) - end - def require_dependencies + require 'active_support/lazy_load_hooks' require_relative 'patches/querying' require_relative 'patches/persistence' require_relative 'patches/persistence_class_methods' @@ -59,6 +40,23 @@ def require_dependencies require_relative 'patches/validations' require_relative 'patches/relation_persistence' end + + def patch_activerecord + ActiveSupport.on_load(:active_record) do + # Modules to prepend to ActiveRecord::Base are grouped by the source + # module that they are defined in as they are included into ActiveRecord::Base + # Example: Patches::PersistenceClassMethods refers to https://github.com/rails/rails/blob/v6.1.0/activerecord/lib/active_record/persistence.rb#L10 + # which is included into ActiveRecord::Base in https://github.com/rails/rails/blob/914caca2d31bd753f47f9168f2a375921d9e91cc/activerecord/lib/active_record/base.rb#L283 + ::ActiveRecord::Base.prepend(Patches::Querying) + ::ActiveRecord::Base.prepend(Patches::Persistence) + ::ActiveRecord::Base.prepend(Patches::PersistenceClassMethods) + ::ActiveRecord::Base.prepend(Patches::PersistenceInsertClassMethods) + ::ActiveRecord::Base.prepend(Patches::TransactionsClassMethods) + ::ActiveRecord::Base.prepend(Patches::Validations) + + ::ActiveRecord::Relation.prepend(Patches::RelationPersistence) + end + end end end end From c7569f50e4c2aee9d58e761997b3c0a3f908cb31 Mon Sep 17 00:00:00 2001 From: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com> Date: Mon, 12 Aug 2024 13:51:39 -0700 Subject: [PATCH 03/58] test: Update Appraisals for Rails 7.2 (#1112) * chore: Add Appraisals for Rails 7.2 * chore: Add ruby version conditions Rails 7.2.0 requires Ruby 3.1. We test on Ruby 3.0. Prevent running the 7.2 tests on that version. * chore: Restrain pg and que to use Rails < 7.2.0 There is also a bottom constraint of Rails (or Rails-related gems) 6.1.0 to prevent cases where Rails 3.2.0 was installed instead. * chore: Adjust pg activerecord to bottom limit of 6.1 The bundle would install activerecord 3.2 without this constraint. --- instrumentation/action_mailer/Appraisals | 6 ++++++ instrumentation/action_pack/Appraisals | 6 ++++++ instrumentation/action_view/Appraisals | 6 ++++++ instrumentation/active_record/Appraisals | 6 ++++++ instrumentation/active_support/Appraisals | 6 ++++++ instrumentation/pg/opentelemetry-instrumentation-pg.gemspec | 2 +- instrumentation/que/Gemfile | 2 +- instrumentation/rails/Appraisals | 6 ++++++ 8 files changed, 38 insertions(+), 2 deletions(-) diff --git a/instrumentation/action_mailer/Appraisals b/instrumentation/action_mailer/Appraisals index 018ce75b2..e6c48d017 100644 --- a/instrumentation/action_mailer/Appraisals +++ b/instrumentation/action_mailer/Appraisals @@ -15,3 +15,9 @@ end appraise 'rails-7.1' do gem 'rails', '~> 7.1.0' end + +if Gem::Version.new(RUBY_VERSION) >= Gem::Version.new('3.1.0') + appraise 'rails-7.2' do + gem 'rails', '~> 7.2.0' + end +end diff --git a/instrumentation/action_pack/Appraisals b/instrumentation/action_pack/Appraisals index 018ce75b2..e6c48d017 100644 --- a/instrumentation/action_pack/Appraisals +++ b/instrumentation/action_pack/Appraisals @@ -15,3 +15,9 @@ end appraise 'rails-7.1' do gem 'rails', '~> 7.1.0' end + +if Gem::Version.new(RUBY_VERSION) >= Gem::Version.new('3.1.0') + appraise 'rails-7.2' do + gem 'rails', '~> 7.2.0' + end +end diff --git a/instrumentation/action_view/Appraisals b/instrumentation/action_view/Appraisals index 018ce75b2..e6c48d017 100644 --- a/instrumentation/action_view/Appraisals +++ b/instrumentation/action_view/Appraisals @@ -15,3 +15,9 @@ end appraise 'rails-7.1' do gem 'rails', '~> 7.1.0' end + +if Gem::Version.new(RUBY_VERSION) >= Gem::Version.new('3.1.0') + appraise 'rails-7.2' do + gem 'rails', '~> 7.2.0' + end +end diff --git a/instrumentation/active_record/Appraisals b/instrumentation/active_record/Appraisals index 36f3effee..36f641b64 100644 --- a/instrumentation/active_record/Appraisals +++ b/instrumentation/active_record/Appraisals @@ -15,3 +15,9 @@ end appraise 'activerecord-7.1' do gem 'activerecord', '~> 7.1.0' end + +if Gem::Version.new(RUBY_VERSION) >= Gem::Version.new('3.1.0') + appraise 'activerecord-7.2' do + gem 'activerecord', '~> 7.2.0' + end +end diff --git a/instrumentation/active_support/Appraisals b/instrumentation/active_support/Appraisals index 086c10ee9..ef832823b 100644 --- a/instrumentation/active_support/Appraisals +++ b/instrumentation/active_support/Appraisals @@ -15,3 +15,9 @@ end appraise 'activesupport-7.1' do gem 'activesupport', '~> 7.1.0' end + +if Gem::Version.new(RUBY_VERSION) >= Gem::Version.new('3.1.0') + appraise 'activesupport-7.2' do + gem 'activesupport', '~> 7.2.0' + end +end diff --git a/instrumentation/pg/opentelemetry-instrumentation-pg.gemspec b/instrumentation/pg/opentelemetry-instrumentation-pg.gemspec index e193ee246..36fbec863 100644 --- a/instrumentation/pg/opentelemetry-instrumentation-pg.gemspec +++ b/instrumentation/pg/opentelemetry-instrumentation-pg.gemspec @@ -29,7 +29,7 @@ Gem::Specification.new do |spec| spec.add_dependency 'opentelemetry-helpers-sql-obfuscation' spec.add_dependency 'opentelemetry-instrumentation-base', '~> 0.22.1' - spec.add_development_dependency 'activerecord' + spec.add_development_dependency 'activerecord', '> 6.1.0' spec.add_development_dependency 'appraisal', '~> 2.5' spec.add_development_dependency 'bundler', '~> 2.4' spec.add_development_dependency 'minitest', '~> 5.0' diff --git a/instrumentation/que/Gemfile b/instrumentation/que/Gemfile index 46bfbfb01..af89399b5 100644 --- a/instrumentation/que/Gemfile +++ b/instrumentation/que/Gemfile @@ -9,7 +9,7 @@ source 'https://rubygems.org' gemspec group :test do - gem 'activerecord' + gem 'activerecord', '< 7.2.0', '> 6.1.0' gem 'pg' gem 'opentelemetry-helpers-sql-obfuscation', path: '../../helpers/sql-obfuscation' gem 'opentelemetry-instrumentation-base', path: '../base' diff --git a/instrumentation/rails/Appraisals b/instrumentation/rails/Appraisals index 018ce75b2..e6c48d017 100644 --- a/instrumentation/rails/Appraisals +++ b/instrumentation/rails/Appraisals @@ -15,3 +15,9 @@ end appraise 'rails-7.1' do gem 'rails', '~> 7.1.0' end + +if Gem::Version.new(RUBY_VERSION) >= Gem::Version.new('3.1.0') + appraise 'rails-7.2' do + gem 'rails', '~> 7.2.0' + end +end From cac6b47df3eb4463be86684ab70a348e89849d36 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 13 Aug 2024 15:44:47 +0000 Subject: [PATCH 04/58] chore: bump ruby/setup-ruby from 1.187.0 to 1.190.0 (#1092) * chore: bump ruby/setup-ruby from 1.187.0 to 1.190.0 Bumps [ruby/setup-ruby](https://github.com/ruby/setup-ruby) from 1.187.0 to 1.190.0. - [Release notes](https://github.com/ruby/setup-ruby/releases) - [Changelog](https://github.com/ruby/setup-ruby/blob/master/release.rb) - [Commits](https://github.com/ruby/setup-ruby/compare/v1.187.0...v1.190.0) --- updated-dependencies: - dependency-name: ruby/setup-ruby dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] * ci: Update test_gem/action.yml --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com> --- .github/actions/test_gem/action.yml | 4 ++-- .github/workflows/installation-tests.yml | 2 +- .github/workflows/release-hook-on-closed.yml | 2 +- .github/workflows/release-hook-on-push.yml | 2 +- .github/workflows/release-perform.yml | 2 +- .github/workflows/release-please.yaml | 2 +- .github/workflows/release-request-weekly.yml | 2 +- .github/workflows/release-request.yml | 2 +- .github/workflows/release-retry.yml | 2 +- 9 files changed, 10 insertions(+), 10 deletions(-) diff --git a/.github/actions/test_gem/action.yml b/.github/actions/test_gem/action.yml index 7b429a72a..f9b08822e 100644 --- a/.github/actions/test_gem/action.yml +++ b/.github/actions/test_gem/action.yml @@ -66,7 +66,7 @@ runs: # ...but not for appraisals, sadly. - name: Install Ruby ${{ inputs.ruby }} with dependencies if: "${{ steps.setup.outputs.appraisals == 'false' }}" - uses: ruby/setup-ruby@v1.187.0 + uses: ruby/setup-ruby@v1.190.0 with: ruby-version: "${{ inputs.ruby }}" working-directory: "${{ steps.setup.outputs.gem_dir }}" @@ -77,7 +77,7 @@ runs: # If we're using appraisals, do it all manually. - name: Install Ruby ${{ inputs.ruby }} without dependencies if: "${{ steps.setup.outputs.appraisals == 'true' }}" - uses: ruby/setup-ruby@v1.187.0 + uses: ruby/setup-ruby@v1.190.0 with: ruby-version: "${{ inputs.ruby }}" bundler: "latest" diff --git a/.github/workflows/installation-tests.yml b/.github/workflows/installation-tests.yml index ad904e520..374e0b358 100644 --- a/.github/workflows/installation-tests.yml +++ b/.github/workflows/installation-tests.yml @@ -25,7 +25,7 @@ jobs: - uses: actions/checkout@v4 # ATTENTION: Dependabot does not know how to update shared actions file. # If you see it update setup-ruby here also update it as part of actions/test_gem/action.yml - - uses: ruby/setup-ruby@v1.187.0 + - uses: ruby/setup-ruby@v1.190.0 with: ruby-version: ${{ matrix.ruby-version }} - name: "Install Latest Gem Versions on ${{ matrix.ruby-version }}" diff --git a/.github/workflows/release-hook-on-closed.yml b/.github/workflows/release-hook-on-closed.yml index 9986cbde3..520ace6ce 100644 --- a/.github/workflows/release-hook-on-closed.yml +++ b/.github/workflows/release-hook-on-closed.yml @@ -12,7 +12,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.187.0 + uses: ruby/setup-ruby@v1.190.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-hook-on-push.yml b/.github/workflows/release-hook-on-push.yml index 8ec044817..04266970a 100644 --- a/.github/workflows/release-hook-on-push.yml +++ b/.github/workflows/release-hook-on-push.yml @@ -13,7 +13,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.187.0 + uses: ruby/setup-ruby@v1.190.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-perform.yml b/.github/workflows/release-perform.yml index eae34b71b..d3e94376e 100644 --- a/.github/workflows/release-perform.yml +++ b/.github/workflows/release-perform.yml @@ -22,7 +22,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.187.0 + uses: ruby/setup-ruby@v1.190.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-please.yaml b/.github/workflows/release-please.yaml index e8b37c831..adc80a791 100644 --- a/.github/workflows/release-please.yaml +++ b/.github/workflows/release-please.yaml @@ -50,7 +50,7 @@ jobs: chmod 0600 $HOME/.gem/credentials printf -- "---\n:rubygems_api_key: ${GEM_HOST_API_KEY}\n" > $HOME/.gem/credentials - - uses: ruby/setup-ruby@v1.187.0 + - uses: ruby/setup-ruby@v1.190.0 with: ruby-version: "3.0" bundler: latest diff --git a/.github/workflows/release-request-weekly.yml b/.github/workflows/release-request-weekly.yml index eff163c83..3e9b5e0ad 100644 --- a/.github/workflows/release-request-weekly.yml +++ b/.github/workflows/release-request-weekly.yml @@ -12,7 +12,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.187.0 + uses: ruby/setup-ruby@v1.190.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-request.yml b/.github/workflows/release-request.yml index 7497818fe..e3f932b26 100644 --- a/.github/workflows/release-request.yml +++ b/.github/workflows/release-request.yml @@ -16,7 +16,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.187.0 + uses: ruby/setup-ruby@v1.190.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-retry.yml b/.github/workflows/release-retry.yml index 62235e070..6d0088535 100644 --- a/.github/workflows/release-retry.yml +++ b/.github/workflows/release-retry.yml @@ -19,7 +19,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.187.0 + uses: ruby/setup-ruby@v1.190.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo From 70fdad63cda07b976b0d0ce9c9566d5a93d1b978 Mon Sep 17 00:00:00 2001 From: Hannah Ramadan <76922290+hannahramadan@users.noreply.github.com> Date: Wed, 14 Aug 2024 14:31:18 -0700 Subject: [PATCH 05/58] feat: collect pg db.collection_name attribute (#1087) The db.collection.name attribute is conditionally required for Database spans. This PR uses regex to detect the collection name (called table name in PG) and report it as the db.collection.name attribute for PG instrumentation. --------- Co-authored-by: Ariel Valentin Co-authored-by: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com> Co-authored-by: Robb Kidd --- instrumentation/pg/example/pg.rb | 11 +++- .../instrumentation/pg/patches/connection.rb | 18 +++++-- .../pg/test/fixtures/sql_table_name.json | 54 +++++++++++++++++++ .../pg/instrumentation_test.rb | 38 +++++++++++-- 4 files changed, 113 insertions(+), 8 deletions(-) create mode 100644 instrumentation/pg/test/fixtures/sql_table_name.json diff --git a/instrumentation/pg/example/pg.rb b/instrumentation/pg/example/pg.rb index a2b923223..4318d5fc3 100644 --- a/instrumentation/pg/example/pg.rb +++ b/instrumentation/pg/example/pg.rb @@ -18,8 +18,17 @@ password: ENV.fetch('TEST_POSTGRES_PASSWORD') { 'postgres' } ) -# Spans will be printed to your terminal when this statement executes: +# Create a table +conn.exec('CREATE TABLE test_table (id SERIAL PRIMARY KEY, name VARCHAR(50), age INT)') +# Insert data into the table +conn.exec("INSERT INTO test_table (name, age) VALUES ('Peter', 60), ('Paul', 25), ('Mary', 45)") + +# Spans will be printed to your terminal when these statements execute: conn.exec('SELECT 1 AS a, 2 AS b, NULL AS c').each_row { |r| puts r.inspect } +conn.exec('SELECT * FROM test_table').each_row { |r| puts r.inspect } + +# Drop table when done querying +conn.exec('DROP TABLE test_table') # You can use parameterized queries like so: # conn.exec_params('SELECT $1 AS a, $2 AS b, $3 AS c', [1, 2, nil]).each_row { |r| puts r.inspect } diff --git a/instrumentation/pg/lib/opentelemetry/instrumentation/pg/patches/connection.rb b/instrumentation/pg/lib/opentelemetry/instrumentation/pg/patches/connection.rb index 631610acf..98814950b 100644 --- a/instrumentation/pg/lib/opentelemetry/instrumentation/pg/patches/connection.rb +++ b/instrumentation/pg/lib/opentelemetry/instrumentation/pg/patches/connection.rb @@ -14,6 +14,9 @@ module PG module Patches # Module to prepend to PG::Connection for instrumentation module Connection # rubocop:disable Metrics/ModuleLength + # Capture the first word (including letters, digits, underscores, & '.', ) that follows common table commands + TABLE_NAME = /\b(?:FROM|INTO|UPDATE|CREATE\s+TABLE(?:\s+IF\s+NOT\s+EXISTS)?|DROP\s+TABLE(?:\s+IF\s+EXISTS)?|ALTER\s+TABLE(?:\s+IF\s+EXISTS)?)\s+([\w\.]+)/i + PG::Constants::EXEC_ISH_METHODS.each do |method| define_method method do |*args, &block| span_name, attrs = span_attrs(:query, *args) @@ -86,11 +89,13 @@ def lru_cache # module size limit! We can't win here unless we want to start # abstracting things into a million pieces. def span_attrs(kind, *args) + text = args[0] + if kind == :query - operation = extract_operation(args[0]) - sql = obfuscate_sql(args[0]).to_s + operation = extract_operation(text) + sql = obfuscate_sql(text).to_s else - statement_name = args[0] + statement_name = text if kind == :prepare sql = obfuscate_sql(args[1]).to_s @@ -104,6 +109,7 @@ def span_attrs(kind, *args) attrs = { 'db.operation' => validated_operation(operation), 'db.postgresql.prepared_statement_name' => statement_name } attrs['db.statement'] = sql unless config[:db_statement] == :omit + attrs['db.collection.name'] = collection_name(text) attrs.merge!(OpenTelemetry::Instrumentation::PG.attributes) attrs.compact! @@ -125,6 +131,12 @@ def validated_operation(operation) operation if PG::Constants::SQL_COMMANDS.include?(operation) end + def collection_name(text) + text.scan(TABLE_NAME).flatten[0] + rescue StandardError + nil + end + def client_attributes attributes = { 'db.system' => 'postgresql', diff --git a/instrumentation/pg/test/fixtures/sql_table_name.json b/instrumentation/pg/test/fixtures/sql_table_name.json new file mode 100644 index 000000000..eacd9571f --- /dev/null +++ b/instrumentation/pg/test/fixtures/sql_table_name.json @@ -0,0 +1,54 @@ +[ + { + "name": "from", + "sql": "SELECT * FROM test_table" + }, + { + "name": "select_count_from", + "sql": "SELECT COUNT(*) FROM test_table WHERE condition" + }, + { + "name": "from_with_subquery", + "sql": "SELECT * FROM (SELECT * FROM test_table) AS table_alias" + }, + { + "name": "insert_into", + "sql": "INSERT INTO test_table (column1, column2) VALUES (value1, value2)" + }, + { + "name": "update", + "sql": "UPDATE test_table SET column1 = value1 WHERE condition" + }, + { + "name": "delete_from", + "sql": "DELETE FROM test_table WHERE condition" + }, + { + "name": "create_table", + "sql": "CREATE TABLE test_table (column1 datatype, column2 datatype)" + }, + { + "name": "create_table_if_not_exists", + "sql": "CREATE TABLE IF NOT EXISTS test_table (column1 datatype, column2 datatype)" + }, + { + "name": "alter_table", + "sql": "ALTER TABLE test_table ADD column_name datatype" + }, + { + "name": "drop_table", + "sql": "DROP TABLE test_table" + }, + { + "name": "drop_table_if_exists", + "sql": "DROP TABLE IF EXISTS test_table" + }, + { + "name": "insert_into", + "sql": "INSERT INTO test_table values('', 'a''b c',0, 1 , 'd''e f''s h')" + }, + { + "name": "from_with_join", + "sql": "SELECT columns FROM test_table JOIN table2 ON test_table.column = table2.column" + } + ] \ No newline at end of file diff --git a/instrumentation/pg/test/opentelemetry/instrumentation/pg/instrumentation_test.rb b/instrumentation/pg/test/opentelemetry/instrumentation/pg/instrumentation_test.rb index b7e97b9ac..95f470014 100644 --- a/instrumentation/pg/test/opentelemetry/instrumentation/pg/instrumentation_test.rb +++ b/instrumentation/pg/test/opentelemetry/instrumentation/pg/instrumentation_test.rb @@ -12,13 +12,16 @@ require_relative '../../../../lib/opentelemetry/instrumentation/pg/patches/connection' # This test suite requires a running postgres container and dedicated test container -# To run tests: +# To run tests locally: # 1. Build the opentelemetry/opentelemetry-ruby-contrib image # - docker-compose build # 2. Bundle install # - docker-compose run ex-instrumentation-pg-test bundle install -# 3. Run test suite -# - docker-compose run ex-instrumentation-pg-test bundle exec rake test +# 3. Install the dependencies for each Appraisal (https://github.com/thoughtbot/appraisal) +# - docker-compose run ex-instrumentation-pg-test bundle exec appraisal install +# 4. Run test suite with Appraisal +# - docker-compose run ex-instrumentation-pg-test bundle exec appraisal rake test + describe OpenTelemetry::Instrumentation::PG::Instrumentation do let(:instrumentation) { OpenTelemetry::Instrumentation::PG::Instrumentation.instance } let(:exporter) { EXPORTER } @@ -33,6 +36,7 @@ after do # Force re-install of instrumentation instrumentation.instance_variable_set(:@installed, false) + client&.close end describe 'tracing' do @@ -76,7 +80,8 @@ 'db.operation' => 'PREPARE FOR SELECT 1', 'db.postgresql.prepared_statement_name' => 'bar', 'net.peer.ip' => '192.168.0.1', - 'peer.service' => 'example:custom' + 'peer.service' => 'example:custom', + 'db.collection.name' => 'test_table' } end @@ -263,6 +268,13 @@ assert(!span.events.first.attributes['exception.stacktrace'].nil?) end + it 'extracts table name' do + client.query('CREATE TABLE test_table (personid int, name VARCHAR(50))') + + _(span.attributes['db.collection.name']).must_equal 'test_table' + client.query('DROP TABLE test_table') # Drop table to avoid conflicts + end + describe 'when db_statement is obfuscate' do let(:config) { { db_statement: :obfuscate } } @@ -361,5 +373,23 @@ _(span.attributes['net.peer.port']).must_equal port.to_i if PG.const_defined?(:DEF_PORT) end end + + describe '#connection_name' do + def self.load_fixture + data = File.read("#{Dir.pwd}/test/fixtures/sql_table_name.json") + JSON.parse(data) + end + + load_fixture.each do |test_case| + name = test_case['name'] + query = test_case['sql'] + + it "returns the table name for #{name}" do + table_name = client.send(:collection_name, query) + + expect(table_name).must_equal('test_table') + end + end + end end unless ENV['OMIT_SERVICES'] end From f5f8375e662e52f98c276a1523a78f3b3d912f11 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Thu, 15 Aug 2024 12:00:21 -0700 Subject: [PATCH 06/58] release: Release 6 gems (#1117) * release: Release 6 gems * opentelemetry-instrumentation-active_job 0.7.5 (was 0.7.4) * opentelemetry-instrumentation-base 0.22.6 (was 0.22.5) * opentelemetry-instrumentation-active_record 0.7.3 (was 0.7.2) * opentelemetry-instrumentation-pg 0.28.0 (was 0.27.4) * opentelemetry-instrumentation-all 0.63.0 (was 0.62.1) * opentelemetry-instrumentation-rails 0.31.2 (was 0.31.1) * chore: Update CHANGELOG.md Move entry for base gem to top of file * chore: Update opentelemetry-instrumentation-all.gemspec Bump pg version to 0.28.0 * chore: Bump all to 0.63.0 pg has a minor version bump, so all should match * Update instrumentation/all/CHANGELOG.md Co-authored-by: Ariel Valentin --------- Co-authored-by: OpenTelemetry Bot <107717825+opentelemetrybot@users.noreply.github.com> Co-authored-by: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com> Co-authored-by: Kayla Reopelle Co-authored-by: Ariel Valentin --- instrumentation/active_job/CHANGELOG.md | 4 ++++ .../lib/opentelemetry/instrumentation/active_job/version.rb | 2 +- instrumentation/active_record/CHANGELOG.md | 4 ++++ .../opentelemetry/instrumentation/active_record/version.rb | 2 +- instrumentation/all/CHANGELOG.md | 4 ++++ .../all/lib/opentelemetry/instrumentation/all/version.rb | 2 +- .../all/opentelemetry-instrumentation-all.gemspec | 2 +- instrumentation/base/CHANGELOG.md | 4 ++++ .../base/lib/opentelemetry/instrumentation/version.rb | 2 +- instrumentation/pg/CHANGELOG.md | 5 +++++ .../pg/lib/opentelemetry/instrumentation/pg/version.rb | 2 +- instrumentation/rails/CHANGELOG.md | 4 ++++ .../rails/lib/opentelemetry/instrumentation/rails/version.rb | 2 +- 13 files changed, 32 insertions(+), 7 deletions(-) diff --git a/instrumentation/active_job/CHANGELOG.md b/instrumentation/active_job/CHANGELOG.md index 24527ef69..276995b5b 100644 --- a/instrumentation/active_job/CHANGELOG.md +++ b/instrumentation/active_job/CHANGELOG.md @@ -1,5 +1,9 @@ # Release History: opentelemetry-instrumentation-active_job +### v0.7.5 / 2024-08-15 + +* FIXED: Use Active Support Lazy Load Hooks to avoid prematurely initializing ActiveRecord::Base and ActiveJob::Base + ### v0.7.4 / 2024-07-30 * FIXED: Honour dynamic changes in configuration diff --git a/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/version.rb b/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/version.rb index 6e4bf337f..8e2b1f78a 100644 --- a/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/version.rb +++ b/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Instrumentation module ActiveJob - VERSION = '0.7.4' + VERSION = '0.7.5' end end end diff --git a/instrumentation/active_record/CHANGELOG.md b/instrumentation/active_record/CHANGELOG.md index 54f1c74ca..26b94de13 100644 --- a/instrumentation/active_record/CHANGELOG.md +++ b/instrumentation/active_record/CHANGELOG.md @@ -1,5 +1,9 @@ # Release History: opentelemetry-instrumentation-active_record +### v0.7.3 / 2024-08-15 + +* FIXED: Use Active Support Lazy Load Hooks to avoid prematurely initializing ActiveRecord::Base and ActiveJob::Base + ### v0.7.2 / 2024-04-30 * FIXED: Resolve active_record testing issue diff --git a/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/version.rb b/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/version.rb index 7d198a293..6acb0339a 100644 --- a/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/version.rb +++ b/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Instrumentation module ActiveRecord - VERSION = '0.7.2' + VERSION = '0.7.3' end end end diff --git a/instrumentation/all/CHANGELOG.md b/instrumentation/all/CHANGELOG.md index 5e2406e19..cf2807c72 100644 --- a/instrumentation/all/CHANGELOG.md +++ b/instrumentation/all/CHANGELOG.md @@ -1,5 +1,9 @@ # Release History: opentelemetry-instrumentation-all +### v0.63.0 / 2024-08-15 + +* ADDED: Collect pg db.collection_name attribute + ### v0.62.1 / 2024-07-23 * DOCS: Add cspell to CI diff --git a/instrumentation/all/lib/opentelemetry/instrumentation/all/version.rb b/instrumentation/all/lib/opentelemetry/instrumentation/all/version.rb index 59e25a754..bffff61dd 100644 --- a/instrumentation/all/lib/opentelemetry/instrumentation/all/version.rb +++ b/instrumentation/all/lib/opentelemetry/instrumentation/all/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Instrumentation module All - VERSION = '0.62.1' + VERSION = '0.63.0' end end end diff --git a/instrumentation/all/opentelemetry-instrumentation-all.gemspec b/instrumentation/all/opentelemetry-instrumentation-all.gemspec index 8873f4bb8..14e4870f6 100644 --- a/instrumentation/all/opentelemetry-instrumentation-all.gemspec +++ b/instrumentation/all/opentelemetry-instrumentation-all.gemspec @@ -46,7 +46,7 @@ Gem::Specification.new do |spec| spec.add_dependency 'opentelemetry-instrumentation-mongo', '~> 0.22.1' spec.add_dependency 'opentelemetry-instrumentation-mysql2', '~> 0.27.0' spec.add_dependency 'opentelemetry-instrumentation-net_http', '~> 0.22.1' - spec.add_dependency 'opentelemetry-instrumentation-pg', '~> 0.27.0' + spec.add_dependency 'opentelemetry-instrumentation-pg', '~> 0.28.0' spec.add_dependency 'opentelemetry-instrumentation-que', '~> 0.8.0' spec.add_dependency 'opentelemetry-instrumentation-racecar', '~> 0.3.0' spec.add_dependency 'opentelemetry-instrumentation-rack', '~> 0.24.0' diff --git a/instrumentation/base/CHANGELOG.md b/instrumentation/base/CHANGELOG.md index c689d8f9e..ff759973d 100644 --- a/instrumentation/base/CHANGELOG.md +++ b/instrumentation/base/CHANGELOG.md @@ -1,5 +1,9 @@ # Release History: opentelemetry-instrumentation-base +### v0.22.6 / 2024-08-15 + +* FIXED: Fix the issue of wrong log msg + ### v0.22.5 / 2024-07-23 * DOCS: Add cspell to CI diff --git a/instrumentation/base/lib/opentelemetry/instrumentation/version.rb b/instrumentation/base/lib/opentelemetry/instrumentation/version.rb index ac1fdd520..6d32c74e9 100644 --- a/instrumentation/base/lib/opentelemetry/instrumentation/version.rb +++ b/instrumentation/base/lib/opentelemetry/instrumentation/version.rb @@ -6,6 +6,6 @@ module OpenTelemetry module Instrumentation - VERSION = '0.22.5' + VERSION = '0.22.6' end end diff --git a/instrumentation/pg/CHANGELOG.md b/instrumentation/pg/CHANGELOG.md index af01546b4..36a25243a 100644 --- a/instrumentation/pg/CHANGELOG.md +++ b/instrumentation/pg/CHANGELOG.md @@ -1,5 +1,10 @@ # Release History: opentelemetry-instrumentation-pg +### v0.28.0 / 2024-08-15 + +* ADDED: Collect pg db.collection_name attribute +* FIXED: Update versions to be tested (includes drop support for pg 1.2) + ### v0.27.4 / 2024-07-23 * DOCS: Add cspell to CI diff --git a/instrumentation/pg/lib/opentelemetry/instrumentation/pg/version.rb b/instrumentation/pg/lib/opentelemetry/instrumentation/pg/version.rb index 5039c662a..4496dc1aa 100644 --- a/instrumentation/pg/lib/opentelemetry/instrumentation/pg/version.rb +++ b/instrumentation/pg/lib/opentelemetry/instrumentation/pg/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Instrumentation module PG - VERSION = '0.27.4' + VERSION = '0.28.0' end end end diff --git a/instrumentation/rails/CHANGELOG.md b/instrumentation/rails/CHANGELOG.md index 64e6a286a..f3a462ef8 100644 --- a/instrumentation/rails/CHANGELOG.md +++ b/instrumentation/rails/CHANGELOG.md @@ -1,5 +1,9 @@ # Release History: opentelemetry-instrumentation-rails +### v0.31.2 / 2024-08-15 + +* FIXED: Rails instrumentation should load ActiveJob instrumentation + ### v0.31.1 / 2024-07-23 * DOCS: Add cspell to CI diff --git a/instrumentation/rails/lib/opentelemetry/instrumentation/rails/version.rb b/instrumentation/rails/lib/opentelemetry/instrumentation/rails/version.rb index 9a76e9151..490c785c4 100644 --- a/instrumentation/rails/lib/opentelemetry/instrumentation/rails/version.rb +++ b/instrumentation/rails/lib/opentelemetry/instrumentation/rails/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Instrumentation module Rails - VERSION = '0.31.1' + VERSION = '0.31.2' end end end From c51c0eed894429d33a4de3b8a981a84971c19611 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Lavoie?= Date: Thu, 15 Aug 2024 17:07:40 -0400 Subject: [PATCH 07/58] fix(active-job): Prefix ::ActiveSupport when installing the instrumentation (#1120) fix(active-job) Prefix ::ActiveSupport when installing the instrumentation Otherwise, `ActiveSupport` ends up resolving to `OpenTelemetry::Instrumentation::ActiveSupport`. `OpenTelemetry::Instrumentation::Registry#install_instrumentation` rescues the exception, so the prepend ends up being (somewhat) silently dropped. --- .../opentelemetry/instrumentation/active_job/instrumentation.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/instrumentation.rb b/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/instrumentation.rb index d4f5dfe3c..a5b9d22e0 100644 --- a/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/instrumentation.rb +++ b/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/instrumentation.rb @@ -71,7 +71,7 @@ def require_dependencies def patch_activejob Handlers.subscribe - ActiveSupport.on_load(:active_job) do + ::ActiveSupport.on_load(:active_job) do ::ActiveJob::Base.prepend(Patches::Base) unless ::ActiveJob::Base <= Patches::Base end end From efaa4040b6e84989efd241d0f988276c83c7a762 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Thu, 15 Aug 2024 17:39:54 -0500 Subject: [PATCH 08/58] release: Release 2 gems (#1122) --- instrumentation/action_view/CHANGELOG.md | 4 ++++ .../lib/opentelemetry/instrumentation/action_view/version.rb | 2 +- instrumentation/active_job/CHANGELOG.md | 4 ++++ .../lib/opentelemetry/instrumentation/active_job/version.rb | 2 +- 4 files changed, 10 insertions(+), 2 deletions(-) diff --git a/instrumentation/action_view/CHANGELOG.md b/instrumentation/action_view/CHANGELOG.md index 0574ba216..c89ba736d 100644 --- a/instrumentation/action_view/CHANGELOG.md +++ b/instrumentation/action_view/CHANGELOG.md @@ -1,5 +1,9 @@ # Release History: opentelemetry-instrumentation-action_view +### v0.7.2 / 2024-08-15 + +* (No Significant Changes) + ### v0.7.1 / 2024-07-23 * DOCS: Add cspell to CI diff --git a/instrumentation/action_view/lib/opentelemetry/instrumentation/action_view/version.rb b/instrumentation/action_view/lib/opentelemetry/instrumentation/action_view/version.rb index 2b41d3fbe..6ac0d5cc4 100644 --- a/instrumentation/action_view/lib/opentelemetry/instrumentation/action_view/version.rb +++ b/instrumentation/action_view/lib/opentelemetry/instrumentation/action_view/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Instrumentation module ActionView - VERSION = '0.7.1' + VERSION = '0.7.2' end end end diff --git a/instrumentation/active_job/CHANGELOG.md b/instrumentation/active_job/CHANGELOG.md index 276995b5b..46e2e74cb 100644 --- a/instrumentation/active_job/CHANGELOG.md +++ b/instrumentation/active_job/CHANGELOG.md @@ -1,5 +1,9 @@ # Release History: opentelemetry-instrumentation-active_job +### v0.7.6 / 2024-08-15 + +* FIXED: Prefix ::ActiveSupport when installing the instrumentation + ### v0.7.5 / 2024-08-15 * FIXED: Use Active Support Lazy Load Hooks to avoid prematurely initializing ActiveRecord::Base and ActiveJob::Base diff --git a/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/version.rb b/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/version.rb index 8e2b1f78a..1386eccdf 100644 --- a/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/version.rb +++ b/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Instrumentation module ActiveJob - VERSION = '0.7.5' + VERSION = '0.7.6' end end end From 9ce7e3932293259e6c82cbf008722b57e4e7b41c Mon Sep 17 00:00:00 2001 From: Ryan Harkins Date: Mon, 19 Aug 2024 12:54:10 +0100 Subject: [PATCH 09/58] fix: use ActiveSupport from top-level namespace (#1123) --- .../instrumentation/active_record/instrumentation.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/instrumentation.rb b/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/instrumentation.rb index 1de788ab0..6d76b91f4 100644 --- a/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/instrumentation.rb +++ b/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/instrumentation.rb @@ -42,7 +42,7 @@ def require_dependencies end def patch_activerecord - ActiveSupport.on_load(:active_record) do + ::ActiveSupport.on_load(:active_record) do # Modules to prepend to ActiveRecord::Base are grouped by the source # module that they are defined in as they are included into ActiveRecord::Base # Example: Patches::PersistenceClassMethods refers to https://github.com/rails/rails/blob/v6.1.0/activerecord/lib/active_record/persistence.rb#L10 From a5648173c25576c4a2d5083958eb5ff0e7092d45 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Mon, 19 Aug 2024 07:49:25 -0500 Subject: [PATCH 10/58] release: Release opentelemetry-instrumentation-active_record 0.7.4 (was 0.7.3) (#1125) --- instrumentation/active_record/CHANGELOG.md | 4 ++++ .../opentelemetry/instrumentation/active_record/version.rb | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/instrumentation/active_record/CHANGELOG.md b/instrumentation/active_record/CHANGELOG.md index 26b94de13..e78491912 100644 --- a/instrumentation/active_record/CHANGELOG.md +++ b/instrumentation/active_record/CHANGELOG.md @@ -1,5 +1,9 @@ # Release History: opentelemetry-instrumentation-active_record +### v0.7.4 / 2024-08-19 + +* FIXED: Use ActiveSupport from top-level namespace (NoMethodError on_load) + ### v0.7.3 / 2024-08-15 * FIXED: Use Active Support Lazy Load Hooks to avoid prematurely initializing ActiveRecord::Base and ActiveJob::Base diff --git a/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/version.rb b/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/version.rb index 6acb0339a..8726c55e3 100644 --- a/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/version.rb +++ b/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Instrumentation module ActiveRecord - VERSION = '0.7.3' + VERSION = '0.7.4' end end end From 9927df8012a51a34653c36f373a2e8d9b19ed7cf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Lavoie?= Date: Wed, 21 Aug 2024 12:00:10 -0400 Subject: [PATCH 11/58] fix(active-job): Propagate context between enqueue and perform (#1132) --- .../active_job/handlers/enqueue.rb | 3 +- .../active_job/handlers/perform.rb | 2 +- .../active_job/handlers/perform_test.rb | 70 +++++++++++++++++++ 3 files changed, 73 insertions(+), 2 deletions(-) diff --git a/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/handlers/enqueue.rb b/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/handlers/enqueue.rb index 23dab795e..9350516ff 100644 --- a/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/handlers/enqueue.rb +++ b/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/handlers/enqueue.rb @@ -23,8 +23,9 @@ def start_span(name, _id, payload) job = payload.fetch(:job) span_name = span_name(job, EVENT_NAME) span = tracer.start_span(span_name, kind: :producer, attributes: @mapper.call(payload)) + token = OpenTelemetry::Context.attach(OpenTelemetry::Trace.context_with_span(span)) OpenTelemetry.propagation.inject(job.__otel_headers) # This must be transmitted over the wire - { span: span, ctx_token: OpenTelemetry::Context.attach(OpenTelemetry::Trace.context_with_span(span)) } + { span: span, ctx_token: token } end end end diff --git a/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/handlers/perform.rb b/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/handlers/perform.rb index b617b8ee2..88141f754 100644 --- a/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/handlers/perform.rb +++ b/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/handlers/perform.rb @@ -27,7 +27,7 @@ def start_span(name, _id, payload) # TODO: Refactor into a propagation strategy propagation_style = @config[:propagation_style] if propagation_style == :child - span = tracer.start_span(span_name, kind: :consumer, attributes: @mapper.call(payload)) + span = tracer.start_span(span_name, with_parent: parent_context, kind: :consumer, attributes: @mapper.call(payload)) else span_context = OpenTelemetry::Trace.current_span(parent_context).context links = [OpenTelemetry::Trace::Link.new(span_context)] if span_context.valid? && propagation_style == :link diff --git a/instrumentation/active_job/test/opentelemetry/instrumentation/active_job/handlers/perform_test.rb b/instrumentation/active_job/test/opentelemetry/instrumentation/active_job/handlers/perform_test.rb index 3227bf62f..de886c206 100644 --- a/instrumentation/active_job/test/opentelemetry/instrumentation/active_job/handlers/perform_test.rb +++ b/instrumentation/active_job/test/opentelemetry/instrumentation/active_job/handlers/perform_test.rb @@ -176,6 +176,18 @@ _(process_span.links[0].span_context.span_id).must_equal(publish_span.span_id) end + it 'does not interfere with an outer span' do + instrumentation.tracer.in_span('outer span') do + TestJob.perform_later + end + + _(publish_span.trace_id).wont_equal(process_span.trace_id) + + _(process_span.total_recorded_links).must_equal(1) + _(process_span.links[0].span_context.trace_id).must_equal(publish_span.trace_id) + _(process_span.links[0].span_context.span_id).must_equal(publish_span.span_id) + end + it 'propagates baggage' do ctx = OpenTelemetry::Baggage.set_value('testing_baggage', 'it_worked') OpenTelemetry::Context.with_current(ctx) do @@ -190,6 +202,30 @@ _(process_span.attributes['success']).must_equal(true) end + + describe 'with an async queue adapter' do + before do + begin + ActiveJob::Base.queue_adapter.shutdown + rescue StandardError + nil + end + + singleton_class.include ActiveJob::TestHelper + ActiveJob::Base.queue_adapter = :test + end + + it 'creates span links in separate traces' do + TestJob.perform_later + perform_enqueued_jobs + + _(publish_span.trace_id).wont_equal(process_span.trace_id) + + _(process_span.total_recorded_links).must_equal(1) + _(process_span.links[0].span_context.trace_id).must_equal(publish_span.trace_id) + _(process_span.links[0].span_context.span_id).must_equal(publish_span.span_id) + end + end end describe 'when configured to do parent/child spans' do @@ -204,6 +240,17 @@ _(process_span.parent_span_id).must_equal(publish_span.span_id) end + it 'does not interfere with an outer span' do + instrumentation.tracer.in_span('outer span') do + TestJob.perform_later + end + + _(process_span.total_recorded_links).must_equal(0) + + _(publish_span.trace_id).must_equal(process_span.trace_id) + _(process_span.parent_span_id).must_equal(publish_span.span_id) + end + it 'propagates baggage' do ctx = OpenTelemetry::Baggage.set_value('testing_baggage', 'it_worked') OpenTelemetry::Context.with_current(ctx) do @@ -215,6 +262,29 @@ _(process_span.parent_span_id).must_equal(publish_span.span_id) _(process_span.attributes['success']).must_equal(true) end + + describe 'with an async queue adapter' do + before do + begin + ActiveJob::Base.queue_adapter.shutdown + rescue StandardError + nil + end + + singleton_class.include ActiveJob::TestHelper + ActiveJob::Base.queue_adapter = :test + end + + it 'creates a parent/child relationship' do + TestJob.perform_later + perform_enqueued_jobs + + _(process_span.total_recorded_links).must_equal(0) + + _(publish_span.trace_id).must_equal(process_span.trace_id) + _(process_span.parent_span_id).must_equal(publish_span.span_id) + end + end end describe 'when explicitly configure for no propagation' do From e15f2d93a15cfacb712188e2811f52ba401f1e80 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Wed, 21 Aug 2024 12:46:44 -0500 Subject: [PATCH 12/58] release: Release opentelemetry-instrumentation-active_job 0.7.7 (was 0.7.6) (#1133) * release: Release opentelemetry-instrumentation-active_job 0.7.7 (was 0.7.6) * ci: Force --------- Co-authored-by: OpenTelemetry Bot <107717825+opentelemetrybot@users.noreply.github.com> Co-authored-by: Ariel Valentin --- instrumentation/active_job/CHANGELOG.md | 4 ++++ .../lib/opentelemetry/instrumentation/active_job/version.rb | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/instrumentation/active_job/CHANGELOG.md b/instrumentation/active_job/CHANGELOG.md index 46e2e74cb..6bda338c4 100644 --- a/instrumentation/active_job/CHANGELOG.md +++ b/instrumentation/active_job/CHANGELOG.md @@ -1,5 +1,9 @@ # Release History: opentelemetry-instrumentation-active_job +### v0.7.7 / 2024-08-21 + +* FIXED: Propagate context between enqueue and perform + ### v0.7.6 / 2024-08-15 * FIXED: Prefix ::ActiveSupport when installing the instrumentation diff --git a/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/version.rb b/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/version.rb index 1386eccdf..587255970 100644 --- a/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/version.rb +++ b/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Instrumentation module ActiveJob - VERSION = '0.7.6' + VERSION = '0.7.7' end end end From 5a7bde5cc4bec99823da3d00476deb7d53570c39 Mon Sep 17 00:00:00 2001 From: Ariel Valentin Date: Thu, 22 Aug 2024 13:14:54 -0500 Subject: [PATCH 13/58] fix: ActionView Support Legacy Formats (#1134) --- .../instrumentation/action_view.rb | 2 +- .../action_view/instrumentation.rb | 38 ++++++++++++++++++- .../instrumentation/action_view/railtie.rb | 11 ++++-- ...emetry-instrumentation-action_view.gemspec | 2 +- 4 files changed, 46 insertions(+), 7 deletions(-) diff --git a/instrumentation/action_view/lib/opentelemetry/instrumentation/action_view.rb b/instrumentation/action_view/lib/opentelemetry/instrumentation/action_view.rb index ef341c0cd..ad42d0dec 100644 --- a/instrumentation/action_view/lib/opentelemetry/instrumentation/action_view.rb +++ b/instrumentation/action_view/lib/opentelemetry/instrumentation/action_view.rb @@ -9,7 +9,7 @@ module OpenTelemetry module Instrumentation - # Contains the OpenTelemetry instrumentation for the ActionView gem + # (see OpenTelemetry::Instrumentation::ActionView::Instrumentation) module ActionView end end diff --git a/instrumentation/action_view/lib/opentelemetry/instrumentation/action_view/instrumentation.rb b/instrumentation/action_view/lib/opentelemetry/instrumentation/action_view/instrumentation.rb index 9087d4475..bb9b60056 100644 --- a/instrumentation/action_view/lib/opentelemetry/instrumentation/action_view/instrumentation.rb +++ b/instrumentation/action_view/lib/opentelemetry/instrumentation/action_view/instrumentation.rb @@ -7,7 +7,42 @@ module OpenTelemetry module Instrumentation module ActionView - # The Instrumentation class contains logic to detect and install the ActionView instrumentation + # The {OpenTelemetry::Instrumentation::ActionView::Instrumentation} class contains logic to detect and install the ActionView instrumentation + # + # Installation and configuration of this instrumentation is done within the + # {https://www.rubydoc.info/gems/opentelemetry-sdk/OpenTelemetry/SDK#configure-instance_method OpenTelemetry::SDK#configure} + # block, calling {https://www.rubydoc.info/gems/opentelemetry-sdk/OpenTelemetry%2FSDK%2FConfigurator:use use()} + # or {https://www.rubydoc.info/gems/opentelemetry-sdk/OpenTelemetry%2FSDK%2FConfigurator:use_all use_all()}. + # + # ## Configuration keys and options + # + # ### `:disallowed_notification_payload_keys` + # + # Specifies an array of keys that should be excluded from the notification payload as span attributes. + # + # ### `:notification_payload_transform` + # + # - `proc` **default** `nil` + # + # Specifies custom proc used to extract span attributes form the notification payload. + # Use this to rename keys, extract nested values, or perform any other custom logic. + # + # ### `:legacy_span_names` + # + # - `boolean` **default** `false` + # + # Specifies whether spans names should use the legacy format where the subscription was reverse ordered and white space separated. (Ex. `action_view render_template`) + # If set to `true`, the span name will match the name of the notification itself. (Ex. `render_template.action_view`) + # + # @example An explicit default configuration + # OpenTelemetry::SDK.configure do |c| + # c.use_all({ + # 'OpenTelemetry::Instrumentation::ActionView' => { + # disallowed_notification_payload_keys: [], + # legacy_span_names: true, + # }, + # }) + # end class Instrumentation < OpenTelemetry::Instrumentation::Base MINIMUM_VERSION = Gem::Version.new('6.1.0') install do |_config| @@ -24,6 +59,7 @@ class Instrumentation < OpenTelemetry::Instrumentation::Base option :disallowed_notification_payload_keys, default: [], validate: :array option :notification_payload_transform, default: nil, validate: :callable + option :legacy_span_names, default: false, validate: :boolean private diff --git a/instrumentation/action_view/lib/opentelemetry/instrumentation/action_view/railtie.rb b/instrumentation/action_view/lib/opentelemetry/instrumentation/action_view/railtie.rb index 276af1106..2c2bf381a 100644 --- a/instrumentation/action_view/lib/opentelemetry/instrumentation/action_view/railtie.rb +++ b/instrumentation/action_view/lib/opentelemetry/instrumentation/action_view/railtie.rb @@ -19,13 +19,16 @@ class Railtie < ::Rails::Railtie config.after_initialize do ::OpenTelemetry::Instrumentation::ActiveSupport::Instrumentation.instance.install({}) + instance = ::OpenTelemetry::Instrumentation::ActionView::Instrumentation.instance + span_name_formatter = instance.config[:legacy_span_names] ? ::OpenTelemetry::Instrumentation::ActiveSupport::LEGACY_NAME_FORMATTER : nil + SUBSCRIPTIONS.each do |subscription_name| - config = ActionView::Instrumentation.instance.config ::OpenTelemetry::Instrumentation::ActiveSupport.subscribe( - ActionView::Instrumentation.instance.tracer, + instance.tracer, subscription_name, - config[:notification_payload_transform], - config[:disallowed_notification_payload_keys] + instance.config[:notification_payload_transform], + instance.config[:disallowed_notification_payload_keys], + span_name_formatter: span_name_formatter ) end end diff --git a/instrumentation/action_view/opentelemetry-instrumentation-action_view.gemspec b/instrumentation/action_view/opentelemetry-instrumentation-action_view.gemspec index 27bd8239f..825106243 100644 --- a/instrumentation/action_view/opentelemetry-instrumentation-action_view.gemspec +++ b/instrumentation/action_view/opentelemetry-instrumentation-action_view.gemspec @@ -26,7 +26,7 @@ Gem::Specification.new do |spec| spec.required_ruby_version = '>= 3.0' spec.add_dependency 'opentelemetry-api', '~> 1.0' - spec.add_dependency 'opentelemetry-instrumentation-active_support', '~> 0.1' + spec.add_dependency 'opentelemetry-instrumentation-active_support', '~> 0.6' spec.add_dependency 'opentelemetry-instrumentation-base', '~> 0.22.1' spec.add_development_dependency 'appraisal', '~> 2.5' From f817d6b941d0e43215c59e7d5c90f778ad824ee1 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Sun, 25 Aug 2024 12:41:56 -0500 Subject: [PATCH 14/58] release: Release opentelemetry-instrumentation-action_view 0.7.3 (was 0.7.2) (#1135) --- instrumentation/action_view/CHANGELOG.md | 4 ++++ .../lib/opentelemetry/instrumentation/action_view/version.rb | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/instrumentation/action_view/CHANGELOG.md b/instrumentation/action_view/CHANGELOG.md index c89ba736d..0f625330a 100644 --- a/instrumentation/action_view/CHANGELOG.md +++ b/instrumentation/action_view/CHANGELOG.md @@ -1,5 +1,9 @@ # Release History: opentelemetry-instrumentation-action_view +### v0.7.3 / 2024-08-23 + +* FIXED: ActionView Support Legacy Formats + ### v0.7.2 / 2024-08-15 * (No Significant Changes) diff --git a/instrumentation/action_view/lib/opentelemetry/instrumentation/action_view/version.rb b/instrumentation/action_view/lib/opentelemetry/instrumentation/action_view/version.rb index 6ac0d5cc4..9326fe3a1 100644 --- a/instrumentation/action_view/lib/opentelemetry/instrumentation/action_view/version.rb +++ b/instrumentation/action_view/lib/opentelemetry/instrumentation/action_view/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Instrumentation module ActionView - VERSION = '0.7.2' + VERSION = '0.7.3' end end end From dbe3e6aabb8616f7b0044bbcc92321641dcd039f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 6 Sep 2024 09:43:23 -0700 Subject: [PATCH 15/58] chore: bump ruby/setup-ruby from 1.190.0 to 1.191.0 (#1147) * chore: bump ruby/setup-ruby from 1.190.0 to 1.191.0 Bumps [ruby/setup-ruby](https://github.com/ruby/setup-ruby) from 1.190.0 to 1.191.0. - [Release notes](https://github.com/ruby/setup-ruby/releases) - [Changelog](https://github.com/ruby/setup-ruby/blob/master/release.rb) - [Commits](https://github.com/ruby/setup-ruby/compare/v1.190.0...v1.191.0) --- updated-dependencies: - dependency-name: ruby/setup-ruby dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] * chore: Bump setup-ruby in action.yml Upgrade from 1.190.0 to 1.191.0 --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Kayla Reopelle --- .github/actions/test_gem/action.yml | 4 ++-- .github/workflows/installation-tests.yml | 2 +- .github/workflows/release-hook-on-closed.yml | 2 +- .github/workflows/release-hook-on-push.yml | 2 +- .github/workflows/release-perform.yml | 2 +- .github/workflows/release-please.yaml | 2 +- .github/workflows/release-request-weekly.yml | 2 +- .github/workflows/release-request.yml | 2 +- .github/workflows/release-retry.yml | 2 +- 9 files changed, 10 insertions(+), 10 deletions(-) diff --git a/.github/actions/test_gem/action.yml b/.github/actions/test_gem/action.yml index f9b08822e..25418da4c 100644 --- a/.github/actions/test_gem/action.yml +++ b/.github/actions/test_gem/action.yml @@ -66,7 +66,7 @@ runs: # ...but not for appraisals, sadly. - name: Install Ruby ${{ inputs.ruby }} with dependencies if: "${{ steps.setup.outputs.appraisals == 'false' }}" - uses: ruby/setup-ruby@v1.190.0 + uses: ruby/setup-ruby@v1.191.0 with: ruby-version: "${{ inputs.ruby }}" working-directory: "${{ steps.setup.outputs.gem_dir }}" @@ -77,7 +77,7 @@ runs: # If we're using appraisals, do it all manually. - name: Install Ruby ${{ inputs.ruby }} without dependencies if: "${{ steps.setup.outputs.appraisals == 'true' }}" - uses: ruby/setup-ruby@v1.190.0 + uses: ruby/setup-ruby@v1.191.0 with: ruby-version: "${{ inputs.ruby }}" bundler: "latest" diff --git a/.github/workflows/installation-tests.yml b/.github/workflows/installation-tests.yml index 374e0b358..e71acac29 100644 --- a/.github/workflows/installation-tests.yml +++ b/.github/workflows/installation-tests.yml @@ -25,7 +25,7 @@ jobs: - uses: actions/checkout@v4 # ATTENTION: Dependabot does not know how to update shared actions file. # If you see it update setup-ruby here also update it as part of actions/test_gem/action.yml - - uses: ruby/setup-ruby@v1.190.0 + - uses: ruby/setup-ruby@v1.191.0 with: ruby-version: ${{ matrix.ruby-version }} - name: "Install Latest Gem Versions on ${{ matrix.ruby-version }}" diff --git a/.github/workflows/release-hook-on-closed.yml b/.github/workflows/release-hook-on-closed.yml index 520ace6ce..ef5cb741e 100644 --- a/.github/workflows/release-hook-on-closed.yml +++ b/.github/workflows/release-hook-on-closed.yml @@ -12,7 +12,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.190.0 + uses: ruby/setup-ruby@v1.191.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-hook-on-push.yml b/.github/workflows/release-hook-on-push.yml index 04266970a..bbe48deb2 100644 --- a/.github/workflows/release-hook-on-push.yml +++ b/.github/workflows/release-hook-on-push.yml @@ -13,7 +13,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.190.0 + uses: ruby/setup-ruby@v1.191.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-perform.yml b/.github/workflows/release-perform.yml index d3e94376e..c4b13ca12 100644 --- a/.github/workflows/release-perform.yml +++ b/.github/workflows/release-perform.yml @@ -22,7 +22,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.190.0 + uses: ruby/setup-ruby@v1.191.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-please.yaml b/.github/workflows/release-please.yaml index adc80a791..c8cfb286f 100644 --- a/.github/workflows/release-please.yaml +++ b/.github/workflows/release-please.yaml @@ -50,7 +50,7 @@ jobs: chmod 0600 $HOME/.gem/credentials printf -- "---\n:rubygems_api_key: ${GEM_HOST_API_KEY}\n" > $HOME/.gem/credentials - - uses: ruby/setup-ruby@v1.190.0 + - uses: ruby/setup-ruby@v1.191.0 with: ruby-version: "3.0" bundler: latest diff --git a/.github/workflows/release-request-weekly.yml b/.github/workflows/release-request-weekly.yml index 3e9b5e0ad..6865df226 100644 --- a/.github/workflows/release-request-weekly.yml +++ b/.github/workflows/release-request-weekly.yml @@ -12,7 +12,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.190.0 + uses: ruby/setup-ruby@v1.191.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-request.yml b/.github/workflows/release-request.yml index e3f932b26..d2b0c3ea5 100644 --- a/.github/workflows/release-request.yml +++ b/.github/workflows/release-request.yml @@ -16,7 +16,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.190.0 + uses: ruby/setup-ruby@v1.191.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-retry.yml b/.github/workflows/release-retry.yml index 6d0088535..626146815 100644 --- a/.github/workflows/release-retry.yml +++ b/.github/workflows/release-retry.yml @@ -19,7 +19,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.190.0 + uses: ruby/setup-ruby@v1.191.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo From 012b2c26e7c885e12dd93090051a7dd10170b134 Mon Sep 17 00:00:00 2001 From: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com> Date: Tue, 10 Sep 2024 13:03:10 -0700 Subject: [PATCH 16/58] chore: Update Rubocop to 1.66.0 (#1151) * chore: Update Rubocop to 1.66.0 * chore: Fix Style/RedundantInterpolationUnfreeze --- .instrumentation_generator/templates/gemspec.tt | 2 +- Gemfile | 2 +- helpers/mysql/opentelemetry-helpers-mysql.gemspec | 2 +- .../opentelemetry-helpers-sql-obfuscation.gemspec | 2 +- helpers/sql-obfuscation/test/helpers/sql_obfuscation_test.rb | 2 +- .../opentelemetry-instrumentation-action_mailer.gemspec | 2 +- .../opentelemetry-instrumentation-action_pack.gemspec | 2 +- .../opentelemetry-instrumentation-action_view.gemspec | 2 +- .../active_job/opentelemetry-instrumentation-active_job.gemspec | 2 +- ...entelemetry-instrumentation-active_model_serializers.gemspec | 2 +- .../opentelemetry-instrumentation-active_record.gemspec | 2 +- .../opentelemetry-instrumentation-active_support.gemspec | 2 +- instrumentation/all/opentelemetry-instrumentation-all.gemspec | 2 +- .../aws_lambda/opentelemetry-instrumentation-aws_lambda.gemspec | 2 +- .../aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec | 2 +- instrumentation/base/opentelemetry-instrumentation-base.gemspec | 2 +- .../bunny/opentelemetry-instrumentation-bunny.gemspec | 2 +- .../opentelemetry-instrumentation-concurrent_ruby.gemspec | 2 +- .../dalli/opentelemetry-instrumentation-dalli.gemspec | 2 +- .../opentelemetry-instrumentation-delayed_job.gemspec | 2 +- .../ethon/opentelemetry-instrumentation-ethon.gemspec | 2 +- .../excon/opentelemetry-instrumentation-excon.gemspec | 2 +- .../faraday/opentelemetry-instrumentation-faraday.gemspec | 2 +- .../grape/opentelemetry-instrumentation-grape.gemspec | 2 +- .../graphql/opentelemetry-instrumentation-graphql.gemspec | 2 +- instrumentation/gruf/opentelemetry-instrumentation-gruf.gemspec | 2 +- instrumentation/http/opentelemetry-instrumentation-http.gemspec | 2 +- .../opentelemetry-instrumentation-http_client.gemspec | 2 +- .../httpx/opentelemetry-instrumentation-httpx.gemspec | 2 +- .../koala/opentelemetry-instrumentation-koala.gemspec | 2 +- instrumentation/lmdb/opentelemetry-instrumentation-lmdb.gemspec | 2 +- .../mongo/opentelemetry-instrumentation-mongo.gemspec | 2 +- .../mysql2/opentelemetry-instrumentation-mysql2.gemspec | 2 +- .../net_http/opentelemetry-instrumentation-net_http.gemspec | 2 +- instrumentation/pg/opentelemetry-instrumentation-pg.gemspec | 2 +- instrumentation/que/opentelemetry-instrumentation-que.gemspec | 2 +- .../racecar/opentelemetry-instrumentation-racecar.gemspec | 2 +- instrumentation/rack/opentelemetry-instrumentation-rack.gemspec | 2 +- .../rails/opentelemetry-instrumentation-rails.gemspec | 2 +- instrumentation/rake/opentelemetry-instrumentation-rake.gemspec | 2 +- .../rdkafka/opentelemetry-instrumentation-rdkafka.gemspec | 2 +- .../redis/opentelemetry-instrumentation-redis.gemspec | 2 +- .../resque/opentelemetry-instrumentation-resque.gemspec | 2 +- .../restclient/opentelemetry-instrumentation-restclient.gemspec | 2 +- .../rspec/opentelemetry-instrumentation-rspec.gemspec | 2 +- .../ruby_kafka/opentelemetry-instrumentation-ruby_kafka.gemspec | 2 +- .../sidekiq/opentelemetry-instrumentation-sidekiq.gemspec | 2 +- .../sinatra/opentelemetry-instrumentation-sinatra.gemspec | 2 +- .../trilogy/opentelemetry-instrumentation-trilogy.gemspec | 2 +- processor/baggage/opentelemetry-processor-baggage.gemspec | 2 +- propagator/ottrace/opentelemetry-propagator-ottrace.gemspec | 2 +- propagator/vitess/opentelemetry-propagator-vitess.gemspec | 2 +- propagator/xray/opentelemetry-propagator-xray.gemspec | 2 +- resources/azure/opentelemetry-resource-detector-azure.gemspec | 2 +- .../container/opentelemetry-resource-detector-container.gemspec | 2 +- ...pentelemetry-resource-detector-google_cloud_platform.gemspec | 2 +- 56 files changed, 56 insertions(+), 56 deletions(-) diff --git a/.instrumentation_generator/templates/gemspec.tt b/.instrumentation_generator/templates/gemspec.tt index 2692e7eac..fb51740b9 100644 --- a/.instrumentation_generator/templates/gemspec.tt +++ b/.instrumentation_generator/templates/gemspec.tt @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.0' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.19.1' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.7.6' diff --git a/Gemfile b/Gemfile index 93039be61..be94fd2e5 100644 --- a/Gemfile +++ b/Gemfile @@ -7,5 +7,5 @@ source 'https://rubygems.org' gem 'rake', '~> 13.0' -gem 'rubocop', '~> 1.65.1' +gem 'rubocop', '~> 1.66.0' gem 'rubocop-performance', '~> 1.21.0' diff --git a/helpers/mysql/opentelemetry-helpers-mysql.gemspec b/helpers/mysql/opentelemetry-helpers-mysql.gemspec index 38b977ea0..5cebc24d6 100644 --- a/helpers/mysql/opentelemetry-helpers-mysql.gemspec +++ b/helpers/mysql/opentelemetry-helpers-mysql.gemspec @@ -32,7 +32,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.21.0' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/helpers/sql-obfuscation/opentelemetry-helpers-sql-obfuscation.gemspec b/helpers/sql-obfuscation/opentelemetry-helpers-sql-obfuscation.gemspec index 65fc0902c..1ce168184 100644 --- a/helpers/sql-obfuscation/opentelemetry-helpers-sql-obfuscation.gemspec +++ b/helpers/sql-obfuscation/opentelemetry-helpers-sql-obfuscation.gemspec @@ -31,7 +31,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.21.0' spec.add_development_dependency 'yard', '~> 0.9' spec.add_development_dependency 'yard-doctest', '~> 0.1.6' diff --git a/helpers/sql-obfuscation/test/helpers/sql_obfuscation_test.rb b/helpers/sql-obfuscation/test/helpers/sql_obfuscation_test.rb index e340cbdb5..4d8aeec4a 100644 --- a/helpers/sql-obfuscation/test/helpers/sql_obfuscation_test.rb +++ b/helpers/sql-obfuscation/test/helpers/sql_obfuscation_test.rb @@ -65,7 +65,7 @@ def test_statement_with_emoji_encodes_utf_8_and_obfuscates FAILED_TO_OBFUSCATE_MESSAGE = 'Failed to obfuscate SQL query - quote characters remained after obfuscation' def build_failure_message(statement, dialect, acceptable_outputs, actual_output) - msg = +"Failed to obfuscate #{dialect} query correctly.\n" + msg = "Failed to obfuscate #{dialect} query correctly.\n" msg << "Input: #{statement}\n" if acceptable_outputs.size == 1 msg << "Expected: #{acceptable_outputs.first}\n" diff --git a/instrumentation/action_mailer/opentelemetry-instrumentation-action_mailer.gemspec b/instrumentation/action_mailer/opentelemetry-instrumentation-action_mailer.gemspec index 4d0b58dfe..2a00a1534 100644 --- a/instrumentation/action_mailer/opentelemetry-instrumentation-action_mailer.gemspec +++ b/instrumentation/action_mailer/opentelemetry-instrumentation-action_mailer.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/action_pack/opentelemetry-instrumentation-action_pack.gemspec b/instrumentation/action_pack/opentelemetry-instrumentation-action_pack.gemspec index 2340f6cf3..27745ffac 100644 --- a/instrumentation/action_pack/opentelemetry-instrumentation-action_pack.gemspec +++ b/instrumentation/action_pack/opentelemetry-instrumentation-action_pack.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rails', '>= 6.1' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/action_view/opentelemetry-instrumentation-action_view.gemspec b/instrumentation/action_view/opentelemetry-instrumentation-action_view.gemspec index 825106243..79685ab32 100644 --- a/instrumentation/action_view/opentelemetry-instrumentation-action_view.gemspec +++ b/instrumentation/action_view/opentelemetry-instrumentation-action_view.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rails', '>= 6.1' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/active_job/opentelemetry-instrumentation-active_job.gemspec b/instrumentation/active_job/opentelemetry-instrumentation-active_job.gemspec index 66ad5abf9..974244bd7 100644 --- a/instrumentation/active_job/opentelemetry-instrumentation-active_job.gemspec +++ b/instrumentation/active_job/opentelemetry-instrumentation-active_job.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/active_model_serializers/opentelemetry-instrumentation-active_model_serializers.gemspec b/instrumentation/active_model_serializers/opentelemetry-instrumentation-active_model_serializers.gemspec index dd76de1fa..315ab5e41 100644 --- a/instrumentation/active_model_serializers/opentelemetry-instrumentation-active_model_serializers.gemspec +++ b/instrumentation/active_model_serializers/opentelemetry-instrumentation-active_model_serializers.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/active_record/opentelemetry-instrumentation-active_record.gemspec b/instrumentation/active_record/opentelemetry-instrumentation-active_record.gemspec index 7c383d4c3..29eeab35d 100644 --- a/instrumentation/active_record/opentelemetry-instrumentation-active_record.gemspec +++ b/instrumentation/active_record/opentelemetry-instrumentation-active_record.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/active_support/opentelemetry-instrumentation-active_support.gemspec b/instrumentation/active_support/opentelemetry-instrumentation-active_support.gemspec index c19dcb32f..e692985f1 100644 --- a/instrumentation/active_support/opentelemetry-instrumentation-active_support.gemspec +++ b/instrumentation/active_support/opentelemetry-instrumentation-active_support.gemspec @@ -39,7 +39,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rails', '>= 6.1' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/all/opentelemetry-instrumentation-all.gemspec b/instrumentation/all/opentelemetry-instrumentation-all.gemspec index 14e4870f6..7af795545 100644 --- a/instrumentation/all/opentelemetry-instrumentation-all.gemspec +++ b/instrumentation/all/opentelemetry-instrumentation-all.gemspec @@ -66,7 +66,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'bundler', '~> 2.4' spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/aws_lambda/opentelemetry-instrumentation-aws_lambda.gemspec b/instrumentation/aws_lambda/opentelemetry-instrumentation-aws_lambda.gemspec index b9c927c34..79937f592 100644 --- a/instrumentation/aws_lambda/opentelemetry-instrumentation-aws_lambda.gemspec +++ b/instrumentation/aws_lambda/opentelemetry-instrumentation-aws_lambda.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'pry' spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.19.1' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec b/instrumentation/aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec index 01415e31c..0c84297d7 100644 --- a/instrumentation/aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec +++ b/instrumentation/aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'pry' spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/base/opentelemetry-instrumentation-base.gemspec b/instrumentation/base/opentelemetry-instrumentation-base.gemspec index 081b8414a..97da5f64f 100644 --- a/instrumentation/base/opentelemetry-instrumentation-base.gemspec +++ b/instrumentation/base/opentelemetry-instrumentation-base.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/bunny/opentelemetry-instrumentation-bunny.gemspec b/instrumentation/bunny/opentelemetry-instrumentation-bunny.gemspec index 6651e5e47..9f94081f0 100644 --- a/instrumentation/bunny/opentelemetry-instrumentation-bunny.gemspec +++ b/instrumentation/bunny/opentelemetry-instrumentation-bunny.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/concurrent_ruby/opentelemetry-instrumentation-concurrent_ruby.gemspec b/instrumentation/concurrent_ruby/opentelemetry-instrumentation-concurrent_ruby.gemspec index 5a6abf5fa..539887b96 100644 --- a/instrumentation/concurrent_ruby/opentelemetry-instrumentation-concurrent_ruby.gemspec +++ b/instrumentation/concurrent_ruby/opentelemetry-instrumentation-concurrent_ruby.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/dalli/opentelemetry-instrumentation-dalli.gemspec b/instrumentation/dalli/opentelemetry-instrumentation-dalli.gemspec index cef6417d6..08405e804 100644 --- a/instrumentation/dalli/opentelemetry-instrumentation-dalli.gemspec +++ b/instrumentation/dalli/opentelemetry-instrumentation-dalli.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/delayed_job/opentelemetry-instrumentation-delayed_job.gemspec b/instrumentation/delayed_job/opentelemetry-instrumentation-delayed_job.gemspec index 5a9f7c724..8007aec82 100644 --- a/instrumentation/delayed_job/opentelemetry-instrumentation-delayed_job.gemspec +++ b/instrumentation/delayed_job/opentelemetry-instrumentation-delayed_job.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'sqlite3' diff --git a/instrumentation/ethon/opentelemetry-instrumentation-ethon.gemspec b/instrumentation/ethon/opentelemetry-instrumentation-ethon.gemspec index d1e5a80bb..b5b90f5d4 100644 --- a/instrumentation/ethon/opentelemetry-instrumentation-ethon.gemspec +++ b/instrumentation/ethon/opentelemetry-instrumentation-ethon.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/excon/opentelemetry-instrumentation-excon.gemspec b/instrumentation/excon/opentelemetry-instrumentation-excon.gemspec index 8c6e67759..18c3f82ba 100644 --- a/instrumentation/excon/opentelemetry-instrumentation-excon.gemspec +++ b/instrumentation/excon/opentelemetry-instrumentation-excon.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/faraday/opentelemetry-instrumentation-faraday.gemspec b/instrumentation/faraday/opentelemetry-instrumentation-faraday.gemspec index 660fdfc6d..f08ff6576 100644 --- a/instrumentation/faraday/opentelemetry-instrumentation-faraday.gemspec +++ b/instrumentation/faraday/opentelemetry-instrumentation-faraday.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/grape/opentelemetry-instrumentation-grape.gemspec b/instrumentation/grape/opentelemetry-instrumentation-grape.gemspec index b3946273d..86306cddb 100644 --- a/instrumentation/grape/opentelemetry-instrumentation-grape.gemspec +++ b/instrumentation/grape/opentelemetry-instrumentation-grape.gemspec @@ -38,7 +38,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rack-test' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/graphql/opentelemetry-instrumentation-graphql.gemspec b/instrumentation/graphql/opentelemetry-instrumentation-graphql.gemspec index 42a068d25..36aec82c3 100644 --- a/instrumentation/graphql/opentelemetry-instrumentation-graphql.gemspec +++ b/instrumentation/graphql/opentelemetry-instrumentation-graphql.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/gruf/opentelemetry-instrumentation-gruf.gemspec b/instrumentation/gruf/opentelemetry-instrumentation-gruf.gemspec index d6a8d22d1..bff04dd3e 100644 --- a/instrumentation/gruf/opentelemetry-instrumentation-gruf.gemspec +++ b/instrumentation/gruf/opentelemetry-instrumentation-gruf.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.0' spec.add_development_dependency 'opentelemetry-test-helpers' spec.add_development_dependency 'rake', '~> 12.3.3' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/http/opentelemetry-instrumentation-http.gemspec b/instrumentation/http/opentelemetry-instrumentation-http.gemspec index f7ceae25c..54069ff29 100644 --- a/instrumentation/http/opentelemetry-instrumentation-http.gemspec +++ b/instrumentation/http/opentelemetry-instrumentation-http.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/http_client/opentelemetry-instrumentation-http_client.gemspec b/instrumentation/http_client/opentelemetry-instrumentation-http_client.gemspec index 022070cde..98a0a1170 100644 --- a/instrumentation/http_client/opentelemetry-instrumentation-http_client.gemspec +++ b/instrumentation/http_client/opentelemetry-instrumentation-http_client.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/httpx/opentelemetry-instrumentation-httpx.gemspec b/instrumentation/httpx/opentelemetry-instrumentation-httpx.gemspec index 5e1f1c04a..b2f48305a 100644 --- a/instrumentation/httpx/opentelemetry-instrumentation-httpx.gemspec +++ b/instrumentation/httpx/opentelemetry-instrumentation-httpx.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/koala/opentelemetry-instrumentation-koala.gemspec b/instrumentation/koala/opentelemetry-instrumentation-koala.gemspec index 3659cdd5a..75d1d574e 100644 --- a/instrumentation/koala/opentelemetry-instrumentation-koala.gemspec +++ b/instrumentation/koala/opentelemetry-instrumentation-koala.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/lmdb/opentelemetry-instrumentation-lmdb.gemspec b/instrumentation/lmdb/opentelemetry-instrumentation-lmdb.gemspec index 9b584530e..7a59efcaa 100644 --- a/instrumentation/lmdb/opentelemetry-instrumentation-lmdb.gemspec +++ b/instrumentation/lmdb/opentelemetry-instrumentation-lmdb.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/mongo/opentelemetry-instrumentation-mongo.gemspec b/instrumentation/mongo/opentelemetry-instrumentation-mongo.gemspec index 08f463bb1..f981355e7 100644 --- a/instrumentation/mongo/opentelemetry-instrumentation-mongo.gemspec +++ b/instrumentation/mongo/opentelemetry-instrumentation-mongo.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'pry' spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/mysql2/opentelemetry-instrumentation-mysql2.gemspec b/instrumentation/mysql2/opentelemetry-instrumentation-mysql2.gemspec index 148514d3c..8a3124f0f 100644 --- a/instrumentation/mysql2/opentelemetry-instrumentation-mysql2.gemspec +++ b/instrumentation/mysql2/opentelemetry-instrumentation-mysql2.gemspec @@ -37,7 +37,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'pry' spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/net_http/opentelemetry-instrumentation-net_http.gemspec b/instrumentation/net_http/opentelemetry-instrumentation-net_http.gemspec index 0e4ebfaca..c0d4f4857 100644 --- a/instrumentation/net_http/opentelemetry-instrumentation-net_http.gemspec +++ b/instrumentation/net_http/opentelemetry-instrumentation-net_http.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0.1' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/pg/opentelemetry-instrumentation-pg.gemspec b/instrumentation/pg/opentelemetry-instrumentation-pg.gemspec index 36fbec863..29feea416 100644 --- a/instrumentation/pg/opentelemetry-instrumentation-pg.gemspec +++ b/instrumentation/pg/opentelemetry-instrumentation-pg.gemspec @@ -37,7 +37,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'pry' spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/que/opentelemetry-instrumentation-que.gemspec b/instrumentation/que/opentelemetry-instrumentation-que.gemspec index 3b0a0d39d..5fa8dfcfb 100644 --- a/instrumentation/que/opentelemetry-instrumentation-que.gemspec +++ b/instrumentation/que/opentelemetry-instrumentation-que.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/racecar/opentelemetry-instrumentation-racecar.gemspec b/instrumentation/racecar/opentelemetry-instrumentation-racecar.gemspec index b79e60360..ce4aceae2 100644 --- a/instrumentation/racecar/opentelemetry-instrumentation-racecar.gemspec +++ b/instrumentation/racecar/opentelemetry-instrumentation-racecar.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/rack/opentelemetry-instrumentation-rack.gemspec b/instrumentation/rack/opentelemetry-instrumentation-rack.gemspec index 58484904d..7ecebeb6b 100644 --- a/instrumentation/rack/opentelemetry-instrumentation-rack.gemspec +++ b/instrumentation/rack/opentelemetry-instrumentation-rack.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec b/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec index ed3428b1b..e8db79ecf 100644 --- a/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec +++ b/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec @@ -41,7 +41,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rack-test', '~> 2.1.0' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/rake/opentelemetry-instrumentation-rake.gemspec b/instrumentation/rake/opentelemetry-instrumentation-rake.gemspec index 14a44994d..f6f8b709b 100644 --- a/instrumentation/rake/opentelemetry-instrumentation-rake.gemspec +++ b/instrumentation/rake/opentelemetry-instrumentation-rake.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.0' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/rdkafka/opentelemetry-instrumentation-rdkafka.gemspec b/instrumentation/rdkafka/opentelemetry-instrumentation-rdkafka.gemspec index 59499e72d..e7b14e48a 100644 --- a/instrumentation/rdkafka/opentelemetry-instrumentation-rdkafka.gemspec +++ b/instrumentation/rdkafka/opentelemetry-instrumentation-rdkafka.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/redis/opentelemetry-instrumentation-redis.gemspec b/instrumentation/redis/opentelemetry-instrumentation-redis.gemspec index 56c1a3a72..183a9d8e0 100644 --- a/instrumentation/redis/opentelemetry-instrumentation-redis.gemspec +++ b/instrumentation/redis/opentelemetry-instrumentation-redis.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/resque/opentelemetry-instrumentation-resque.gemspec b/instrumentation/resque/opentelemetry-instrumentation-resque.gemspec index 5726ac107..1c6e8e5ab 100644 --- a/instrumentation/resque/opentelemetry-instrumentation-resque.gemspec +++ b/instrumentation/resque/opentelemetry-instrumentation-resque.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/restclient/opentelemetry-instrumentation-restclient.gemspec b/instrumentation/restclient/opentelemetry-instrumentation-restclient.gemspec index 6ae709b1f..2b4823aac 100644 --- a/instrumentation/restclient/opentelemetry-instrumentation-restclient.gemspec +++ b/instrumentation/restclient/opentelemetry-instrumentation-restclient.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/rspec/opentelemetry-instrumentation-rspec.gemspec b/instrumentation/rspec/opentelemetry-instrumentation-rspec.gemspec index 5bf297ee1..6c4760d0c 100644 --- a/instrumentation/rspec/opentelemetry-instrumentation-rspec.gemspec +++ b/instrumentation/rspec/opentelemetry-instrumentation-rspec.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/ruby_kafka/opentelemetry-instrumentation-ruby_kafka.gemspec b/instrumentation/ruby_kafka/opentelemetry-instrumentation-ruby_kafka.gemspec index cbb1225f5..a6572baa6 100644 --- a/instrumentation/ruby_kafka/opentelemetry-instrumentation-ruby_kafka.gemspec +++ b/instrumentation/ruby_kafka/opentelemetry-instrumentation-ruby_kafka.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/sidekiq/opentelemetry-instrumentation-sidekiq.gemspec b/instrumentation/sidekiq/opentelemetry-instrumentation-sidekiq.gemspec index acce77d2e..dc1939455 100644 --- a/instrumentation/sidekiq/opentelemetry-instrumentation-sidekiq.gemspec +++ b/instrumentation/sidekiq/opentelemetry-instrumentation-sidekiq.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/sinatra/opentelemetry-instrumentation-sinatra.gemspec b/instrumentation/sinatra/opentelemetry-instrumentation-sinatra.gemspec index aba1324d3..4a1543785 100644 --- a/instrumentation/sinatra/opentelemetry-instrumentation-sinatra.gemspec +++ b/instrumentation/sinatra/opentelemetry-instrumentation-sinatra.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rack-test', '~> 2.1' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/trilogy/opentelemetry-instrumentation-trilogy.gemspec b/instrumentation/trilogy/opentelemetry-instrumentation-trilogy.gemspec index 0d380eac0..788ab8469 100644 --- a/instrumentation/trilogy/opentelemetry-instrumentation-trilogy.gemspec +++ b/instrumentation/trilogy/opentelemetry-instrumentation-trilogy.gemspec @@ -41,7 +41,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/processor/baggage/opentelemetry-processor-baggage.gemspec b/processor/baggage/opentelemetry-processor-baggage.gemspec index dc34fd861..18ef334bb 100644 --- a/processor/baggage/opentelemetry-processor-baggage.gemspec +++ b/processor/baggage/opentelemetry-processor-baggage.gemspec @@ -30,7 +30,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/propagator/ottrace/opentelemetry-propagator-ottrace.gemspec b/propagator/ottrace/opentelemetry-propagator-ottrace.gemspec index 2ae6921c1..d00f57231 100644 --- a/propagator/ottrace/opentelemetry-propagator-ottrace.gemspec +++ b/propagator/ottrace/opentelemetry-propagator-ottrace.gemspec @@ -28,7 +28,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'bundler', '~> 2.4' spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/propagator/vitess/opentelemetry-propagator-vitess.gemspec b/propagator/vitess/opentelemetry-propagator-vitess.gemspec index 3b22600a8..74d87c68f 100644 --- a/propagator/vitess/opentelemetry-propagator-vitess.gemspec +++ b/propagator/vitess/opentelemetry-propagator-vitess.gemspec @@ -29,7 +29,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'bundler', '~> 2.4' spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/propagator/xray/opentelemetry-propagator-xray.gemspec b/propagator/xray/opentelemetry-propagator-xray.gemspec index 2f5cf5009..c4c056fc8 100644 --- a/propagator/xray/opentelemetry-propagator-xray.gemspec +++ b/propagator/xray/opentelemetry-propagator-xray.gemspec @@ -31,7 +31,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'bundler', '~> 2.4' spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/resources/azure/opentelemetry-resource-detector-azure.gemspec b/resources/azure/opentelemetry-resource-detector-azure.gemspec index 2a5da4255..8c92fea3c 100644 --- a/resources/azure/opentelemetry-resource-detector-azure.gemspec +++ b/resources/azure/opentelemetry-resource-detector-azure.gemspec @@ -30,7 +30,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'bundler', '~> 2.4' spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17' spec.add_development_dependency 'webmock', '~> 3.23.0' diff --git a/resources/container/opentelemetry-resource-detector-container.gemspec b/resources/container/opentelemetry-resource-detector-container.gemspec index a5724c958..caf0fc56c 100644 --- a/resources/container/opentelemetry-resource-detector-container.gemspec +++ b/resources/container/opentelemetry-resource-detector-container.gemspec @@ -30,7 +30,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'bundler', '~> 2.4' spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/resources/google_cloud_platform/opentelemetry-resource-detector-google_cloud_platform.gemspec b/resources/google_cloud_platform/opentelemetry-resource-detector-google_cloud_platform.gemspec index 5ec3b7e83..1603b54fe 100644 --- a/resources/google_cloud_platform/opentelemetry-resource-detector-google_cloud_platform.gemspec +++ b/resources/google_cloud_platform/opentelemetry-resource-detector-google_cloud_platform.gemspec @@ -31,7 +31,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'bundler', '~> 2.4' spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.65.0' + spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.20' spec.add_development_dependency 'simplecov', '~> 0.17' spec.add_development_dependency 'webmock', '~> 3.23.0' From 8e778ba768f8fb43779efadaa4223e300aff34ab Mon Sep 17 00:00:00 2001 From: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com> Date: Tue, 10 Sep 2024 13:25:47 -0700 Subject: [PATCH 17/58] fix!: Return message when sql is over the obfuscation limit (#1149) Previously, when a SQL query with a prepended comment exceeded the obfuscation limit, the query would be truncated without obfuscation. Now, when the when the obfuscation limit is hit, a message is returned and obfuscation is not attempted. --- helpers/sql-obfuscation/README.md | 2 +- .../lib/opentelemetry/helpers/sql_obfuscation.rb | 15 +++------------ .../test/helpers/sql_obfuscation_test.rb | 12 ++---------- .../mysql2/instrumentation_test.rb | 15 ++------------- .../instrumentation/pg/instrumentation_test.rb | 15 ++------------- .../trilogy/instrumentation_test.rb | 15 ++------------- 6 files changed, 12 insertions(+), 62 deletions(-) diff --git a/helpers/sql-obfuscation/README.md b/helpers/sql-obfuscation/README.md index 1e86bacdf..6055f8fe8 100644 --- a/helpers/sql-obfuscation/README.md +++ b/helpers/sql-obfuscation/README.md @@ -25,7 +25,7 @@ end Make sure the `Instrumentation` class for your gem contains configuration options for: -- `:obfuscation_limit`: the length at which the obfuscated SQL string will be truncated. +- `:obfuscation_limit`: the length at which the SQL string will not be obfuscated Example: `option :obfuscation_limit, default: 2000, validate: :integer` If you want to add support for a new adapter, update the following constants to include keys for your adapter: diff --git a/helpers/sql-obfuscation/lib/opentelemetry/helpers/sql_obfuscation.rb b/helpers/sql-obfuscation/lib/opentelemetry/helpers/sql_obfuscation.rb index da0394b42..debb2b7e5 100644 --- a/helpers/sql-obfuscation/lib/opentelemetry/helpers/sql_obfuscation.rb +++ b/helpers/sql-obfuscation/lib/opentelemetry/helpers/sql_obfuscation.rb @@ -94,7 +94,7 @@ def generate_regex(dialect) # This is a SQL obfuscation utility intended for use in database adapter instrumentation. # # @param sql [String] The SQL to obfuscate. - # @param obfuscation_limit [optional Integer] The maximum length of an obfuscated sql statement. + # @param obfuscation_limit [optional Integer] the length at which the SQL string will not be obfuscated # @param adapter [optional Symbol] the type of database adapter calling the method. `:default`, `:mysql` and `:postgres` are supported. # @return [String] The SQL query string where the values are replaced with "?". When the sql statement exceeds the obufscation limit # the first matched pair from the SQL statement will be returned, with an appended truncation message. If trunaction is unsuccessful, @@ -102,6 +102,8 @@ def generate_regex(dialect) # # @api public def obfuscate_sql(sql, obfuscation_limit: 2000, adapter: :default) + return "SQL not obfuscated, query exceeds #{obfuscation_limit} characters" if sql.size > obfuscation_limit + regex = case adapter when :mysql MYSQL_COMPONENTS_REGEX @@ -115,7 +117,6 @@ def obfuscate_sql(sql, obfuscation_limit: 2000, adapter: :default) # https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/160 # https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/345 sql = OpenTelemetry::Common::Utilities.utf8_encode(sql, binary: true) - return truncate_statement(sql, regex, obfuscation_limit) if sql.size > obfuscation_limit sql = sql.gsub(regex, PLACEHOLDER) return 'Failed to obfuscate SQL query - quote characters remained after obfuscation' if CLEANUP_REGEX[adapter].match(sql) @@ -124,16 +125,6 @@ def obfuscate_sql(sql, obfuscation_limit: 2000, adapter: :default) rescue StandardError => e OpenTelemetry.handle_error(message: 'Failed to obfuscate SQL', exception: e) end - - # @api private - def truncate_statement(sql, regex, limit) - first_match_index = sql.index(regex) - truncation_message = "SQL truncated (> #{limit} characters)" - return truncation_message unless first_match_index - - truncated_sql = sql[..first_match_index - 1] - "#{truncated_sql}...\n#{truncation_message}" - end end end end diff --git a/helpers/sql-obfuscation/test/helpers/sql_obfuscation_test.rb b/helpers/sql-obfuscation/test/helpers/sql_obfuscation_test.rb index 4d8aeec4a..39229d47f 100644 --- a/helpers/sql-obfuscation/test/helpers/sql_obfuscation_test.rb +++ b/helpers/sql-obfuscation/test/helpers/sql_obfuscation_test.rb @@ -18,17 +18,9 @@ def test_named_arg_defaults_obfuscates assert_equal(expected, result) end - def test_obfuscation_limit_truncates_query_after_first_match + def test_obfuscation_returns_message_when_limit_is_reached sql = "SELECT * from users where users.id = 1 and users.email = 'test@test.com'" - expected = "SELECT * from users where users.id = ...\nSQL truncated (> 42 characters)" - result = OpenTelemetry::Helpers::SqlObfuscation.obfuscate_sql(sql, obfuscation_limit: 42) - - assert_equal(expected, result) - end - - def test_obfuscation_limit_truncates_when_query_not_encoded_with_utf8 - sql = "SELECT * from 😄 where users.id = 1 and users.😄 = 'test@test.com'" - expected = "SELECT * from where users.id = ...\nSQL truncated (> 42 characters)" + expected = 'SQL not obfuscated, query exceeds 42 characters' result = OpenTelemetry::Helpers::SqlObfuscation.obfuscate_sql(sql, obfuscation_limit: 42) assert_equal(expected, result) diff --git a/instrumentation/mysql2/test/opentelemetry/instrumentation/mysql2/instrumentation_test.rb b/instrumentation/mysql2/test/opentelemetry/instrumentation/mysql2/instrumentation_test.rb index 319e138d8..405b714ee 100644 --- a/instrumentation/mysql2/test/opentelemetry/instrumentation/mysql2/instrumentation_test.rb +++ b/instrumentation/mysql2/test/opentelemetry/instrumentation/mysql2/instrumentation_test.rb @@ -236,20 +236,9 @@ describe 'with obfuscation_limit' do let(:config) { { db_statement: :obfuscate, obfuscation_limit: 10 } } - it 'truncates SQL using config limit' do + it 'returns a message when the limit is reached' do sql = "SELECT * from users where users.id = 1 and users.email = 'test@test.com'" - obfuscated_sql = "SELECT * from users where users.id = ...\nSQL truncated (> 10 characters)" - expect do - client.query(sql) - end.must_raise Mysql2::Error - - _(span.attributes['db.statement']).must_equal obfuscated_sql - end - - it 'handles regex non-matches' do - sql = 'ALTER TABLE my_table DISABLE TRIGGER ALL;' - obfuscated_sql = 'SQL truncated (> 10 characters)' - + obfuscated_sql = 'SQL not obfuscated, query exceeds 10 characters' expect do client.query(sql) end.must_raise Mysql2::Error diff --git a/instrumentation/pg/test/opentelemetry/instrumentation/pg/instrumentation_test.rb b/instrumentation/pg/test/opentelemetry/instrumentation/pg/instrumentation_test.rb index 95f470014..cc50728e5 100644 --- a/instrumentation/pg/test/opentelemetry/instrumentation/pg/instrumentation_test.rb +++ b/instrumentation/pg/test/opentelemetry/instrumentation/pg/instrumentation_test.rb @@ -297,20 +297,9 @@ describe 'with obfuscation_limit' do let(:config) { { db_statement: :obfuscate, obfuscation_limit: 10 } } - it 'truncates SQL using config limit' do + it 'returns a message when the limit is reached' do sql = "SELECT * from users where users.id = 1 and users.email = 'test@test.com'" - obfuscated_sql = "SELECT * from users where users.id = ...\nSQL truncated (> 10 characters)" - expect do - client.exec(sql) - end.must_raise PG::UndefinedTable - - _(span.attributes['db.statement']).must_equal obfuscated_sql - end - - it 'handles regex non-matches' do - sql = 'ALTER TABLE my_table DISABLE TRIGGER ALL;' - obfuscated_sql = 'SQL truncated (> 10 characters)' - + obfuscated_sql = 'SQL not obfuscated, query exceeds 10 characters' expect do client.exec(sql) end.must_raise PG::UndefinedTable diff --git a/instrumentation/trilogy/test/opentelemetry/instrumentation/trilogy/instrumentation_test.rb b/instrumentation/trilogy/test/opentelemetry/instrumentation/trilogy/instrumentation_test.rb index 9b1b7b845..350ee5f83 100644 --- a/instrumentation/trilogy/test/opentelemetry/instrumentation/trilogy/instrumentation_test.rb +++ b/instrumentation/trilogy/test/opentelemetry/instrumentation/trilogy/instrumentation_test.rb @@ -323,20 +323,9 @@ describe 'with obfuscation_limit' do let(:config) { { db_statement: :obfuscate, obfuscation_limit: 10 } } - it 'truncates SQL using config limit' do + it 'returns a message when the limit is reached' do sql = "SELECT * from users where users.id = 1 and users.email = 'test@test.com'" - obfuscated_sql = "SELECT * from users where users.id = ...\nSQL truncated (> 10 characters)" - expect do - client.query(sql) - end.must_raise Trilogy::Error - - _(span.attributes['db.statement']).must_equal obfuscated_sql - end - - it 'handles regex non-matches' do - sql = 'ALTER TABLE my_table DISABLE TRIGGER ALL;' - obfuscated_sql = 'SQL truncated (> 10 characters)' - + obfuscated_sql = 'SQL not obfuscated, query exceeds 10 characters' expect do client.query(sql) end.must_raise Trilogy::Error From 1f6659c35a4aa0b67541d6d46a003988b502b28f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 12 Sep 2024 12:52:38 -0700 Subject: [PATCH 18/58] chore: bump DavidAnson/markdownlint-cli2-action from 16 to 17 (#1163) Bumps [DavidAnson/markdownlint-cli2-action](https://github.com/davidanson/markdownlint-cli2-action) from 16 to 17. - [Release notes](https://github.com/davidanson/markdownlint-cli2-action/releases) - [Commits](https://github.com/davidanson/markdownlint-cli2-action/compare/v16...v17) --- updated-dependencies: - dependency-name: DavidAnson/markdownlint-cli2-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- .github/workflows/ci-markdownlint.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-markdownlint.yml b/.github/workflows/ci-markdownlint.yml index f91609fdb..646484a9b 100644 --- a/.github/workflows/ci-markdownlint.yml +++ b/.github/workflows/ci-markdownlint.yml @@ -11,7 +11,7 @@ jobs: # equivalent cli: markdownlint-cli2 "**/*.md" "#**/CHANGELOG.md" --config .markdownlint.json - name: "Markdown Lint Check" - uses: DavidAnson/markdownlint-cli2-action@v16 + uses: DavidAnson/markdownlint-cli2-action@v17 with: fix: false globs: | From a174d03213057f0a86ecf23251f2c9e072c0ec6e Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Thu, 12 Sep 2024 15:43:07 -0700 Subject: [PATCH 19/58] release: Release 5 gems (#1162) * release: Release 4 gems * opentelemetry-helpers-sql-obfuscation 0.2.0 (was 0.1.1) * opentelemetry-instrumentation-trilogy 0.60.0 (was 0.59.3) * opentelemetry-instrumentation-mysql2 0.28.0 (was 0.27.2) * opentelemetry-instrumentation-pg 0.29.0 (was 0.28.0) * chore: Update changelogs, bump instrumentation-all * chore: Fix spelling --------- Co-authored-by: OpenTelemetry Bot <107717825+opentelemetrybot@users.noreply.github.com> Co-authored-by: Kayla Reopelle Co-authored-by: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com> --- helpers/sql-obfuscation/CHANGELOG.md | 8 +- .../helpers/sql_obfuscation/version.rb | 2 +- instrumentation/all/CHANGELOG.md | 195 +++++++++--------- .../instrumentation/all/version.rb | 2 +- .../opentelemetry-instrumentation-all.gemspec | 6 +- instrumentation/mysql2/CHANGELOG.md | 105 +++++----- .../instrumentation/mysql2/version.rb | 2 +- instrumentation/pg/CHANGELOG.md | 83 ++++---- .../instrumentation/pg/version.rb | 2 +- instrumentation/trilogy/CHANGELOG.md | 64 +++--- .../instrumentation/trilogy/version.rb | 2 +- 11 files changed, 243 insertions(+), 228 deletions(-) diff --git a/helpers/sql-obfuscation/CHANGELOG.md b/helpers/sql-obfuscation/CHANGELOG.md index 7a62283ca..610ebb127 100644 --- a/helpers/sql-obfuscation/CHANGELOG.md +++ b/helpers/sql-obfuscation/CHANGELOG.md @@ -1,8 +1,12 @@ -# Release History: opentelemetry-helpers-sql-obfuscation +# Release History: opentelemetry-helpers-sql-obfuscation + +### v0.2.0 / 2024-09-12 + +- BREAKING CHANGE: Return message when sql is over the obfuscation limit. Fixes a bug where sql statements with prepended comments that hit the obfuscation limit would be sent raw. ### v0.1.1 / 2024-06-18 -* FIXED: Relax otel common gem constraints +- FIXED: Relax otel common gem constraints ### v0.1.0 / 2024-02-08 diff --git a/helpers/sql-obfuscation/lib/opentelemetry/helpers/sql_obfuscation/version.rb b/helpers/sql-obfuscation/lib/opentelemetry/helpers/sql_obfuscation/version.rb index 4d0787456..98cd6adc7 100644 --- a/helpers/sql-obfuscation/lib/opentelemetry/helpers/sql_obfuscation/version.rb +++ b/helpers/sql-obfuscation/lib/opentelemetry/helpers/sql_obfuscation/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Helpers module SqlObfuscation - VERSION = '0.1.1' + VERSION = '0.2.0' end end end diff --git a/instrumentation/all/CHANGELOG.md b/instrumentation/all/CHANGELOG.md index cf2807c72..7d3116d2a 100644 --- a/instrumentation/all/CHANGELOG.md +++ b/instrumentation/all/CHANGELOG.md @@ -1,285 +1,286 @@ # Release History: opentelemetry-instrumentation-all +### v0.64.0 / 2024-09-12 + +- BREAKING CHANGE: Return message when sql is over the obfuscation limit. Fixes a bug where sql statements with prepended comments that hit the obfuscation limit would be sent raw. + ### v0.63.0 / 2024-08-15 -* ADDED: Collect pg db.collection_name attribute +- ADDED: Collect pg db.collection_name attribute ### v0.62.1 / 2024-07-23 -* DOCS: Add cspell to CI +- DOCS: Add cspell to CI ### v0.62.0 / 2024-07-02 -* DOCS: Fix CHANGELOGs to reflect a past breaking change -* CHANGED: Update Rails Instrumentation -* CHANGED: Update Grape Instrumentation -* CHANGED: Update Sinatra Instrumentation +- DOCS: Fix CHANGELOGs to reflect a past breaking change +- CHANGED: Update Rails Instrumentation +- CHANGED: Update Grape Instrumentation +- CHANGED: Update Sinatra Instrumentation ### v0.61.0 / 2024-06-04 -* ADDED: Add aws lambda to instrumentation-all -* FIXED: Add action_mailer to rails and all +- ADDED: Add aws lambda to instrumentation-all +- FIXED: Add action_mailer to rails and all ### v0.60.0 / 2024-02-20 -* ADDED: Add support gruf 2.19 -* ADDED: Faraday add support for internal spans +- ADDED: Add support gruf 2.19 +- ADDED: Faraday add support for internal spans ### v0.59.0 / 2024-02-16 -* BREAKING CHANGE: GraphQL Legacy Tracer perf improvements [#867](https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/867). +- BREAKING CHANGE: GraphQL Legacy Tracer perf improvements [#867](https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/867). ### v0.58.0 / 2024-02-15 -* CHANGED: upgrade mysql2 instrumentation +- CHANGED: upgrade mysql2 instrumentation ### v0.57.0 / 2024-02-08 -* BREAKING CHANGE: Move shared sql behavior to helper gems - +- BREAKING CHANGE: Move shared sql behavior to helper gems ### v0.56.0 / 2024-01-09 -* BREAKING CHANGE: Use ActiveSupport instead of patches #703 +- BREAKING CHANGE: Use ActiveSupport instead of patches #703 ### v0.55.0 / 2024-01-06 -* CHANGED: Upgrade Trilogy and Rack [#796](https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/796) +- CHANGED: Upgrade Trilogy and Rack [#796](https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/796) ### v0.54.0 / 2023-11-28 -* ADDED: Updated excon to include connect spans +- ADDED: Updated excon to include connect spans ### v0.53.0 / 2023-11-28 -* CHANGED: Performance optimization cache attribute hashes [#723](https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/723) +- CHANGED: Performance optimization cache attribute hashes [#723](https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/723) ### v0.52.0 / 2023-11-21 -* BREAKING CHANGE: Drop Support for EoL Rails 6.0 [#680](https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/680) -* BREAKING CHANGE: Use ActiveSupport Instrumentation instead of Money Patches [#677](https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/677) +- BREAKING CHANGE: Drop Support for EoL Rails 6.0 [#680](https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/680) +- BREAKING CHANGE: Use ActiveSupport Instrumentation instead of Money Patches [#677](https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/677) -* CHANGED: Drop Support for EoL Rails 6.0 [#680](https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/680) -* CHANGED: Use ActiveSupport Instrumentation instead of Money Patches [#677](https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/677) +- CHANGED: Drop Support for EoL Rails 6.0 [#680](https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/680) +- CHANGED: Use ActiveSupport Instrumentation instead of Money Patches [#677](https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/677) ### v0.51.1 / 2023-10-27 -* ADDED: Instrument connect and ping (Trilogy) +- ADDED: Instrument connect and ping (Trilogy) ### v0.51.0 / 2023-10-16 -* CHANGED: See [#695](https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/695) for details +- CHANGED: See [#695](https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/695) for details ### v0.50.1 / 2023-09-07 -* BREAKING CHANGE: Align messaging instrumentation operation names (Resque) +- BREAKING CHANGE: Align messaging instrumentation operation names (Resque) ### v0.50.0 / 2023-09-07 -* BREAKING CHANGE: Align messaging instrumentation operation names [#648](https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/648) +- BREAKING CHANGE: Align messaging instrumentation operation names [#648](https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/648) ### v0.40.0 / 2023-08-07 -* ADDED: Add Gruf instrumentation +- ADDED: Add Gruf instrumentation ### v0.39.1 / 2023-06-05 -* FIXED: Use latest bug fix version for all dependencies +- FIXED: Use latest bug fix version for all dependencies ### v0.39.0 / 2023-06-02 -* BREAKING CHANGE: Separate logical MySQL host from connected host -* ADDED: Separate logical MySQL host from connected host +- BREAKING CHANGE: Separate logical MySQL host from connected host +- ADDED: Separate logical MySQL host from connected host ### v0.38.0 / 2023-05-31 -* BREAKING CHANGE: Add database name for trilogy traces +- BREAKING CHANGE: Add database name for trilogy traces -* ADDED: Add database name for trilogy traces +- ADDED: Add database name for trilogy traces ### v0.37.0 / 2023-05-25 -* ADDED: Add config[:obfuscation_limit] to pg and mysql2 -* ADDED: Add Obfuscation Limit Option to Trilogy - +- ADDED: Add config[:obfuscation_limit] to pg and mysql2 +- ADDED: Add Obfuscation Limit Option to Trilogy ### v0.36.0 / 2023-05-18 -* ADDED: GraphQL instrumentation: support new tracing API (#453) -* ADDED: Add span_preprocessor hook (#456) -* ADDED: add db.operation attribute for dalli (#458) +- ADDED: GraphQL instrumentation: support new tracing API (#453) +- ADDED: Add span_preprocessor hook (#456) +- ADDED: add db.operation attribute for dalli (#458) ### v0.35.0 / 2023-04-21 -* ADDED: Re-add Grape instrumentation to opentelemetry-instrumentation-all +- ADDED: Re-add Grape instrumentation to opentelemetry-instrumentation-all ### v0.34.0 / 2023-04-17 -* BREAKING CHANGE: Drop support for EoL Ruby 2.7 +- BREAKING CHANGE: Drop support for EoL Ruby 2.7 -* ADDED: Drop support for EoL Ruby 2.7 -* ADDED: Add Grape instrumentation +- ADDED: Drop support for EoL Ruby 2.7 +- ADDED: Add Grape instrumentation ### v0.33.0 / 2023-03-15 -* BREAKING CHANGE: Add support for GraphQL 2.0.19 +- BREAKING CHANGE: Add support for GraphQL 2.0.19 -* FIXED: Add support for GraphQL 2.0.19 +- FIXED: Add support for GraphQL 2.0.19 ### v0.32.0 / 2023-03-13 -* BREAKING CHANGE: Lock graphql max version to 2.0.17 -* FIXED: Lock graphql max version to 2.0.17 -* ADDED: Add with_attributes context propagation to Trilogy instrumentation -* ADDED: Add option to configure span name for trilogy -* FIXED: Ensure encoding errors handled during SQL obfuscation for Trilogy +- BREAKING CHANGE: Lock graphql max version to 2.0.17 +- FIXED: Lock graphql max version to 2.0.17 +- ADDED: Add with_attributes context propagation to Trilogy instrumentation +- ADDED: Add option to configure span name for trilogy +- FIXED: Ensure encoding errors handled during SQL obfuscation for Trilogy ### v0.31.0 / 2023-02-09 -* BREAKING CHANGE: Drop Rails 5 support [#324](https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/324) - +- BREAKING CHANGE: Drop Rails 5 support [#324](https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/324) ### v0.30.0 / 2023-01-31 -* BREAKING CHANGE: Updates instrumentations [#303](https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/303) +- BREAKING CHANGE: Updates instrumentations [#303](https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/303) ### v0.29.0 / 2023-01-14 -* BREAKING CHANGE: includes minor version updates in [#271](https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/271) +- BREAKING CHANGE: includes minor version updates in [#271](https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/271) ### v0.28.1 / 2023-01-14 -* DOCS: Fix gem homepage -* DOCS: More gem documentation fixes +- DOCS: Fix gem homepage +- DOCS: More gem documentation fixes ### v0.28.0 / 2022-11-09 -* ADDED: Bump minimum gem versions for opentelemetry-instrumentation-all -* ADDED: Instrumentation for racecar -* CHANGED: Update rails instrumentation +- ADDED: Bump minimum gem versions for opentelemetry-instrumentation-all +- ADDED: Instrumentation for racecar +- CHANGED: Update rails instrumentation ### v0.27.0 / 2022-10-14 -* CHANGED: Update Rails instrumentation +- CHANGED: Update Rails instrumentation ### v0.26.0 / 2022-10-12 -* ADDED: Upgrade min instrumentation versions See For Details https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/134 +- ADDED: Upgrade min instrumentation versions See For Details https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/134 ### v0.25.0 / 2022-06-09 -* Bump all dependencies to use base 0.21.0 +- Bump all dependencies to use base 0.21.0 ### v0.24.1 / 2022-05-05 -* (No significant changes) +- (No significant changes) ### v0.24.0 / 2022-05-02 -* ADDED: Adds instrumentation for rdkafka -* FIXED: Add rdkafka to all +- ADDED: Adds instrumentation for rdkafka +- FIXED: Add rdkafka to all ### v0.23.0 / 2022-01-26 -* ADDED: Add Trilogy Auto Instrumentation -* FIXED: `ActiveSupport` constant conflict in Active Model Serializers instrumentation -* FIXED: add missing require for aws_sdk instrumentation #1054 +- ADDED: Add Trilogy Auto Instrumentation +- FIXED: `ActiveSupport` constant conflict in Active Model Serializers instrumentation +- FIXED: add missing require for aws_sdk instrumentation #1054 ### v0.22.0 / 2021-12-01 -* ADDED: Move activesupport notification subscriber out of action_view gem +- ADDED: Move activesupport notification subscriber out of action_view gem ### v0.21.3 / 2021-10-07 -* (No significant changes) +- (No significant changes) ### v0.21.2 / 2021-09-29 -* (No significant changes) +- (No significant changes) ### v0.21.1 / 2021-09-29 -* (No significant changes) +- (No significant changes) ### v0.21.0 / 2021-09-15 -* ADDED: Add Que instrumentation +- ADDED: Add Que instrumentation ### v0.20.2 / 2021-09-09 -* (No significant changes) +- (No significant changes) ### v0.20.1 / 2021-08-18 -* FIXED: Instrumentation all sidekiq +- FIXED: Instrumentation all sidekiq ### v0.20.0 / 2021-08-12 -* ADDED: Instrument active record -* ADDED: Add ActionView instrumentation via ActiveSupport::Notifications +- ADDED: Instrument active record +- ADDED: Add ActionView instrumentation via ActiveSupport::Notifications ### v0.19.0 / 2021-06-25 -* ADDED: Add resque instrumentation -* ADDED: Add ActiveJob instrumentation -* ADDED: Configuration option to enable or disable redis root spans [#777](https://github.com/open-telemetry/opentelemetry-ruby/pull/777) -* FIXED: Broken instrumentation all release +- ADDED: Add resque instrumentation +- ADDED: Add ActiveJob instrumentation +- ADDED: Configuration option to enable or disable redis root spans [#777](https://github.com/open-telemetry/opentelemetry-ruby/pull/777) +- FIXED: Broken instrumentation all release ### v0.18.0 / 2021-05-21 -* ADDED: Add koala instrumentation +- ADDED: Add koala instrumentation ### v0.17.0 / 2021-04-22 -* ADDED: Add instrumentation for postgresql (pg gem) +- ADDED: Add instrumentation for postgresql (pg gem) ### v0.16.0 / 2021-03-17 -* ADDED: Instrument http gem -* ADDED: Instrument lmdb gem -* FIXED: Example scripts now reference local common lib -* DOCS: Replace Gitter with GitHub Discussions +- ADDED: Instrument http gem +- ADDED: Instrument lmdb gem +- FIXED: Example scripts now reference local common lib +- DOCS: Replace Gitter with GitHub Discussions ### v0.15.0 / 2021-02-18 -* ADDED: Instrument http client gem +- ADDED: Instrument http client gem ### v0.14.0 / 2021-02-03 -* (No significant changes) +- (No significant changes) ### v0.13.0 / 2021-01-29 -* (No significant changes) +- (No significant changes) ### v0.12.1 / 2021-01-13 -* ADDED: Instrument RubyKafka +- ADDED: Instrument RubyKafka ### v0.12.0 / 2020-12-24 -* ADDED: Instrument graphql +- ADDED: Instrument graphql ### v0.11.0 / 2020-12-11 -* FIXED: Copyright comments to not reference year +- FIXED: Copyright comments to not reference year ### v0.10.0 / 2020-12-03 -* FIXED: Otel-instrumentation-all not installing all +- FIXED: Otel-instrumentation-all not installing all ### v0.9.0 / 2020-11-27 -* ADDED: Add common helpers +- ADDED: Add common helpers ### v0.8.0 / 2020-10-27 -* (No significant changes) +- (No significant changes) ### v0.7.0 / 2020-10-07 -* DOCS: Standardize top-level docs structure and readme +- DOCS: Standardize top-level docs structure and readme ### v0.6.0 / 2020-09-10 -* Now depends on version 0.6.x of all the individual instrumentation gems. +- Now depends on version 0.6.x of all the individual instrumentation gems. diff --git a/instrumentation/all/lib/opentelemetry/instrumentation/all/version.rb b/instrumentation/all/lib/opentelemetry/instrumentation/all/version.rb index bffff61dd..93c736580 100644 --- a/instrumentation/all/lib/opentelemetry/instrumentation/all/version.rb +++ b/instrumentation/all/lib/opentelemetry/instrumentation/all/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Instrumentation module All - VERSION = '0.63.0' + VERSION = '0.64.0' end end end diff --git a/instrumentation/all/opentelemetry-instrumentation-all.gemspec b/instrumentation/all/opentelemetry-instrumentation-all.gemspec index 7af795545..54ee07265 100644 --- a/instrumentation/all/opentelemetry-instrumentation-all.gemspec +++ b/instrumentation/all/opentelemetry-instrumentation-all.gemspec @@ -44,9 +44,9 @@ Gem::Specification.new do |spec| spec.add_dependency 'opentelemetry-instrumentation-koala', '~> 0.20.1' spec.add_dependency 'opentelemetry-instrumentation-lmdb', '~> 0.22.1' spec.add_dependency 'opentelemetry-instrumentation-mongo', '~> 0.22.1' - spec.add_dependency 'opentelemetry-instrumentation-mysql2', '~> 0.27.0' + spec.add_dependency 'opentelemetry-instrumentation-mysql2', '~> 0.28.0' spec.add_dependency 'opentelemetry-instrumentation-net_http', '~> 0.22.1' - spec.add_dependency 'opentelemetry-instrumentation-pg', '~> 0.28.0' + spec.add_dependency 'opentelemetry-instrumentation-pg', '~> 0.29.0' spec.add_dependency 'opentelemetry-instrumentation-que', '~> 0.8.0' spec.add_dependency 'opentelemetry-instrumentation-racecar', '~> 0.3.0' spec.add_dependency 'opentelemetry-instrumentation-rack', '~> 0.24.0' @@ -59,7 +59,7 @@ Gem::Specification.new do |spec| spec.add_dependency 'opentelemetry-instrumentation-ruby_kafka', '~> 0.21.0' spec.add_dependency 'opentelemetry-instrumentation-sidekiq', '~> 0.25.0' spec.add_dependency 'opentelemetry-instrumentation-sinatra', '~> 0.24.0' - spec.add_dependency 'opentelemetry-instrumentation-trilogy', '~> 0.59.0' + spec.add_dependency 'opentelemetry-instrumentation-trilogy', '~> 0.60.0' spec.add_development_dependency 'active_model_serializers' spec.add_development_dependency 'activesupport' diff --git a/instrumentation/mysql2/CHANGELOG.md b/instrumentation/mysql2/CHANGELOG.md index 4d78d7856..e84ca9092 100644 --- a/instrumentation/mysql2/CHANGELOG.md +++ b/instrumentation/mysql2/CHANGELOG.md @@ -1,157 +1,160 @@ # Release History: opentelemetry-instrumentation-mysql2 +### v0.28.0 / 2024-09-12 + +- BREAKING CHANGE: Return message when sql is over the obfuscation limit. Fixes a bug where sql statements with prepended comments that hit the obfuscation limit would be sent raw. + ### v0.27.2 / 2024-07-23 -* DOCS: Add cspell to CI +- DOCS: Add cspell to CI ### v0.27.1 / 2024-04-30 -* FIXED: Bundler conflict warnings +- FIXED: Bundler conflict warnings ### v0.27.0 / 2024-02-15 -* ADDED: Instrument mysql2 prepare statement +- ADDED: Instrument mysql2 prepare statement ### v0.26.1 / 2024-02-08 -* FIXED: Add missing requires for sql-helpers to mysql, pg, and trilogy instrumentation +- FIXED: Add missing requires for sql-helpers to mysql, pg, and trilogy instrumentation ### v0.26.0 / 2024-02-08 -* BREAKING CHANGE: Move shared sql behavior to helper gems - +- BREAKING CHANGE: Move shared sql behavior to helper gems ### v0.25.0 / 2023-10-16 -* BREAKING CHANGE: Obfuscation for mysql2, dalli and postgresql as default option for db_statement +- BREAKING CHANGE: Obfuscation for mysql2, dalli and postgresql as default option for db_statement -* ADDED: Obfuscation for mysql2, dalli and postgresql as default option for db_statement +- ADDED: Obfuscation for mysql2, dalli and postgresql as default option for db_statement ### v0.24.3 / 2023-08-03 -* FIXED: Remove inline linter rules +- FIXED: Remove inline linter rules ### v0.24.2 / 2023-06-05 -* FIXED: Base config options +- FIXED: Base config options ### v0.24.1 / 2023-06-01 -* FIXED: Regex non-match with obfuscation limit (issue #486) +- FIXED: Regex non-match with obfuscation limit (issue #486) ### v0.24.0 / 2023-05-25 -* ADDED: Add config[:obfuscation_limit] to pg and mysql2 +- ADDED: Add config[:obfuscation_limit] to pg and mysql2 ### v0.23.0 / 2023-04-17 -* BREAKING CHANGE: Drop support for EoL Ruby 2.7 +- BREAKING CHANGE: Drop support for EoL Ruby 2.7 -* ADDED: Drop support for EoL Ruby 2.7 -* FIXED: Ensure encoding errors handled during SQL obfuscation for Trilogy +- ADDED: Drop support for EoL Ruby 2.7 +- FIXED: Ensure encoding errors handled during SQL obfuscation for Trilogy ### v0.22.0 / 2023-01-14 -* BREAKING CHANGE: Removed deprecated instrumentation options +- BREAKING CHANGE: Removed deprecated instrumentation options -* ADDED: Add option to configure span name -* ADDED: Removed deprecated instrumentation options -* DOCS: Fix gem homepage -* DOCS: More gem documentation fixes +- ADDED: Add option to configure span name +- ADDED: Removed deprecated instrumentation options +- DOCS: Fix gem homepage +- DOCS: More gem documentation fixes ### v0.21.1 / 2022-10-26 -* FIXED: Handle encoding errors in mysql obfuscation +- FIXED: Handle encoding errors in mysql obfuscation ### v0.21.0 / 2022-06-09 -* Upgrading Base dependency version -* FIXED: Broken test file requirements +- Upgrading Base dependency version +- FIXED: Broken test file requirements ### v0.20.1 / 2022-05-03 -* ADDED: `with_attributes` method for context propagation +- ADDED: `with_attributes` method for context propagation ### v0.20.0 / 2021-12-01 -* ADDED: Add default options config helper + env var config option support +- ADDED: Add default options config helper + env var config option support ### v0.19.1 / 2021-09-29 -* (No significant changes) +- (No significant changes) ### v0.19.0 / 2021-08-12 -* BREAKING CHANGE: Add option for db.statement +- BREAKING CHANGE: Add option for db.statement -* ADDED: Add option for db.statement -* DOCS: Update docs to rely more on environment variable configuration -* DOCS: Move to using new db_statement +- ADDED: Add option for db.statement +- DOCS: Update docs to rely more on environment variable configuration +- DOCS: Move to using new db_statement ### v0.18.1 / 2021-06-23 -* (No significant changes) +- (No significant changes) ### v0.18.0 / 2021-05-21 -* ADDED: Updated API dependency for 1.0.0.rc1 -* Fix: Nil value for db.name attribute #744 +- ADDED: Updated API dependency for 1.0.0.rc1 +- Fix: Nil value for db.name attribute #744 ### v0.17.0 / 2021-04-22 -* (No significant changes) +- (No significant changes) ### v0.16.0 / 2021-03-17 -* FIXED: Update DB semantic conventions -* FIXED: Example scripts now reference local common lib -* ADDED: Configurable obfuscation of sql in mysql2 instrumentation to avoid logging sensitive data +- FIXED: Update DB semantic conventions +- FIXED: Example scripts now reference local common lib +- ADDED: Configurable obfuscation of sql in mysql2 instrumentation to avoid logging sensitive data ### v0.15.0 / 2021-02-18 -* ADDED: Add instrumentation config validation +- ADDED: Add instrumentation config validation ### v0.14.0 / 2021-02-03 -* (No significant changes) +- (No significant changes) ### v0.13.0 / 2021-01-29 -* (No significant changes) +- (No significant changes) ### v0.12.0 / 2020-12-24 -* (No significant changes) +- (No significant changes) ### v0.11.0 / 2020-12-11 -* ADDED: Add peer service config to mysql -* FIXED: Copyright comments to not reference year +- ADDED: Add peer service config to mysql +- FIXED: Copyright comments to not reference year ### v0.10.1 / 2020-12-09 -* FIXED: Semantic conventions db.type -> db.system +- FIXED: Semantic conventions db.type -> db.system ### v0.10.0 / 2020-12-03 -* (No significant changes) +- (No significant changes) ### v0.9.0 / 2020-11-27 -* BREAKING CHANGE: Add timeout for force_flush and shutdown +- BREAKING CHANGE: Add timeout for force_flush and shutdown -* ADDED: Add timeout for force_flush and shutdown +- ADDED: Add timeout for force_flush and shutdown ### v0.8.0 / 2020-10-27 -* BREAKING CHANGE: Remove 'canonical' from status codes +- BREAKING CHANGE: Remove 'canonical' from status codes -* FIXED: Remove 'canonical' from status codes +- FIXED: Remove 'canonical' from status codes ### v0.7.0 / 2020-10-07 -* DOCS: Standardize top-level docs structure and readme +- DOCS: Standardize top-level docs structure and readme ### v0.6.0 / 2020-09-10 -* (No significant changes) +- (No significant changes) diff --git a/instrumentation/mysql2/lib/opentelemetry/instrumentation/mysql2/version.rb b/instrumentation/mysql2/lib/opentelemetry/instrumentation/mysql2/version.rb index ea71550ea..f6076089b 100644 --- a/instrumentation/mysql2/lib/opentelemetry/instrumentation/mysql2/version.rb +++ b/instrumentation/mysql2/lib/opentelemetry/instrumentation/mysql2/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Instrumentation module Mysql2 - VERSION = '0.27.2' + VERSION = '0.28.0' end end end diff --git a/instrumentation/pg/CHANGELOG.md b/instrumentation/pg/CHANGELOG.md index 36a25243a..0d291618b 100644 --- a/instrumentation/pg/CHANGELOG.md +++ b/instrumentation/pg/CHANGELOG.md @@ -1,122 +1,125 @@ # Release History: opentelemetry-instrumentation-pg +### v0.29.0 / 2024-09-12 + +- BREAKING CHANGE: Return message when sql is over the obfuscation limit. Fixes a bug where sql statements with prepended comments that hit the obfuscation limit would be sent raw. + ### v0.28.0 / 2024-08-15 -* ADDED: Collect pg db.collection_name attribute -* FIXED: Update versions to be tested (includes drop support for pg 1.2) +- ADDED: Collect pg db.collection_name attribute +- FIXED: Update versions to be tested (includes drop support for pg 1.2) ### v0.27.4 / 2024-07-23 -* DOCS: Add cspell to CI +- DOCS: Add cspell to CI ### v0.27.3 / 2024-05-11 -* ADDED: Support prepend SQL comment for PG instrumentation +- ADDED: Support prepend SQL comment for PG instrumentation ### v0.27.2 / 2024-04-30 -* FIXED: Bundler conflict warnings +- FIXED: Bundler conflict warnings ### v0.27.1 / 2024-02-08 -* FIXED: Add missing requires for sql-helpers to mysql, pg, and trilogy instrumentation +- FIXED: Add missing requires for sql-helpers to mysql, pg, and trilogy instrumentation ### v0.27.0 / 2024-02-08 -* BREAKING CHANGE: Move shared sql behavior to helper gems - +- BREAKING CHANGE: Move shared sql behavior to helper gems ### v0.26.1 / 2023-11-23 -* CHANGED: Applied Rubocop Performance Recommendations [#727](https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/727) +- CHANGED: Applied Rubocop Performance Recommendations [#727](https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/727) ### v0.26.0 / 2023-10-16 -* BREAKING CHANGE: Obfuscation for mysql2, dalli and postgresql as default option for db_statement +- BREAKING CHANGE: Obfuscation for mysql2, dalli and postgresql as default option for db_statement -* ADDED: Obfuscation for mysql2, dalli and postgresql as default option for db_statement +- ADDED: Obfuscation for mysql2, dalli and postgresql as default option for db_statement ### v0.25.3 / 2023-07-29 -* FIXED: Pass block explicitly in `define_method` calls for PG instrumentation query methods +- FIXED: Pass block explicitly in `define_method` calls for PG instrumentation query methods ### v0.25.2 / 2023-06-05 -* FIXED: Base config options +- FIXED: Base config options ### v0.25.1 / 2023-06-01 -* FIXED: Regex non-match with obfuscation limit (issue #486) +- FIXED: Regex non-match with obfuscation limit (issue #486) ### v0.25.0 / 2023-05-25 -* ADDED: Add config[:obfuscation_limit] to pg and mysql2 +- ADDED: Add config[:obfuscation_limit] to pg and mysql2 ### v0.24.0 / 2023-04-17 -* BREAKING CHANGE: Drop support for EoL Ruby 2.7 +- BREAKING CHANGE: Drop support for EoL Ruby 2.7 -* ADDED: Drop support for EoL Ruby 2.7 +- ADDED: Drop support for EoL Ruby 2.7 ### v0.23.0 / 2023-01-14 -* BREAKING CHANGE: Removed deprecated instrumentation options +- BREAKING CHANGE: Removed deprecated instrumentation options -* ADDED: Removed deprecated instrumentation options -* FIXED: Reduce Hash Allocations in PG Instrumentation -* DOCS: Fix gem homepage -* DOCS: More gem documentation fixes +- ADDED: Removed deprecated instrumentation options +- FIXED: Reduce Hash Allocations in PG Instrumentation +- DOCS: Fix gem homepage +- DOCS: More gem documentation fixes ### v0.22.3 / 2022-12-06 -* FIXED: Use attributes from the active PG connection +- FIXED: Use attributes from the active PG connection ### v0.22.2 / 2022-11-10 -* FIXED: Safeguard against host being nil +- FIXED: Safeguard against host being nil ### v0.22.1 / 2022-10-27 -* FIXED: Only take the first item in a comma-separated list for pg attrs +- FIXED: Only take the first item in a comma-separated list for pg attrs ### v0.22.0 / 2022-10-04 -* ADDED: Add `with_attributes` context propagation for PG instrumentation +- ADDED: Add `with_attributes` context propagation for PG instrumentation ### v0.21.0 / 2022-06-09 -* Upgrading Base dependency version -* FIXED: Broken test file requirements +- Upgrading Base dependency version +- FIXED: Broken test file requirements ### v0.20.0 / 2022-05-02 -* ADDED: Validate Using Enums -* FIXED: Update pg instrumentation to handle non primitive argument -* FIXED: RubyGems Fallback +- ADDED: Validate Using Enums +- FIXED: Update pg instrumentation to handle non primitive argument +- FIXED: RubyGems Fallback ### v0.19.2 / 2021-12-02 -* (No significant changes) +- (No significant changes) ### v0.19.1 / 2021-09-29 -* (No significant changes) +- (No significant changes) ### v0.19.0 / 2021-08-12 -* ADDED: Add db_statement toggle for postgres -* DOCS: Update docs to rely more on environment variable configuration +- ADDED: Add db_statement toggle for postgres +- DOCS: Update docs to rely more on environment variable configuration ### v0.18.1 / 2021-06-23 -* (No significant changes) +- (No significant changes) ### v0.18.0 / 2021-05-21 -* ADDED: Updated API dependency for 1.0.0.rc1 -* ADDED: Add option to postgres instrumentation to disable db.statement +- ADDED: Updated API dependency for 1.0.0.rc1 +- ADDED: Add option to postgres instrumentation to disable db.statement ### v0.17.1 / 2021-04-23 -* Initial release. -* ADDED: Initial postgresql instrumentation +- Initial release. +- ADDED: Initial postgresql instrumentation diff --git a/instrumentation/pg/lib/opentelemetry/instrumentation/pg/version.rb b/instrumentation/pg/lib/opentelemetry/instrumentation/pg/version.rb index 4496dc1aa..23b0157b9 100644 --- a/instrumentation/pg/lib/opentelemetry/instrumentation/pg/version.rb +++ b/instrumentation/pg/lib/opentelemetry/instrumentation/pg/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Instrumentation module PG - VERSION = '0.28.0' + VERSION = '0.29.0' end end end diff --git a/instrumentation/trilogy/CHANGELOG.md b/instrumentation/trilogy/CHANGELOG.md index 6b9fe2acf..f1e00396f 100644 --- a/instrumentation/trilogy/CHANGELOG.md +++ b/instrumentation/trilogy/CHANGELOG.md @@ -1,96 +1,100 @@ # Release History: opentelemetry-instrumentation-trilogy +### v0.60.0 / 2024-09-12 + +- BREAKING CHANGE: Return message when sql is over the obfuscation limit. Fixes a bug where sql statements with prepended comments that hit the obfuscation limit would be sent raw. + ### v0.59.3 / 2024-04-30 -* FIXED: Bundler conflict warnings +- FIXED: Bundler conflict warnings ### v0.59.2 / 2024-02-20 -* FIXED: Dup string if frozen in trilogy query +- FIXED: Dup string if frozen in trilogy query ### v0.59.1 / 2024-02-08 -* FIXED: Add missing requires for sql-helpers to mysql, pg, and trilogy instrumentation +- FIXED: Add missing requires for sql-helpers to mysql, pg, and trilogy instrumentation ### v0.59.0 / 2024-02-08 -* BREAKING CHANGE: Move shared sql behavior to helper gems +- BREAKING CHANGE: Move shared sql behavior to helper gems -* ADDED: Propagate context to Vitess +- ADDED: Propagate context to Vitess ### v0.58.0 / 2024-01-06 -* BREAKING CHANGE: Change db.mysql.instance.address to db.instance.id +- BREAKING CHANGE: Change db.mysql.instance.address to db.instance.id -* ADDED: Change db.mysql.instance.address to db.instance.id -* FIXED: Trilogy only set db.instance.id attribute if there is a value +- ADDED: Change db.mysql.instance.address to db.instance.id +- FIXED: Trilogy only set db.instance.id attribute if there is a value ### v0.57.0 / 2023-10-27 -* ADDED: Instrument connect and ping +- ADDED: Instrument connect and ping ### v0.56.3 / 2023-08-03 -* FIXED: Remove inline linter rules +- FIXED: Remove inline linter rules ### v0.56.2 / 2023-07-14 -* ADDED: `db.user` attribute (recommended connection-level attribute) +- ADDED: `db.user` attribute (recommended connection-level attribute) ### v0.56.1 / 2023-06-05 -* FIXED: Base config options +- FIXED: Base config options ### v0.56.0 / 2023-06-02 -* BREAKING CHANGE: Separate logical MySQL host from connected host +- BREAKING CHANGE: Separate logical MySQL host from connected host -* ADDED: Separate logical MySQL host from connected host +- ADDED: Separate logical MySQL host from connected host ### v0.55.1 / 2023-06-01 -* FIXED: Regex non-match with obfuscation limit (issue #486) +- FIXED: Regex non-match with obfuscation limit (issue #486) ### v0.55.0 / 2023-05-31 -* BREAKING CHANGE: Add database name for trilogy traces +- BREAKING CHANGE: Add database name for trilogy traces -* ADDED: Add database name for trilogy traces +- ADDED: Add database name for trilogy traces ### v0.54.0 / 2023-05-25 -* ADDED: Add Obfuscation Limit Option to Trilogy +- ADDED: Add Obfuscation Limit Option to Trilogy ### v0.53.0 / 2023-04-17 -* BREAKING CHANGE: Drop support for EoL Ruby 2.7 +- BREAKING CHANGE: Drop support for EoL Ruby 2.7 -* ADDED: Drop support for EoL Ruby 2.7 +- ADDED: Drop support for EoL Ruby 2.7 ### v0.52.0 / 2023-03-06 -* ADDED: Add with_attributes context propagation to Trilogy instrumentation -* ADDED: Add option to configure span name for trilogy -* FIXED: Ensure encoding errors handled during SQL obfuscation for Trilogy +- ADDED: Add with_attributes context propagation to Trilogy instrumentation +- ADDED: Add option to configure span name for trilogy +- FIXED: Ensure encoding errors handled during SQL obfuscation for Trilogy ### v0.51.1 / 2023-01-14 -* DOCS: Fix gem homepage -* DOCS: More gem documentation fixes +- DOCS: Fix gem homepage +- DOCS: More gem documentation fixes ### v0.51.0 / 2022-06-09 -* Upgrading Base dependency version -* FIXED: Broken test file requirements +- Upgrading Base dependency version +- FIXED: Broken test file requirements ### v0.50.2 / 2022-05-05 -* (No significant changes) +- (No significant changes) ### v0.50.1 / 2022-01-07 -* FIXED: Trilogy Driver Options +- FIXED: Trilogy Driver Options ### v0.50.0 / 2021-12-31 -* Initial release. +- Initial release. diff --git a/instrumentation/trilogy/lib/opentelemetry/instrumentation/trilogy/version.rb b/instrumentation/trilogy/lib/opentelemetry/instrumentation/trilogy/version.rb index 24cedba17..ebce38215 100644 --- a/instrumentation/trilogy/lib/opentelemetry/instrumentation/trilogy/version.rb +++ b/instrumentation/trilogy/lib/opentelemetry/instrumentation/trilogy/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Instrumentation module Trilogy - VERSION = '0.59.3' + VERSION = '0.60.0' end end end From 7671f4ee9dd37692e5f0e006ab2a263f7992dd0d Mon Sep 17 00:00:00 2001 From: Juli Tera <57973151+jterapin@users.noreply.github.com> Date: Wed, 18 Sep 2024 14:01:16 -0700 Subject: [PATCH 20/58] feat: All AWS services emit traces (#1150) * feat: All V3 services emit traces * refactor: Clean up Handler and MessageHelper * Revise based on feedback * Fix CI * Correctly handle V2 service clients * Add comments * Fix loaded_service check * Fix loaded_service check to be compatible with V3 --- .../instrumentation/aws_sdk/handler.rb | 84 ++++++------ .../aws_sdk/instrumentation.rb | 32 +++-- .../aws_sdk/messaging_helper.rb | 61 ++++++++- .../instrumentation/aws_sdk/services.rb | 121 ------------------ ...ntelemetry-instrumentation-aws_sdk.gemspec | 7 +- 5 files changed, 116 insertions(+), 189 deletions(-) delete mode 100644 instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/services.rb diff --git a/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/handler.rb b/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/handler.rb index a973adeb5..c0b040956 100644 --- a/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/handler.rb +++ b/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/handler.rb @@ -9,36 +9,32 @@ module Instrumentation module AwsSdk # Generates Spans for all interactions with AwsSdk class Handler < Seahorse::Client::Handler - SQS_SEND_MESSAGE = 'SQS.SendMessage' - SQS_SEND_MESSAGE_BATCH = 'SQS.SendMessageBatch' - SQS_RECEIVE_MESSAGE = 'SQS.ReceiveMessage' - SNS_PUBLISH = 'SNS.Publish' - def call(context) return super unless context - service_name = service_name(context) + service_id = service_name(context) operation = context.operation&.name - client_method = "#{service_name}.#{operation}" - attributes = { - 'aws.region' => context.config.region, - OpenTelemetry::SemanticConventions::Trace::RPC_SYSTEM => 'aws-api', - OpenTelemetry::SemanticConventions::Trace::RPC_METHOD => operation, - OpenTelemetry::SemanticConventions::Trace::RPC_SERVICE => service_name - } - attributes[SemanticConventions::Trace::DB_SYSTEM] = 'dynamodb' if service_name == 'DynamoDB' - MessagingHelper.apply_sqs_attributes(attributes, context, client_method) if service_name == 'SQS' - MessagingHelper.apply_sns_attributes(attributes, context, client_method) if service_name == 'SNS' + client_method = "#{service_id}.#{operation}" + + tracer.in_span( + span_name(context, client_method, service_id), + attributes: attributes(context, client_method, service_id, operation), + kind: span_kind(client_method, service_id) + ) do |span| + if instrumentation_config[:inject_messaging_context] && + %w[SQS SNS].include?(service_id) + MessagingHelper.inject_context(context, client_method) + end - tracer.in_span(span_name(context, client_method), attributes: attributes, kind: span_kind(client_method)) do |span| - inject_context(context, client_method) if instrumentation_config[:suppress_internal_instrumentation] OpenTelemetry::Common::Utilities.untraced { super } else super end.tap do |response| - span.set_attribute(OpenTelemetry::SemanticConventions::Trace::HTTP_STATUS_CODE, - context.http_response.status_code) + span.set_attribute( + OpenTelemetry::SemanticConventions::Trace::HTTP_STATUS_CODE, + context.http_response.status_code + ) if (err = response.error) span.record_exception(err) @@ -65,48 +61,40 @@ def service_name(context) context.client.class.api.metadata['serviceId'] || context.client.class.to_s.split('::')[1] end - SEND_MESSAGE_CLIENT_METHODS = [SQS_SEND_MESSAGE, SQS_SEND_MESSAGE_BATCH, SNS_PUBLISH].freeze - def inject_context(context, client_method) - return unless SEND_MESSAGE_CLIENT_METHODS.include? client_method - return unless instrumentation_config[:inject_messaging_context] - - if client_method == SQS_SEND_MESSAGE_BATCH - context.params[:entries].each do |entry| - entry[:message_attributes] ||= {} - OpenTelemetry.propagation.inject(entry[:message_attributes], setter: MessageAttributeSetter) - end + def span_kind(client_method, service_id) + case service_id + when 'SQS', 'SNS' + MessagingHelper.span_kind(client_method) else - context.params[:message_attributes] ||= {} - OpenTelemetry.propagation.inject(context.params[:message_attributes], setter: MessageAttributeSetter) + OpenTelemetry::Trace::SpanKind::CLIENT end end - def span_kind(client_method) - case client_method - when SQS_SEND_MESSAGE, SQS_SEND_MESSAGE_BATCH, SNS_PUBLISH - OpenTelemetry::Trace::SpanKind::PRODUCER - when SQS_RECEIVE_MESSAGE - OpenTelemetry::Trace::SpanKind::CONSUMER + def span_name(context, client_method, service_id) + case service_id + when 'SQS', 'SNS' + MessagingHelper.legacy_span_name(context, client_method) else - OpenTelemetry::Trace::SpanKind::CLIENT + client_method end end - def span_name(context, client_method) - case client_method - when SQS_SEND_MESSAGE, SQS_SEND_MESSAGE_BATCH, SNS_PUBLISH - "#{MessagingHelper.queue_name(context)} publish" - when SQS_RECEIVE_MESSAGE - "#{MessagingHelper.queue_name(context)} receive" - else - client_method + def attributes(context, client_method, service_id, operation) + { + 'aws.region' => context.config.region, + OpenTelemetry::SemanticConventions::Trace::RPC_SYSTEM => 'aws-api', + OpenTelemetry::SemanticConventions::Trace::RPC_METHOD => operation, + OpenTelemetry::SemanticConventions::Trace::RPC_SERVICE => service_id + }.tap do |attrs| + attrs[SemanticConventions::Trace::DB_SYSTEM] = 'dynamodb' if service_id == 'DynamoDB' + MessagingHelper.apply_span_attributes(context, attrs, client_method, service_id) if %w[SQS SNS].include?(service_id) end end end # A Seahorse::Client::Plugin that enables instrumentation for all AWS services class Plugin < Seahorse::Client::Plugin - def add_handlers(handlers, config) + def add_handlers(handlers, _config) # run before Seahorse::Client::Plugin::ParamValidator (priority 50) handlers.add Handler, step: :validate, priority: 49 end diff --git a/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/instrumentation.rb b/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/instrumentation.rb index 07b4075f2..928b9b98e 100644 --- a/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/instrumentation.rb +++ b/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/instrumentation.rb @@ -13,7 +13,7 @@ class Instrumentation < OpenTelemetry::Instrumentation::Base install do |_config| require_dependencies - add_plugin(Seahorse::Client::Base, *loaded_constants) + add_plugins(Seahorse::Client::Base, *loaded_service_clients) end present do @@ -41,31 +41,39 @@ def gem_version def require_dependencies require_relative 'handler' - require_relative 'services' require_relative 'message_attributes' require_relative 'messaging_helper' end - def add_plugin(*targets) + def add_plugins(*targets) targets.each { |klass| klass.add_plugin(AwsSdk::Plugin) } end - def loaded_constants - # Cross-check services against loaded AWS constants - # Module#const_get can return a constant from ancestors when there's a miss. - # If this conincidentally matches another constant, it will attempt to patch - # the wrong constant, resulting in patch failure. - available_services = ::Aws.constants & SERVICES.map(&:to_sym) - available_services.each_with_object([]) do |service, constants| - next if ::Aws.autoload?(service) + def loaded_service_clients + ::Aws.constants.each_with_object([]) do |c, constants| + m = ::Aws.const_get(c) + next unless loaded_service?(c, m) begin - constants << ::Aws.const_get(service, false).const_get(:Client, false) + constants << m.const_get(:Client) rescue StandardError => e OpenTelemetry.logger.warn("Constant could not be loaded: #{e}") end end end + + # This check does the following: + # 1 - Checks if the service client is autoload or not + # 2 - Validates whether if is a service client + # note that Seahorse::Client::Base is a superclass for V3 clients + # but for V2, it is Aws::Client + def loaded_service?(constant, service_module) + !::Aws.autoload?(constant) && + service_module.is_a?(Module) && + service_module.const_defined?(:Client) && + (service_module.const_get(:Client).superclass == Seahorse::Client::Base || + service_module.const_get(:Client).superclass == Aws::Client) + end end end end diff --git a/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/messaging_helper.rb b/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/messaging_helper.rb index e6fb8d0e4..27064aa74 100644 --- a/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/messaging_helper.rb +++ b/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/messaging_helper.rb @@ -7,9 +7,15 @@ module OpenTelemetry module Instrumentation module AwsSdk - # MessagingHelper class provides methods for calculating messaging span attributes + # An utility class to help SQS/SNS-related span attributes/context injection class MessagingHelper class << self + SQS_SEND_MESSAGE = 'SQS.SendMessage' + SQS_SEND_MESSAGE_BATCH = 'SQS.SendMessageBatch' + SQS_RECEIVE_MESSAGE = 'SQS.ReceiveMessage' + SNS_PUBLISH = 'SNS.Publish' + SEND_MESSAGE_CLIENT_METHODS = [SQS_SEND_MESSAGE, SQS_SEND_MESSAGE_BATCH, SNS_PUBLISH].freeze + def queue_name(context) topic_arn = context.params[:topic_arn] target_arn = context.params[:target_arn] @@ -28,19 +34,64 @@ def queue_name(context) 'unknown' end + def legacy_span_name(context, client_method) + case client_method + when SQS_SEND_MESSAGE, SQS_SEND_MESSAGE_BATCH, SNS_PUBLISH + "#{MessagingHelper.queue_name(context)} publish" + when SQS_RECEIVE_MESSAGE + "#{MessagingHelper.queue_name(context)} receive" + else + client_method + end + end + + def apply_span_attributes(context, attrs, client_method, service_id) + case service_id + when 'SQS' + apply_sqs_attributes(attrs, context, client_method) + when 'SNS' + apply_sns_attributes(attrs, context, client_method) + end + end + + def span_kind(client_method) + case client_method + when SQS_SEND_MESSAGE, SQS_SEND_MESSAGE_BATCH, SNS_PUBLISH + OpenTelemetry::Trace::SpanKind::PRODUCER + when SQS_RECEIVE_MESSAGE + OpenTelemetry::Trace::SpanKind::CONSUMER + else + OpenTelemetry::Trace::SpanKind::CLIENT + end + end + + def inject_context(context, client_method) + return unless SEND_MESSAGE_CLIENT_METHODS.include?(client_method) + + if client_method == SQS_SEND_MESSAGE_BATCH + context.params[:entries].each do |entry| + entry[:message_attributes] ||= {} + OpenTelemetry.propagation.inject(entry[:message_attributes], setter: MessageAttributeSetter) + end + else + context.params[:message_attributes] ||= {} + OpenTelemetry.propagation.inject(context.params[:message_attributes], setter: MessageAttributeSetter) + end + end + + private + def apply_sqs_attributes(attributes, context, client_method) attributes[SemanticConventions::Trace::MESSAGING_SYSTEM] = 'aws.sqs' attributes[SemanticConventions::Trace::MESSAGING_DESTINATION_KIND] = 'queue' attributes[SemanticConventions::Trace::MESSAGING_DESTINATION] = queue_name(context) attributes[SemanticConventions::Trace::MESSAGING_URL] = context.params[:queue_url] if context.params[:queue_url] - - attributes[SemanticConventions::Trace::MESSAGING_OPERATION] = 'receive' if client_method == 'SQS.ReceiveMessage' + attributes[SemanticConventions::Trace::MESSAGING_OPERATION] = 'receive' if client_method == SQS_RECEIVE_MESSAGE end def apply_sns_attributes(attributes, context, client_method) attributes[SemanticConventions::Trace::MESSAGING_SYSTEM] = 'aws.sns' - - return unless client_method == 'SNS.Publish' + return unless client_method == SNS_PUBLISH attributes[SemanticConventions::Trace::MESSAGING_DESTINATION_KIND] = 'topic' attributes[SemanticConventions::Trace::MESSAGING_DESTINATION] = queue_name(context) diff --git a/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/services.rb b/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/services.rb deleted file mode 100644 index d0bacb75f..000000000 --- a/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/services.rb +++ /dev/null @@ -1,121 +0,0 @@ -# frozen_string_literal: true - -module OpenTelemetry - module Instrumentation - # rubocop:disable Metrics/ModuleLength: - module AwsSdk - SERVICES = %w[ - ACM - APIGateway - AppStream - ApplicationAutoScaling - ApplicationDiscoveryService - Athena - AutoScaling - Batch - Budgets - CloudDirectory - CloudFormation - CloudFront - CloudHSM - CloudHSMV2 - CloudSearch - CloudSearchDomain - CloudTrail - CloudWatch - CloudWatchEvents - CloudWatchLogs - CodeBuild - CodeCommit - CodeDeploy - CodePipeline - CodeStar - CognitoIdentity - CognitoIdentityProvider - CognitoSync - ConfigService - CostandUsageReportService - DAX - DataPipeline - DatabaseMigrationService - DeviceFarm - DirectConnect - DirectoryService - DynamoDB - DynamoDBStreams - EC2 - ECR - ECS - EFS - EMR - ElastiCache - ElasticBeanstalk - ElasticLoadBalancing - ElasticLoadBalancingV2 - ElasticTranscoder - ElasticsearchService - EventBridge - Firehose - GameLift - Glacier - Glue - Greengrass - Health - IAM - ImportExport - Inspector - IoT - IoTDataPlane - KMS - Kinesis - KinesisAnalytics - Lambda - LambdaPreview - Lex - LexModelBuildingService - Lightsail - MTurk - MachineLearning - MarketplaceCommerceAnalytics - MarketplaceEntitlementService - MarketplaceMetering - MigrationHub - Mobile - OpsWorks - OpsWorksCM - Organizations - Pinpoint - Polly - RDS - Redshift - Rekognition - ResourceGroupsTaggingAPI - Route53 - Route53Domains - S3 - SES - SMS - SNS - SQS - SSM - STS - SWF - ServiceCatalog - Schemas - Shield - SimpleDB - Snowball - States - StorageGateway - Support - Textract - WAF - WAFRegional - WorkDocs - WorkSpaces - XRay - ].freeze - end - # rubocop:enable Metrics/ModuleLength: - end -end diff --git a/instrumentation/aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec b/instrumentation/aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec index 0c84297d7..6562625c6 100644 --- a/instrumentation/aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec +++ b/instrumentation/aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec @@ -19,9 +19,10 @@ Gem::Specification.new do |spec| spec.homepage = 'https://github.com/open-telemetry/opentelemetry-ruby-contrib' spec.license = 'Apache-2.0' - spec.files = Dir.glob('lib/**/*.rb') + - Dir.glob('*.md') + - ['LICENSE', '.yardopts'] + spec.files = + Dir.glob('lib/**/*.rb') + + Dir.glob('*.md') + + ['LICENSE', '.yardopts'] spec.require_paths = ['lib'] spec.required_ruby_version = '>= 3.0' From 2debf6f945323e35c32acad779b56fe18de99aa8 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Thu, 19 Sep 2024 17:17:17 -0700 Subject: [PATCH 21/58] release: Release 2 gems (#1175) * release: Release 2 gems * opentelemetry-instrumentation-all 0.64.1 (was 0.64.0) * opentelemetry-instrumentation-aws_sdk 0.6.0 (was 0.5.4) * chore: Bump aws_sdk version in all * chore: Bump all version to 0.65.0 --------- Co-authored-by: OpenTelemetry Bot <107717825+opentelemetrybot@users.noreply.github.com> Co-authored-by: Kayla Reopelle --- instrumentation/all/CHANGELOG.md | 4 ++++ .../all/lib/opentelemetry/instrumentation/all/version.rb | 2 +- instrumentation/all/opentelemetry-instrumentation-all.gemspec | 2 +- instrumentation/aws_sdk/CHANGELOG.md | 4 ++++ .../lib/opentelemetry/instrumentation/aws_sdk/version.rb | 2 +- 5 files changed, 11 insertions(+), 3 deletions(-) diff --git a/instrumentation/all/CHANGELOG.md b/instrumentation/all/CHANGELOG.md index 7d3116d2a..438034604 100644 --- a/instrumentation/all/CHANGELOG.md +++ b/instrumentation/all/CHANGELOG.md @@ -1,5 +1,9 @@ # Release History: opentelemetry-instrumentation-all +### v0.65.0 / 2024-09-19 + +* ADDED: All AWS services emit traces + ### v0.64.0 / 2024-09-12 - BREAKING CHANGE: Return message when sql is over the obfuscation limit. Fixes a bug where sql statements with prepended comments that hit the obfuscation limit would be sent raw. diff --git a/instrumentation/all/lib/opentelemetry/instrumentation/all/version.rb b/instrumentation/all/lib/opentelemetry/instrumentation/all/version.rb index 93c736580..987e5b61d 100644 --- a/instrumentation/all/lib/opentelemetry/instrumentation/all/version.rb +++ b/instrumentation/all/lib/opentelemetry/instrumentation/all/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Instrumentation module All - VERSION = '0.64.0' + VERSION = '0.65.0' end end end diff --git a/instrumentation/all/opentelemetry-instrumentation-all.gemspec b/instrumentation/all/opentelemetry-instrumentation-all.gemspec index 54ee07265..6434734c9 100644 --- a/instrumentation/all/opentelemetry-instrumentation-all.gemspec +++ b/instrumentation/all/opentelemetry-instrumentation-all.gemspec @@ -28,7 +28,7 @@ Gem::Specification.new do |spec| spec.add_dependency 'opentelemetry-instrumentation-active_model_serializers', '~> 0.20.1' spec.add_dependency 'opentelemetry-instrumentation-aws_lambda', '~> 0.1.0' - spec.add_dependency 'opentelemetry-instrumentation-aws_sdk', '~> 0.5.0' + spec.add_dependency 'opentelemetry-instrumentation-aws_sdk', '~> 0.6.0' spec.add_dependency 'opentelemetry-instrumentation-bunny', '~> 0.21.0' spec.add_dependency 'opentelemetry-instrumentation-concurrent_ruby', '~> 0.21.1' spec.add_dependency 'opentelemetry-instrumentation-dalli', '~> 0.25.0' diff --git a/instrumentation/aws_sdk/CHANGELOG.md b/instrumentation/aws_sdk/CHANGELOG.md index ae6f5e8a4..a382f2c7a 100644 --- a/instrumentation/aws_sdk/CHANGELOG.md +++ b/instrumentation/aws_sdk/CHANGELOG.md @@ -1,5 +1,9 @@ # Release History: opentelemetry-instrumentation-aws_sdk +### v0.6.0 / 2024-09-19 + +* ADDED: All AWS services emit traces + ### v0.5.4 / 2024-07-23 * DOCS: Add cspell to CI diff --git a/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/version.rb b/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/version.rb index b14b16581..0fbf946cf 100644 --- a/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/version.rb +++ b/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Instrumentation module AwsSdk - VERSION = '0.5.4' + VERSION = '0.6.0' end end end From dd0084bc1b9d696533ea0ee22dbcab470ee3827f Mon Sep 17 00:00:00 2001 From: Laur <49899951+laurglia@users.noreply.github.com> Date: Tue, 1 Oct 2024 21:24:58 +0300 Subject: [PATCH 22/58] fix(que): Fix bulk_enqueue when enqueuing more than 5 jobs (#1074) Previously, with Que `bulk_enqueue` a new span was created for every job in the batch. For each such span, a tag was added to _all_ jobs in the batch. This meant that if you enqueued 3 jobs, then 3 spans were created and each job had 3 tags pointing to 3 different spans. This behavior became problematic when you tried to insert more than 5 jobs, as Que supports up to 5 tags per job. More specifically, a runtime error was raised by Que. This commit fixes that bug by creating only a single span when using bulk_enqueue. --- .../instrumentation/que/patches/que_job.rb | 45 +++++++---- .../opentelemetry/instrumentation/que_test.rb | 78 +++++++++++++++++-- 2 files changed, 105 insertions(+), 18 deletions(-) diff --git a/instrumentation/que/lib/opentelemetry/instrumentation/que/patches/que_job.rb b/instrumentation/que/lib/opentelemetry/instrumentation/que/patches/que_job.rb index 5be898984..a189f5aee 100644 --- a/instrumentation/que/lib/opentelemetry/instrumentation/que/patches/que_job.rb +++ b/instrumentation/que/lib/opentelemetry/instrumentation/que/patches/que_job.rb @@ -19,6 +19,10 @@ class << base # Module to prepend to Que singleton class module ClassMethods def enqueue(*args, job_options: {}, **arg_opts) + # In Que version 2.1.0 `bulk_enqueue` was introduced. + # In that case, the span is created inside the `bulk_enqueue` method. + return super(*args, **arg_opts) if gem_version >= Gem::Version.new('2.1.0') && Thread.current[:que_jobs_to_bulk_insert] + tracer = Que::Instrumentation.instance.tracer otel_config = Que::Instrumentation.instance.config @@ -43,19 +47,8 @@ def enqueue(*args, job_options: {}, **arg_opts) OpenTelemetry.propagation.inject(tags, setter: TagSetter) end - # In Que version 2.1.0 `bulk_enqueue` was introduced and in order - # for it to work, we must pass `job_options` to `bulk_enqueue` instead of enqueue. - if gem_version >= Gem::Version.new('2.1.0') && Thread.current[:que_jobs_to_bulk_insert] - Thread.current[:que_jobs_to_bulk_insert][:job_options] = Thread.current[:que_jobs_to_bulk_insert][:job_options]&.merge(tags: tags) do |_, a, b| - a.is_a?(Array) && b.is_a?(Array) ? a.concat(b) : b - end - - job = super(*args, **arg_opts) - job_attrs = Thread.current[:que_jobs_to_bulk_insert][:jobs_attrs].last - else - job = super(*args, job_options: job_options.merge(tags: tags), **arg_opts) - job_attrs = job.que_attrs - end + job = super(*args, job_options: job_options.merge(tags: tags), **arg_opts) + job_attrs = job.que_attrs span.name = "#{job_attrs[:job_class]} publish" span.add_attributes(QueJob.job_attributes(job_attrs)) @@ -67,6 +60,32 @@ def enqueue(*args, job_options: {}, **arg_opts) def gem_version @gem_version ||= Gem.loaded_specs['que'].version end + + if Gem.loaded_specs['que'].version >= Gem::Version.new('2.1.0') + def bulk_enqueue(**_kwargs, &block) + tracer = Que::Instrumentation.instance.tracer + otel_config = Que::Instrumentation.instance.config + + tracer.in_span('publish', kind: :producer) do |span| + super do + yield + + job_attrs = Thread.current[:que_jobs_to_bulk_insert][:jobs_attrs] + + unless job_attrs.empty? + span.name = "#{job_attrs.first[:job_class]} publish" + span.add_attributes(QueJob.job_attributes(job_attrs.first)) + end + + if otel_config[:propagation_style] != :none + job_options = Thread.current[:que_jobs_to_bulk_insert][:job_options] + job_options[:tags] ||= [] + OpenTelemetry.propagation.inject(job_options[:tags], setter: TagSetter) + end + end + end + end + end end def self.job_attributes(job_attrs) diff --git a/instrumentation/que/test/opentelemetry/instrumentation/que_test.rb b/instrumentation/que/test/opentelemetry/instrumentation/que_test.rb index 9ec9847c1..7222e82cd 100644 --- a/instrumentation/que/test/opentelemetry/instrumentation/que_test.rb +++ b/instrumentation/que/test/opentelemetry/instrumentation/que_test.rb @@ -304,6 +304,74 @@ def self.run(first, second); end end end + describe 'enqueueing multiple jobs' do + it 'creates a span' do + Que.bulk_enqueue do + 10.times { TestJobAsync.enqueue } + end + + _(finished_spans.size).must_equal(1) + + span = finished_spans.last + _(span.kind).must_equal(:producer) + end + + it 'names the created span' do + Que.bulk_enqueue do + 10.times { TestJobAsync.enqueue } + end + + span = finished_spans.last + _(span.name).must_equal('TestJobAsync publish') + end + + it 'links spans together' do + bulk_jobs = Que.bulk_enqueue do + 10.times { TestJobAsync.enqueue } + end + + bulk_jobs.each { |job| Que.run_job_middleware(job) { job.tap(&:_run) } } + + _(finished_spans.size).must_equal(11) + + publish_span = finished_spans.first + + process_spans = finished_spans.drop(1) + + process_spans.each do |process_span| + _(publish_span.trace_id).wont_equal(process_span.trace_id) + + _(process_span.total_recorded_links).must_equal(1) + _(process_span.links[0].span_context.trace_id).must_equal(publish_span.trace_id) + _(process_span.links[0].span_context.span_id).must_equal(publish_span.span_id) + end + end + + it 'records attributes' do + Que.bulk_enqueue do + 10.times { TestJobAsync.enqueue } + end + + attributes = finished_spans.last.attributes + _(attributes['messaging.system']).must_equal('que') + _(attributes['messaging.destination']).must_equal('default') + _(attributes['messaging.destination_kind']).must_equal('queue') + _(attributes['messaging.operation']).must_equal('publish') + _(attributes['messaging.que.job_class']).must_equal('TestJobAsync') + _(attributes['messaging.que.priority']).must_equal(100) + _(attributes.key?('messaging.message_id')).must_equal(false) + end + end + + describe 'enqueueing zero jobs' do + it 'creates a span' do + Que.bulk_enqueue do + end + + _(finished_spans.size).must_equal(1) + end + end + describe 'processing a job' do before do bulk_job = Que.bulk_enqueue do @@ -363,10 +431,10 @@ def self.run(first, second); end _(finished_spans.size).must_equal(2) - span1 = finished_spans.first + span1 = finished_spans.last _(span1.kind).must_equal(:producer) - span2 = finished_spans.last + span2 = finished_spans.first _(span2.kind).must_equal(:consumer) end @@ -375,10 +443,10 @@ def self.run(first, second); end TestJobSync.enqueue end - span1 = finished_spans.first + span1 = finished_spans.last _(span1.name).must_equal('TestJobSync publish') - span2 = finished_spans.last + span2 = finished_spans.first _(span2.name).must_equal('TestJobSync process') end @@ -387,7 +455,7 @@ def self.run(first, second); end TestJobSync.enqueue end - attributes = finished_spans.last.attributes + attributes = finished_spans.first.attributes _(attributes['messaging.system']).must_equal('que') _(attributes['messaging.destination']).must_equal('default') _(attributes['messaging.destination_kind']).must_equal('queue') From ea603ac60f2a5001d9c05cbd1939ef5d58fedc17 Mon Sep 17 00:00:00 2001 From: Hannah Ramadan <76922290+hannahramadan@users.noreply.github.com> Date: Tue, 1 Oct 2024 11:48:35 -0700 Subject: [PATCH 23/58] chore: Update CONTRIBUTING instructions for running tests using Appraisal (#1167) * chore: Update contributing instructions for running tests * Update CONTRIBUTING.md Co-authored-by: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com> --------- Co-authored-by: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com> --- CONTRIBUTING.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 58466f717..dc7c281c7 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -80,6 +80,12 @@ For example, to test `opentelemetry-instrumentation-action_pack` you would: 2. Install the bundle with `bundle install` 3. Run the tests with `bundle exec rake` +Note: Some test suites make use of [Appraisal](https://github.com/thoughtbot/appraisal), a library for testing against different versions of dependencies. To run tests in suites that use Appraisal: + + 1. Change directory to the instrumentation you'd like to test, ex: `instrumentation/action_pack` + 2. Install the bundle with `bundle exec appraisal install` + 3. Run the tests with `bundle exec appraisal rake test` + ### Docker setup We use Docker Compose to configure and build services used in development and From 7b349b177d0fce296efdb92e5f4453c457f142b4 Mon Sep 17 00:00:00 2001 From: Sam <370182+plantfansam@users.noreply.github.com> Date: Tue, 1 Oct 2024 13:14:05 -0600 Subject: [PATCH 24/58] chore: update env var in vitess docs (#1176) Co-authored-by: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com> --- propagator/vitess/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/propagator/vitess/README.md b/propagator/vitess/README.md index 47b88eda3..cb5c96ef9 100644 --- a/propagator/vitess/README.md +++ b/propagator/vitess/README.md @@ -40,7 +40,7 @@ Or, if you use [bundler][bundler-home], include `opentelemetry-propagator-vitess Configure your application to use this propagator with the Trilogy client instrumentation by setting the following [environment variable][envars]: ```console -OTEL_RUBY_INSTRUMENTATION_TRILOGY_PROPAGATOR=vitess +OTEL_RUBY_INSTRUMENTATION_TRILOGY_CONFIG_OPTS=propagator=vitess ``` ## How can I get involved? From 0a7f9e7950a37292d0092da7433dce821a9f524f Mon Sep 17 00:00:00 2001 From: Alex Boten <223565+codeboten@users.noreply.github.com> Date: Tue, 1 Oct 2024 12:37:26 -0700 Subject: [PATCH 25/58] fix: update references to logging exporter (#1178) * examples: update references to logging exporter This exporter has been replaced by the debug exporter and will be removed soon Signed-off-by: Alex Boten <223565+codeboten@users.noreply.github.com> * update example to use v0.109.0 of the collector Signed-off-by: Alex Boten <223565+codeboten@users.noreply.github.com> --------- Signed-off-by: Alex Boten <223565+codeboten@users.noreply.github.com> Co-authored-by: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com> --- docker-compose.yml | 6 +++--- otelcol-config.yml | 10 ++++++---- 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index af815eabe..b77ad0e9d 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -217,7 +217,7 @@ services: image: memcached:alpine command: memcached -m 64 ports: - - "11211:11211" + - "11211:11211" zookeeper: image: confluentinc/cp-zookeeper:latest @@ -248,8 +248,8 @@ services: - "16686:16686" otelcol: - image: otel/opentelemetry-collector:0.54.0 - command: [ "--config=/etc/otelcol-config.yml" ] + image: otel/opentelemetry-collector:0.109.0 + command: ["--config=/etc/otelcol-config.yml"] volumes: - ./otelcol-config.yml:/etc/otelcol-config.yml ports: diff --git a/otelcol-config.yml b/otelcol-config.yml index e653551b5..c406f0517 100644 --- a/otelcol-config.yml +++ b/otelcol-config.yml @@ -2,13 +2,15 @@ receivers: otlp: protocols: grpc: + endpoint: 0.0.0.0:4317 http: + endpoint: 0.0.0.0:4318 exporters: - jaeger: - endpoint: "jaeger:14250" + otlp: + endpoint: "jaeger:4317" tls: insecure: true - logging: + debug: processors: batch: @@ -18,4 +20,4 @@ service: traces: receivers: [otlp] processors: [batch] - exporters: [logging, jaeger] + exporters: [debug, otlp] From 745c333b2037c74cba0285ffa6aefb7dc8a866ce Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 2 Oct 2024 13:32:27 -0700 Subject: [PATCH 26/58] chore: bump ruby/setup-ruby from 1.191.0 to 1.194.0 (#1182) * chore: bump ruby/setup-ruby from 1.191.0 to 1.194.0 Bumps [ruby/setup-ruby](https://github.com/ruby/setup-ruby) from 1.191.0 to 1.194.0. - [Release notes](https://github.com/ruby/setup-ruby/releases) - [Changelog](https://github.com/ruby/setup-ruby/blob/master/release.rb) - [Commits](https://github.com/ruby/setup-ruby/compare/v1.191.0...v1.194.0) --- updated-dependencies: - dependency-name: ruby/setup-ruby dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] * chore: Update action.yml setup-ruby to 1.194.0 --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Kayla Reopelle Co-authored-by: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com> --- .github/actions/test_gem/action.yml | 4 ++-- .github/workflows/installation-tests.yml | 2 +- .github/workflows/release-hook-on-closed.yml | 2 +- .github/workflows/release-hook-on-push.yml | 2 +- .github/workflows/release-perform.yml | 2 +- .github/workflows/release-please.yaml | 2 +- .github/workflows/release-request-weekly.yml | 2 +- .github/workflows/release-request.yml | 2 +- .github/workflows/release-retry.yml | 2 +- 9 files changed, 10 insertions(+), 10 deletions(-) diff --git a/.github/actions/test_gem/action.yml b/.github/actions/test_gem/action.yml index 25418da4c..4b4ddfbcf 100644 --- a/.github/actions/test_gem/action.yml +++ b/.github/actions/test_gem/action.yml @@ -66,7 +66,7 @@ runs: # ...but not for appraisals, sadly. - name: Install Ruby ${{ inputs.ruby }} with dependencies if: "${{ steps.setup.outputs.appraisals == 'false' }}" - uses: ruby/setup-ruby@v1.191.0 + uses: ruby/setup-ruby@v1.194.0 with: ruby-version: "${{ inputs.ruby }}" working-directory: "${{ steps.setup.outputs.gem_dir }}" @@ -77,7 +77,7 @@ runs: # If we're using appraisals, do it all manually. - name: Install Ruby ${{ inputs.ruby }} without dependencies if: "${{ steps.setup.outputs.appraisals == 'true' }}" - uses: ruby/setup-ruby@v1.191.0 + uses: ruby/setup-ruby@v1.194.0 with: ruby-version: "${{ inputs.ruby }}" bundler: "latest" diff --git a/.github/workflows/installation-tests.yml b/.github/workflows/installation-tests.yml index e71acac29..5efb7c95e 100644 --- a/.github/workflows/installation-tests.yml +++ b/.github/workflows/installation-tests.yml @@ -25,7 +25,7 @@ jobs: - uses: actions/checkout@v4 # ATTENTION: Dependabot does not know how to update shared actions file. # If you see it update setup-ruby here also update it as part of actions/test_gem/action.yml - - uses: ruby/setup-ruby@v1.191.0 + - uses: ruby/setup-ruby@v1.194.0 with: ruby-version: ${{ matrix.ruby-version }} - name: "Install Latest Gem Versions on ${{ matrix.ruby-version }}" diff --git a/.github/workflows/release-hook-on-closed.yml b/.github/workflows/release-hook-on-closed.yml index ef5cb741e..29c07df0f 100644 --- a/.github/workflows/release-hook-on-closed.yml +++ b/.github/workflows/release-hook-on-closed.yml @@ -12,7 +12,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.191.0 + uses: ruby/setup-ruby@v1.194.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-hook-on-push.yml b/.github/workflows/release-hook-on-push.yml index bbe48deb2..66653b863 100644 --- a/.github/workflows/release-hook-on-push.yml +++ b/.github/workflows/release-hook-on-push.yml @@ -13,7 +13,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.191.0 + uses: ruby/setup-ruby@v1.194.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-perform.yml b/.github/workflows/release-perform.yml index c4b13ca12..e7cfd5af5 100644 --- a/.github/workflows/release-perform.yml +++ b/.github/workflows/release-perform.yml @@ -22,7 +22,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.191.0 + uses: ruby/setup-ruby@v1.194.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-please.yaml b/.github/workflows/release-please.yaml index c8cfb286f..0e113ec04 100644 --- a/.github/workflows/release-please.yaml +++ b/.github/workflows/release-please.yaml @@ -50,7 +50,7 @@ jobs: chmod 0600 $HOME/.gem/credentials printf -- "---\n:rubygems_api_key: ${GEM_HOST_API_KEY}\n" > $HOME/.gem/credentials - - uses: ruby/setup-ruby@v1.191.0 + - uses: ruby/setup-ruby@v1.194.0 with: ruby-version: "3.0" bundler: latest diff --git a/.github/workflows/release-request-weekly.yml b/.github/workflows/release-request-weekly.yml index 6865df226..03c1ca27c 100644 --- a/.github/workflows/release-request-weekly.yml +++ b/.github/workflows/release-request-weekly.yml @@ -12,7 +12,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.191.0 + uses: ruby/setup-ruby@v1.194.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-request.yml b/.github/workflows/release-request.yml index d2b0c3ea5..6d208071d 100644 --- a/.github/workflows/release-request.yml +++ b/.github/workflows/release-request.yml @@ -16,7 +16,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.191.0 + uses: ruby/setup-ruby@v1.194.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-retry.yml b/.github/workflows/release-retry.yml index 626146815..27e8149d3 100644 --- a/.github/workflows/release-retry.yml +++ b/.github/workflows/release-retry.yml @@ -19,7 +19,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.191.0 + uses: ruby/setup-ruby@v1.194.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo From a71d905979982e74810e49372864580a165f08b4 Mon Sep 17 00:00:00 2001 From: Juli Tera <57973151+jterapin@users.noreply.github.com> Date: Mon, 7 Oct 2024 15:49:20 -0700 Subject: [PATCH 27/58] feat: Integration with V3 telemetry provider (#1186) * feat: Integration with V3 telemetry provider * Fix CI failure * Fix CI failure - attempt 2 * Fix CI failure - attempt 3 * Fix CI failure - attempt 4 * Add minor cleanup * Address feedbacks * Add handler helper to contain shared methods * Add config documentation * Add minor update * Update based on feedbacks --------- Co-authored-by: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com> --- instrumentation/aws_sdk/Appraisals | 57 +--- instrumentation/aws_sdk/README.md | 24 ++ .../instrumentation/aws_sdk/handler.rb | 62 +--- .../instrumentation/aws_sdk/handler_helper.rb | 81 +++++ .../aws_sdk/instrumentation.rb | 52 ++- .../aws_sdk/messaging_helper.rb | 23 ++ .../aws_sdk/patches/telemetry.rb | 40 +++ .../test/opentelemetry/handler_test.rb | 201 ++++++++++++ .../opentelemetry/instrumentation_test.rb | 230 +------------- .../opentelemetry/message_attributes_test.rb | 84 +++++ .../opentelemetry/patches/telemetry_test.rb | 297 ++++++++++++++++++ instrumentation/aws_sdk/test/test_helper.rb | 17 + 12 files changed, 853 insertions(+), 315 deletions(-) create mode 100644 instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/handler_helper.rb create mode 100644 instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/patches/telemetry.rb create mode 100644 instrumentation/aws_sdk/test/opentelemetry/handler_test.rb create mode 100644 instrumentation/aws_sdk/test/opentelemetry/message_attributes_test.rb create mode 100644 instrumentation/aws_sdk/test/opentelemetry/patches/telemetry_test.rb diff --git a/instrumentation/aws_sdk/Appraisals b/instrumentation/aws_sdk/Appraisals index 5ecdbf591..c9c9b908b 100644 --- a/instrumentation/aws_sdk/Appraisals +++ b/instrumentation/aws_sdk/Appraisals @@ -4,58 +4,27 @@ # # SPDX-License-Identifier: Apache-2.0 -appraise 'aws-sdk-3.1' do - gem 'aws-sdk', '~> 3.1' +appraise 'aws-sdk-3' do + gem 'aws-sdk-core', '~> 3' + gem 'aws-sdk-lambda', '~> 1' + gem 'aws-sdk-dynamodb', '~> 1' + gem 'aws-sdk-sns', '~> 1' + gem 'aws-sdk-sqs', '~> 1' end -appraise 'aws-sdk-3.0' do - gem 'aws-sdk', '~> 3.0' +# pre-Observability support in V3 SDK +appraise 'aws-sdk-3.202' do + gem 'aws-sdk-core', '~> 3.202' + gem 'aws-sdk-lambda', '~> 1.127' + gem 'aws-sdk-dynamodb', '~> 1.118' + gem 'aws-sdk-sns', '~> 1.82' + gem 'aws-sdk-sqs', '~> 1.80' end appraise 'aws-sdk-2.11' do gem 'aws-sdk', '~> 2.11' end -appraise 'aws-sdk-2.10' do - gem 'aws-sdk', '~> 2.10' -end - -appraise 'aws-sdk-2.9' do - gem 'aws-sdk', '~> 2.9' -end - -appraise 'aws-sdk-2.8' do - gem 'aws-sdk', '~> 2.8' -end - -appraise 'aws-sdk-2.7' do - gem 'aws-sdk', '~> 2.7' -end - -appraise 'aws-sdk-2.6' do - gem 'aws-sdk', '~> 2.6' -end - -appraise 'aws-sdk-2.5' do - gem 'aws-sdk', '~> 2.5' -end - -appraise 'aws-sdk-2.4' do - gem 'aws-sdk', '~> 2.4' -end - -appraise 'aws-sdk-2.3' do - gem 'aws-sdk', '~> 2.3' -end - -appraise 'aws-sdk-2.2' do - gem 'aws-sdk', '~> 2.2' -end - -appraise 'aws-sdk-2.1' do - gem 'aws-sdk', '~> 2.1' -end - appraise 'aws-sdk-2.0' do gem 'aws-sdk', '~> 2.0' end diff --git a/instrumentation/aws_sdk/README.md b/instrumentation/aws_sdk/README.md index e1885d7a9..fcf4de368 100644 --- a/instrumentation/aws_sdk/README.md +++ b/instrumentation/aws_sdk/README.md @@ -32,6 +32,30 @@ OpenTelemetry::SDK.configure do |c| c.use_all end ``` +### Configuration options +This instrumentation offers the following configuration options: +* `:inject_messaging_context` (default: `false`): When set to `true`, adds context key/value + to Message Attributes for SQS/SNS messages. +* `suppress_internal_instrumentation` (default: `false`): When set to `true`, any spans with + span kind of `internal` are suppressed from traces. + +## Integration with SDK V3's Telemetry support +AWS SDK for Ruby V3 added support for Observability which includes a new configuration, +`telemetry_provider` and an OpenTelemetry-based telemetry provider. Only applies to +AWS service gems released after 2024-09-03. + +Using later versions of these gems will give more details on the internal spans. +See below for example usage: +```ruby +# configures the OpenTelemetry SDK with instrumentation defaults +OpenTelemetry::SDK.configure do |c| + c.use 'OpenTelemetry::Instrumentation::AwsSdk' +end + +# create open-telemetry provider and pass to client config +otel_provider = Aws::Telemetry::OTelProvider.new +client = Aws::S3::Client.new(telemetry_provider: otel_provider) +``` ## Example diff --git a/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/handler.rb b/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/handler.rb index c0b040956..40ec604c7 100644 --- a/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/handler.rb +++ b/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/handler.rb @@ -7,26 +7,23 @@ module OpenTelemetry module Instrumentation module AwsSdk - # Generates Spans for all interactions with AwsSdk + # This handler supports specifically supports V2 and V3 + # prior to Observability support released on 2024-09-03. class Handler < Seahorse::Client::Handler def call(context) return super unless context - service_id = service_name(context) - operation = context.operation&.name - client_method = "#{service_id}.#{operation}" + service_id = HandlerHelper.service_id(context, legacy: true) + client_method = HandlerHelper.client_method(service_id, context) tracer.in_span( - span_name(context, client_method, service_id), - attributes: attributes(context, client_method, service_id, operation), - kind: span_kind(client_method, service_id) + HandlerHelper.span_name(context, client_method, service_id, legacy: true), + attributes: HandlerHelper.span_attributes(context, client_method, service_id, legacy: true), + kind: HandlerHelper.span_kind(client_method, service_id) ) do |span| - if instrumentation_config[:inject_messaging_context] && - %w[SQS SNS].include?(service_id) - MessagingHelper.inject_context(context, client_method) - end + MessagingHelper.inject_context_if_supported(context, client_method, service_id) - if instrumentation_config[:suppress_internal_instrumentation] + if HandlerHelper.instrumentation_config[:suppress_internal_instrumentation] OpenTelemetry::Common::Utilities.untraced { super } else super @@ -49,47 +46,6 @@ def call(context) def tracer AwsSdk::Instrumentation.instance.tracer end - - def instrumentation_config - AwsSdk::Instrumentation.instance.config - end - - def service_name(context) - # Support aws-sdk v2.0.x, which 'metadata' has a setter method only - return context.client.class.to_s.split('::')[1] if ::Seahorse::Model::Api.instance_method(:metadata).parameters.length.positive? - - context.client.class.api.metadata['serviceId'] || context.client.class.to_s.split('::')[1] - end - - def span_kind(client_method, service_id) - case service_id - when 'SQS', 'SNS' - MessagingHelper.span_kind(client_method) - else - OpenTelemetry::Trace::SpanKind::CLIENT - end - end - - def span_name(context, client_method, service_id) - case service_id - when 'SQS', 'SNS' - MessagingHelper.legacy_span_name(context, client_method) - else - client_method - end - end - - def attributes(context, client_method, service_id, operation) - { - 'aws.region' => context.config.region, - OpenTelemetry::SemanticConventions::Trace::RPC_SYSTEM => 'aws-api', - OpenTelemetry::SemanticConventions::Trace::RPC_METHOD => operation, - OpenTelemetry::SemanticConventions::Trace::RPC_SERVICE => service_id - }.tap do |attrs| - attrs[SemanticConventions::Trace::DB_SYSTEM] = 'dynamodb' if service_id == 'DynamoDB' - MessagingHelper.apply_span_attributes(context, attrs, client_method, service_id) if %w[SQS SNS].include?(service_id) - end - end end # A Seahorse::Client::Plugin that enables instrumentation for all AWS services diff --git a/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/handler_helper.rb b/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/handler_helper.rb new file mode 100644 index 000000000..9b5a01304 --- /dev/null +++ b/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/handler_helper.rb @@ -0,0 +1,81 @@ +# frozen_string_literal: true + +# Copyright The OpenTelemetry Authors +# +# SPDX-License-Identifier: Apache-2.0 + +module OpenTelemetry + module Instrumentation + module AwsSdk + # Utility module that contains shared methods between AwsSdk and Telemetry handlers + module HandlerHelper + class << self + def instrumentation_config + AwsSdk::Instrumentation.instance.config + end + + def client_method(service_id, context) + "#{service_id}.#{context.operation.name}".delete(' ') + end + + def span_attributes(context, client_method, service_id, legacy: false) + { + 'aws.region' => context.config.region, + OpenTelemetry::SemanticConventions::Trace::CODE_FUNCTION => context.operation_name.to_s, + OpenTelemetry::SemanticConventions::Trace::CODE_NAMESPACE => 'Aws::Plugins::Telemetry', + OpenTelemetry::SemanticConventions::Trace::RPC_METHOD => context.operation.name, + OpenTelemetry::SemanticConventions::Trace::RPC_SERVICE => service_id, + OpenTelemetry::SemanticConventions::Trace::RPC_SYSTEM => 'aws-api' + }.tap do |attrs| + attrs[OpenTelemetry::SemanticConventions::Trace::CODE_NAMESPACE] = 'Aws::Plugins::AwsSdk' if legacy + attrs[SemanticConventions::Trace::DB_SYSTEM] = 'dynamodb' if service_id == 'DynamoDB' + + MessagingHelper.apply_span_attributes(context, attrs, client_method, service_id) if MessagingHelper::SUPPORTED_SERVICES.include?(service_id) + end + end + + def span_kind(client_method, service_id) + case service_id + when *MessagingHelper::SUPPORTED_SERVICES + MessagingHelper.span_kind(client_method) + else + OpenTelemetry::Trace::SpanKind::CLIENT + end + end + + def span_name(context, client_method, service_id, legacy: false) + case service_id + when *MessagingHelper::SUPPORTED_SERVICES + if legacy + MessagingHelper.legacy_span_name(context, client_method) + else + MessagingHelper.span_name(context, client_method) + end + else + client_method + end + end + + def service_id(context, legacy: false) + if legacy + legacy_service_id(context) + else + context.config.api.metadata['serviceId'] || + context.config.api.metadata['serviceAbbreviation'] || + context.config.api.metadata['serviceFullName'] + end + end + + private + + def legacy_service_id(context) + # Support aws-sdk v2.0.x, which 'metadata' has a setter method only + return context.client.class.to_s.split('::')[1] if ::Seahorse::Model::Api.instance_method(:metadata).parameters.length.positive? + + context.client.class.api.metadata['serviceId'] || context.client.class.to_s.split('::')[1] + end + end + end + end + end +end diff --git a/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/instrumentation.rb b/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/instrumentation.rb index 928b9b98e..fe8651c25 100644 --- a/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/instrumentation.rb +++ b/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/instrumentation.rb @@ -7,12 +7,38 @@ module OpenTelemetry module Instrumentation module AwsSdk - # Instrumentation class that detects and installs the AwsSdk instrumentation + # The `OpenTelemetry::Instrumentation::AwsSdk::Instrumentation` class contains + # logic to detect and install the AwsSdk instrumentation. + # + # ## Configuration keys and options + # + # ### `:inject_messaging_context` + # + # Allows adding of context key/value to Message Attributes for SQS/SNS messages. + # + # - `false` **(default)** - Context key/value will not be added. + # - `true` - Context key/value will be added. + # + # ### `:suppress_internal_instrumentation` + # + # Disables tracing of spans of `internal` span kind. + # + # - `false` **(default)** - Internal spans are traced. + # - `true` - Internal spans are not traced. + # + # @example An explicit default configuration + # OpenTelemetry::SDK.configure do |c| + # c.use 'OpenTelemetry::Instrumentation::AwsSdk', { + # inject_messaging_context: false, + # suppress_internal_instrumentation: false + # } + # end class Instrumentation < OpenTelemetry::Instrumentation::Base MINIMUM_VERSION = Gem::Version.new('2.0.0') install do |_config| require_dependencies + patch_telemetry_plugin if telemetry_plugin? add_plugins(Seahorse::Client::Base, *loaded_service_clients) end @@ -41,12 +67,34 @@ def gem_version def require_dependencies require_relative 'handler' + require_relative 'handler_helper' require_relative 'message_attributes' require_relative 'messaging_helper' + require_relative 'patches/telemetry' end def add_plugins(*targets) - targets.each { |klass| klass.add_plugin(AwsSdk::Plugin) } + targets.each do |klass| + next if supports_telemetry_plugin?(klass) + + klass.add_plugin(AwsSdk::Plugin) + end + end + + def supports_telemetry_plugin?(klass) + telemetry_plugin? && + klass.plugins.include?(Aws::Plugins::Telemetry) + end + + def telemetry_plugin? + ::Aws::Plugins.const_defined?(:Telemetry) + end + + # Patches AWS SDK V3's telemetry plugin for integration + # This patch supports configuration set by this gem and + # additional span attributes that was not provided by the plugin + def patch_telemetry_plugin + ::Aws::Plugins::Telemetry::Handler.prepend(Patches::Handler) end def loaded_service_clients diff --git a/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/messaging_helper.rb b/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/messaging_helper.rb index 27064aa74..b821aca56 100644 --- a/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/messaging_helper.rb +++ b/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/messaging_helper.rb @@ -9,6 +9,7 @@ module Instrumentation module AwsSdk # An utility class to help SQS/SNS-related span attributes/context injection class MessagingHelper + SUPPORTED_SERVICES = %w[SQS SNS].freeze class << self SQS_SEND_MESSAGE = 'SQS.SendMessage' SQS_SEND_MESSAGE_BATCH = 'SQS.SendMessageBatch' @@ -16,6 +17,10 @@ class << self SNS_PUBLISH = 'SNS.Publish' SEND_MESSAGE_CLIENT_METHODS = [SQS_SEND_MESSAGE, SQS_SEND_MESSAGE_BATCH, SNS_PUBLISH].freeze + def supported_services + SUPPORTED_SERVICES + end + def queue_name(context) topic_arn = context.params[:topic_arn] target_arn = context.params[:target_arn] @@ -34,6 +39,17 @@ def queue_name(context) 'unknown' end + def span_name(context, client_method) + case client_method + when SQS_SEND_MESSAGE, SQS_SEND_MESSAGE_BATCH, SNS_PUBLISH + "#{client_method}.#{queue_name(context)}.Publish" + when SQS_RECEIVE_MESSAGE + "#{client_method}.#{queue_name(context)}.Receive" + else + client_method + end + end + def legacy_span_name(context, client_method) case client_method when SQS_SEND_MESSAGE, SQS_SEND_MESSAGE_BATCH, SNS_PUBLISH @@ -65,6 +81,13 @@ def span_kind(client_method) end end + def inject_context_if_supported(context, client_method, service_id) + if HandlerHelper.instrumentation_config[:inject_messaging_context] && + SUPPORTED_SERVICES.include?(service_id) + inject_context(context, client_method) + end + end + def inject_context(context, client_method) return unless SEND_MESSAGE_CLIENT_METHODS.include?(client_method) diff --git a/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/patches/telemetry.rb b/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/patches/telemetry.rb new file mode 100644 index 000000000..31bb41c39 --- /dev/null +++ b/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/patches/telemetry.rb @@ -0,0 +1,40 @@ +# frozen_string_literal: true + +# Copyright The OpenTelemetry Authors +# +# SPDX-License-Identifier: Apache-2.0 + +module OpenTelemetry + module Instrumentation + module AwsSdk + module Patches + # Patch for Telemetry Plugin Handler in V3 SDK + module Handler + def call(context) + span_wrapper(context) { @handler.call(context) } + end + + private + + def span_wrapper(context, &block) + service_id = HandlerHelper.service_id(context) + client_method = HandlerHelper.client_method(service_id, context) + context.tracer.in_span( + HandlerHelper.span_name(context, client_method, service_id), + attributes: HandlerHelper.span_attributes(context, client_method, service_id), + kind: HandlerHelper.span_kind(client_method, service_id) + ) do |span| + MessagingHelper.inject_context_if_supported(context, client_method, service_id) + + if HandlerHelper.instrumentation_config[:suppress_internal_instrumentation] + OpenTelemetry::Common::Utilities.untraced { super } + else + yield span + end + end + end + end + end + end + end +end diff --git a/instrumentation/aws_sdk/test/opentelemetry/handler_test.rb b/instrumentation/aws_sdk/test/opentelemetry/handler_test.rb new file mode 100644 index 000000000..8b178948c --- /dev/null +++ b/instrumentation/aws_sdk/test/opentelemetry/handler_test.rb @@ -0,0 +1,201 @@ +# frozen_string_literal: true + +# Copyright The OpenTelemetry Authors +# +# SPDX-License-Identifier: Apache-2.0 + +require 'test_helper' + +describe OpenTelemetry::Instrumentation::AwsSdk do + describe 'AwsSdk Plugin' do + let(:instrumentation_gem_version) do + OpenTelemetry::Instrumentation::AwsSdk::Instrumentation.instance.gem_version + end + let(:otel_semantic) { OpenTelemetry::SemanticConventions::Trace } + let(:exporter) { EXPORTER } + let(:span) { exporter.finished_spans.last } + let(:span_attrs) do + { + 'aws.region' => 'us-stubbed-1', + otel_semantic::HTTP_STATUS_CODE => 200, + otel_semantic::RPC_SYSTEM => 'aws-api' + } + end + + before do + exporter.reset + end + + describe 'Lambda' do + let(:service_name) { 'Lambda' } + let(:client) { Aws::Lambda::Client.new(stub_responses: true) } + let(:expected_attrs) do + span_attrs.tap do |attrs| + attrs[otel_semantic::RPC_METHOD] = 'ListFunctions' + attrs[otel_semantic::RPC_SERVICE] = service_name + end + end + + it 'creates a span with all the supplied parameters' do + skip if TestHelper.telemetry_plugin?(service_name) + + client.list_functions + + _(span.name).must_equal('Lambda.ListFunctions') + _(span.kind).must_equal(:client) + TestHelper.match_span_attrs(expected_attrs, span, self) + end + + it 'should have correct span attributes when error' do + skip if TestHelper.telemetry_plugin?(service_name) + + client.stub_responses(:list_functions, 'NotFound') + + begin + client.list_functions + rescue Aws::Lambda::Errors::NotFound + _(span.status.code).must_equal(2) + _(span.events[0].name).must_equal('exception') + _(span.attributes[otel_semantic::HTTP_STATUS_CODE]).must_equal(400) + end + end + end + + describe 'SNS' do + let(:service_name) { 'SNS' } + let(:client) { Aws::SNS::Client.new(stub_responses: true) } + let(:expected_attrs) do + span_attrs.tap do |attrs| + attrs[otel_semantic::RPC_METHOD] = 'Publish' + attrs[otel_semantic::RPC_SERVICE] = service_name + attrs[otel_semantic::MESSAGING_DESTINATION_KIND] = 'topic' + attrs[otel_semantic::MESSAGING_DESTINATION] = 'TopicName' + attrs[otel_semantic::MESSAGING_SYSTEM] = 'aws.sns' + end + end + + it 'creates a span with appropriate messaging attributes' do + skip if TestHelper.telemetry_plugin?(service_name) + + client.publish( + message: 'msg', + topic_arn: 'arn:aws:sns:fake:123:TopicName' + ) + + _(span.name).must_equal('TopicName publish') + _(span.kind).must_equal(:producer) + TestHelper.match_span_attrs(expected_attrs, span, self) + end + + it 'creates a span that includes a phone number' do + # skip if using aws-sdk version before phone_number supported (v2.3.18) + skip if Gem::Version.new('2.3.18') > instrumentation_gem_version + skip if TestHelper.telemetry_plugin?(service_name) + + client.publish(message: 'msg', phone_number: '123456') + + _(span.name).must_equal('phone_number publish') + _(span.attributes[otel_semantic::MESSAGING_DESTINATION]) + .must_equal('phone_number') + end + end + + describe 'SQS' do + let(:service_name) { 'SQS' } + let(:client) { Aws::SQS::Client.new(stub_responses: true) } + let(:queue_url) { 'https://sqs.fake.amazonaws.com/1/QueueName' } + let(:expected_base_attrs) do + span_attrs.tap do |attrs| + attrs[otel_semantic::RPC_SERVICE] = service_name + attrs[otel_semantic::MESSAGING_DESTINATION_KIND] = 'queue' + attrs[otel_semantic::MESSAGING_DESTINATION] = 'QueueName' + attrs[otel_semantic::MESSAGING_SYSTEM] = 'aws.sqs' + attrs[otel_semantic::MESSAGING_URL] = queue_url + end + end + + describe '#SendMessage' do + let(:expected_attrs) do + span_attrs.tap do |attrs| + attrs[otel_semantic::RPC_METHOD] = 'SendMessage' + end + end + + it 'creates a span with appropriate messaging attributes' do + skip if TestHelper.telemetry_plugin?(service_name) + + client.send_message(message_body: 'msg', queue_url: queue_url) + + _(span.name).must_equal('QueueName publish') + _(span.kind).must_equal(:producer) + TestHelper.match_span_attrs(expected_attrs, span, self) + end + end + + describe '#SendMessageBatch' do + let(:expected_attrs) do + expected_base_attrs.tap do |attrs| + attrs[otel_semantic::RPC_METHOD] = 'SendMessageBatch' + end + end + + it 'creates a span with appropriate messaging attributes' do + skip if TestHelper.telemetry_plugin?(service_name) + + client.send_message_batch( + queue_url: queue_url, + entries: [{ id: 'Message1', message_body: 'Body1' }] + ) + + _(span.name).must_equal('QueueName publish') + _(span.kind).must_equal(:producer) + TestHelper.match_span_attrs(expected_attrs, span, self) + end + end + + describe '#ReceiveMessage' do + let(:expected_attrs) do + expected_base_attrs.tap do |attrs| + attrs[otel_semantic::RPC_METHOD] = 'ReceiveMessage' + attrs[otel_semantic::MESSAGING_OPERATION] = 'receive' + end + end + + it 'creates a span with appropriate messaging attributes' do + skip if TestHelper.telemetry_plugin?(service_name) + + client.receive_message(queue_url: queue_url) + + _(span.name).must_equal('QueueName receive') + _(span.kind).must_equal(:consumer) + TestHelper.match_span_attrs(expected_attrs, span, self) + end + end + + describe '#GetQueueUrl' do + it 'creates a span with appropriate messaging attributes' do + skip if TestHelper.telemetry_plugin?(service_name) + + client.get_queue_url(queue_name: 'queue-name') + + _(span.attributes['messaging.destination']) + .must_equal('unknown') + _(span.attributes).wont_include('messaging.url') + end + end + end + + describe 'DynamoDB' do + let(:client) { Aws::DynamoDB::Client.new(stub_responses: true) } + + it 'creates a span with dynamodb-specific attribute' do + skip if TestHelper.telemetry_plugin?('DynamoDB') + + client.list_tables + + _(span.attributes[otel_semantic::DB_SYSTEM]) + .must_equal('dynamodb') + end + end + end +end diff --git a/instrumentation/aws_sdk/test/opentelemetry/instrumentation_test.rb b/instrumentation/aws_sdk/test/opentelemetry/instrumentation_test.rb index f44e81bc5..7ffe3d33f 100644 --- a/instrumentation/aws_sdk/test/opentelemetry/instrumentation_test.rb +++ b/instrumentation/aws_sdk/test/opentelemetry/instrumentation_test.rb @@ -9,8 +9,6 @@ describe OpenTelemetry::Instrumentation::AwsSdk do let(:instrumentation) { OpenTelemetry::Instrumentation::AwsSdk::Instrumentation.instance } let(:minimum_version) { OpenTelemetry::Instrumentation::AwsSdk::Instrumentation::MINIMUM_VERSION } - let(:exporter) { EXPORTER } - let(:last_span) { exporter.finished_spans.last } it 'has #name' do _(instrumentation.name).must_equal 'OpenTelemetry::Instrumentation::AwsSdk' @@ -28,12 +26,24 @@ _(instrumentation.compatible?).must_equal false end - Gem.stub(:loaded_specs, { 'aws-sdk-core' => nil, 'aws-sdk' => Gem::Specification.new { |s| s.version = '1.0.0' } }) do + Gem.stub( + :loaded_specs, + { + 'aws-sdk-core' => nil, + 'aws-sdk' => Gem::Specification.new { |s| s.version = '1.0.0' } + } + ) do hide_const('::Aws::CORE_GEM_VERSION') _(instrumentation.compatible?).must_equal false end - Gem.stub(:loaded_specs, { 'aws-sdk-core' => Gem::Specification.new { |s| s.version = '1.0.0' }, 'aws-sdk' => nil }) do + Gem.stub( + :loaded_specs, + { + 'aws-sdk-core' => Gem::Specification.new { |s| s.version = '1.0.0' }, + 'aws-sdk' => nil + } + ) do hide_const('::Aws::CORE_GEM_VERSION') _(instrumentation.compatible?).must_equal false end @@ -55,216 +65,4 @@ instrumentation.instance_variable_set(:@installed, false) end end - - describe 'validate_spans' do - describe 'SNS' do - it 'should have correct attributes' do - sns = Aws::SNS::Client.new(stub_responses: true) - sns.stub_responses(:publish) - - sns.publish message: 'msg' - - _(last_span.attributes['rpc.system']).must_equal 'aws-api' - _(last_span.attributes['rpc.service']).must_equal 'SNS' - _(last_span.attributes['rpc.method']).must_equal 'Publish' - _(last_span.attributes['aws.region']).must_include 'stubbed' - _(last_span.attributes['db.system']).must_be_nil - - _(last_span.attributes[OpenTelemetry::SemanticConventions::Trace::HTTP_STATUS_CODE]).must_equal 200 - - _(last_span.status.code).must_equal OpenTelemetry::Trace::Status::UNSET - end - end - - describe 'S3' do - it 'should have correct attributes when success' do - s3 = Aws::S3::Client.new(stub_responses: { list_buckets: { buckets: [{ name: 'bucket1' }] } }) - - s3.list_buckets - - _(last_span.attributes['rpc.system']).must_equal 'aws-api' - _(last_span.attributes['rpc.service']).must_equal 'S3' - _(last_span.attributes['rpc.method']).must_equal 'ListBuckets' - _(last_span.attributes['aws.region']).must_include 'stubbed' - _(last_span.attributes['db.system']).must_be_nil - - _(last_span.attributes[OpenTelemetry::SemanticConventions::Trace::HTTP_STATUS_CODE]).must_equal 200 - - _(last_span.status.code).must_equal OpenTelemetry::Trace::Status::UNSET - end - - it 'should have correct attributes when error' do - s3 = Aws::S3::Client.new(stub_responses: true) - s3.stub_responses(:list_buckets, 'NotFound') - - begin - s3.list_buckets - rescue StandardError - _(last_span.attributes['rpc.system']).must_equal 'aws-api' - _(last_span.attributes['rpc.service']).must_equal 'S3' - _(last_span.attributes['rpc.method']).must_equal 'ListBuckets' - _(last_span.attributes['aws.region']).must_include 'stubbed' - _(last_span.attributes['db.system']).must_be_nil - end - - _(last_span.attributes[OpenTelemetry::SemanticConventions::Trace::HTTP_STATUS_CODE]).must_equal 400 - - _(last_span.status.code).must_equal OpenTelemetry::Trace::Status::ERROR - end - end - - describe 'dynamodb' do - it 'should have db.system attribute' do - dynamodb_client = Aws::DynamoDB::Client.new(stub_responses: true) - - dynamodb_client.list_tables - - _(last_span.attributes['rpc.system']).must_equal 'aws-api' - _(last_span.attributes['db.system']).must_equal 'dynamodb' - - _(last_span.attributes[OpenTelemetry::SemanticConventions::Trace::HTTP_STATUS_CODE]).must_equal 200 - end - end - - describe 'sqs' do - it 'should have messaging attributes for send_message' do - sqs_client = Aws::SQS::Client.new(stub_responses: true) - - sqs_client.send_message message_body: 'msg', queue_url: 'https://sqs.fake.amazonaws.com/1/queue-name' - - _(last_span.attributes['rpc.system']).must_equal 'aws-api' - _(last_span.attributes['messaging.system']).must_equal 'aws.sqs' - _(last_span.attributes['messaging.destination_kind']).must_equal 'queue' - _(last_span.attributes['messaging.destination']).must_equal 'queue-name' - _(last_span.attributes['messaging.url']).must_equal 'https://sqs.fake.amazonaws.com/1/queue-name' - end - - it 'should have messaging attributes for send_message_batch' do - sqs_client = Aws::SQS::Client.new(stub_responses: true) - - entries = [ - { - id: 'Message1', - message_body: 'This is the first message.' - }, - { - id: 'Message2', - message_body: 'This is the second message.', - message_attributes: { - attr1: { - data_type: 'String', - string_value: 'value1' - } - } - } - ] - - sqs_client.send_message_batch( - queue_url: 'https://sqs.fake.amazonaws.com/1/queue-name', - entries: entries - ) - - _(last_span.attributes['rpc.system']).must_equal 'aws-api' - _(last_span.attributes['messaging.system']).must_equal 'aws.sqs' - _(last_span.attributes['messaging.destination_kind']).must_equal 'queue' - _(last_span.attributes['messaging.destination']).must_equal 'queue-name' - _(last_span.attributes['messaging.url']).must_equal 'https://sqs.fake.amazonaws.com/1/queue-name' - end - - it 'should have messaging attributes for get_queue_url' do - sqs_client = Aws::SQS::Client.new(stub_responses: true) - - sqs_client.get_queue_url queue_name: 'queue-name' - - _(last_span.attributes['rpc.system']).must_equal 'aws-api' - _(last_span.attributes['messaging.system']).must_equal 'aws.sqs' - _(last_span.attributes['messaging.destination_kind']).must_equal 'queue' - _(last_span.attributes['messaging.destination']).must_equal 'unknown' - _(last_span.attributes).wont_include('messaging.url') - end - end - - describe 'sns' do - it 'should have messaging attributes for publish' do - sns_client = Aws::SNS::Client.new(stub_responses: true) - - sns_client.publish message: 'msg', topic_arn: 'arn:aws:sns:fake:123:topic-name' - - _(last_span.attributes['rpc.system']).must_equal 'aws-api' - _(last_span.attributes['messaging.system']).must_equal 'aws.sns' - _(last_span.attributes['messaging.destination_kind']).must_equal 'topic' - _(last_span.attributes['messaging.destination']).must_equal 'topic-name' - end - - it 'should handle phone numbers' do - # skip if using aws-sdk version before phone_number supported (v2.3.18) - return if Gem::Version.new('2.3.18') > instrumentation.gem_version - - sns_client = Aws::SNS::Client.new(stub_responses: true) - - sns_client.publish message: 'msg', phone_number: '123456' - - _(last_span.attributes['messaging.destination']).must_equal 'phone_number' - _(last_span.name).must_equal 'phone_number publish' - end - end - end - - describe 'MessageAttributeSetter' do - it 'set when hash length is lower than 10' do - key = 'foo' - value = 'bar' - metadata_attributes = {} - OpenTelemetry::Instrumentation::AwsSdk::MessageAttributeSetter.set(metadata_attributes, key, value) - _(metadata_attributes[key]).must_equal(string_value: value, data_type: 'String') - end - - it 'should keep existing attributes' do - key = 'foo' - value = 'bar' - metadata_attributes = { - 'existingKey' => { string_value: 'existingValue', data_type: 'String' } - } - OpenTelemetry::Instrumentation::AwsSdk::MessageAttributeSetter.set(metadata_attributes, key, value) - _(metadata_attributes[key]).must_equal(string_value: value, data_type: 'String') - _(metadata_attributes['existingKey']).must_equal(string_value: 'existingValue', data_type: 'String') - end - - it 'should not add if there are 10 or more existing attributes' do - metadata_attributes = { - 'existingKey0' => { string_value: 'existingValue', data_type: 'String' }, - 'existingKey1' => { string_value: 'existingValue', data_type: 'String' }, - 'existingKey2' => { string_value: 'existingValue', data_type: 'String' }, - 'existingKey3' => { string_value: 'existingValue', data_type: 'String' }, - 'existingKey4' => { string_value: 'existingValue', data_type: 'String' }, - 'existingKey5' => { string_value: 'existingValue', data_type: 'String' }, - 'existingKey6' => { string_value: 'existingValue', data_type: 'String' }, - 'existingKey7' => { string_value: 'existingValue', data_type: 'String' }, - 'existingKey8' => { string_value: 'existingValue', data_type: 'String' }, - 'existingKey9' => { string_value: 'existingValue', data_type: 'String' } - } - OpenTelemetry::Instrumentation::AwsSdk::MessageAttributeSetter.set(metadata_attributes, 'new10', 'value') - _(metadata_attributes.keys).must_equal(%w[existingKey0 existingKey1 existingKey2 existingKey3 existingKey4 existingKey5 existingKey6 existingKey7 existingKey8 existingKey9]) - end - - describe 'MessageAttributeGetter' do - let(:getter) { OpenTelemetry::Instrumentation::AwsSdk::MessageAttributeGetter } - let(:carrier) do - { - 'traceparent' => { data_type: 'String', string_value: 'tp' }, - 'tracestate' => { data_type: 'String', string_value: 'ts' }, - 'x-source-id' => { data_type: 'String', string_value: '123' } - } - end - - it 'reads key from carrier' do - _(getter.get(carrier, 'traceparent')).must_equal('tp') - _(getter.get(carrier, 'x-source-id')).must_equal('123') - end - - it 'returns nil for non-existant key' do - _(getter.get(carrier, 'not-here')).must_be_nil - end - end - end end diff --git a/instrumentation/aws_sdk/test/opentelemetry/message_attributes_test.rb b/instrumentation/aws_sdk/test/opentelemetry/message_attributes_test.rb new file mode 100644 index 000000000..1d3486399 --- /dev/null +++ b/instrumentation/aws_sdk/test/opentelemetry/message_attributes_test.rb @@ -0,0 +1,84 @@ +# frozen_string_literal: true + +# Copyright The OpenTelemetry Authors +# +# SPDX-License-Identifier: Apache-2.0 + +require 'test_helper' + +describe OpenTelemetry::Instrumentation::AwsSdk do + let(:instrumentation) { OpenTelemetry::Instrumentation::AwsSdk } + + describe 'MessageAttributeSetter' do + it 'set when hash length is lower than 10' do + key = 'foo' + value = 'bar' + metadata_attributes = {} + instrumentation::MessageAttributeSetter.set(metadata_attributes, key, value) + _(metadata_attributes[key]).must_equal(string_value: value, data_type: 'String') + end + + it 'should keep existing attributes' do + key = 'foo' + value = 'bar' + metadata_attributes = { + 'existingKey' => { string_value: 'existingValue', data_type: 'String' } + } + instrumentation::MessageAttributeSetter.set(metadata_attributes, key, value) + _(metadata_attributes[key]).must_equal(string_value: value, data_type: 'String') + _(metadata_attributes['existingKey']) + .must_equal(string_value: 'existingValue', data_type: 'String') + end + + it 'should not add if there are 10 or more existing attributes' do + metadata_attributes = { + 'existingKey0' => { string_value: 'existingValue', data_type: 'String' }, + 'existingKey1' => { string_value: 'existingValue', data_type: 'String' }, + 'existingKey2' => { string_value: 'existingValue', data_type: 'String' }, + 'existingKey3' => { string_value: 'existingValue', data_type: 'String' }, + 'existingKey4' => { string_value: 'existingValue', data_type: 'String' }, + 'existingKey5' => { string_value: 'existingValue', data_type: 'String' }, + 'existingKey6' => { string_value: 'existingValue', data_type: 'String' }, + 'existingKey7' => { string_value: 'existingValue', data_type: 'String' }, + 'existingKey8' => { string_value: 'existingValue', data_type: 'String' }, + 'existingKey9' => { string_value: 'existingValue', data_type: 'String' } + } + instrumentation::MessageAttributeSetter.set(metadata_attributes, 'new10', 'value') + _(metadata_attributes.keys) + .must_equal( + %w[ + existingKey0 + existingKey1 + existingKey2 + existingKey3 + existingKey4 + existingKey5 + existingKey6 + existingKey7 + existingKey8 + existingKey9 + ] + ) + end + end + + describe 'MessageAttributeGetter' do + let(:getter) { instrumentation::MessageAttributeGetter } + let(:carrier) do + { + 'traceparent' => { data_type: 'String', string_value: 'tp' }, + 'tracestate' => { data_type: 'String', string_value: 'ts' }, + 'x-source-id' => { data_type: 'String', string_value: '123' } + } + end + + it 'reads key from carrier' do + _(getter.get(carrier, 'traceparent')).must_equal('tp') + _(getter.get(carrier, 'x-source-id')).must_equal('123') + end + + it 'returns nil for non-existant key' do + _(getter.get(carrier, 'not-here')).must_be_nil + end + end +end diff --git a/instrumentation/aws_sdk/test/opentelemetry/patches/telemetry_test.rb b/instrumentation/aws_sdk/test/opentelemetry/patches/telemetry_test.rb new file mode 100644 index 000000000..55fd83886 --- /dev/null +++ b/instrumentation/aws_sdk/test/opentelemetry/patches/telemetry_test.rb @@ -0,0 +1,297 @@ +# frozen_string_literal: true + +# Copyright The OpenTelemetry Authors +# +# SPDX-License-Identifier: Apache-2.0 + +require_relative '../../test_helper' + +describe OpenTelemetry::Instrumentation::AwsSdk do + describe 'Telemetry plugin' do + let(:instrumentation_gem_version) do + OpenTelemetry::Instrumentation::AwsSdk::Instrumentation.instance.gem_version + end + let(:otel_semantic) { OpenTelemetry::SemanticConventions::Trace } + let(:exporter) { EXPORTER } + let(:spans) { exporter.finished_spans } + let(:otel_provider) { Aws::Telemetry::OTelProvider.new } + let(:stub_span) { spans.find { |s| s.name == 'Handler.StubResponses' } } + let(:client_attrs) do + { + 'aws.region' => 'us-stubbed-1', + otel_semantic::CODE_NAMESPACE => 'Aws::Plugins::Telemetry', + otel_semantic::RPC_SYSTEM => 'aws-api' + } + end + + let(:stub_attrs) do + { + 'http.status_code' => '200', + 'net.protocol.name' => 'http', + 'net.protocol.version' => '1.1' + } + end + + before do + exporter.reset + end + + describe 'Lambda' do + let(:service_name) { 'Lambda' } + let(:service_uri) do + 'https://lambda.us-east-1.amazonaws.com/2015-03-31/functions/' + end + let(:client) do + Aws::Lambda::Client.new( + telemetry_provider: otel_provider, + stub_responses: true + ) + end + let(:client_span) { spans.find { |s| s.name == 'Lambda.ListFunctions' } } + let(:internal_span) { spans.find { |s| s.name == 'Handler.NetHttp' } } + + let(:expected_client_attrs) do + client_attrs.tap do |attrs| + attrs[otel_semantic::CODE_FUNCTION] = 'list_functions' + attrs[otel_semantic::RPC_METHOD] = 'ListFunctions' + attrs[otel_semantic::RPC_SERVICE] = service_name + end + end + + let(:expected_stub_attrs) { stub_attrs.tap { |a| a['http.method'] = 'GET' } } + + let(:expected_internal_attrs) do + stub_attrs.tap do |attrs| + attrs['net.peer.name'] = 'lambda.us-east-1.amazonaws.com' + attrs['net.peer.port'] = '443' + end + end + + it 'creates spans with all the supplied parameters' do + skip unless TestHelper.telemetry_plugin?(service_name) + client.list_functions + + _(client_span.name).must_equal('Lambda.ListFunctions') + _(stub_span.name).must_equal('Handler.StubResponses') + _(client_span.kind).must_equal(:client) + _(stub_span.kind).must_equal(:internal) + TestHelper.match_span_attrs(expected_client_attrs, client_span, self) + TestHelper.match_span_attrs(expected_stub_attrs, stub_span, self) + _(stub_span.parent_span_id).must_equal(client_span.span_id) + end + + it 'creates spans with all the non-stubbed parameters' do + skip unless TestHelper.telemetry_plugin?(service_name) + stub_request(:get, 'https://lambda.us-east-1.amazonaws.com/2015-03-31/functions/') + + client = Aws::Lambda::Client.new( + telemetry_provider: otel_provider, + credentials: Aws::Credentials.new('akid', 'secret'), + region: 'us-east-1' + ) + client.list_functions + + _(client_span.name).must_equal('Lambda.ListFunctions') + _(internal_span.name).must_equal('Handler.NetHttp') + _(client_span.kind).must_equal(:client) + _(internal_span.kind).must_equal(:internal) + _(client_span.attributes['aws.region']).must_equal('us-east-1') + TestHelper.match_span_attrs(expected_internal_attrs, internal_span, self) + end + + it 'should have correct span attributes when error' do + skip unless TestHelper.telemetry_plugin?(service_name) + stub_request(:get, 'foo').to_return(status: 400) + + begin + client.list_functions + rescue Aws::Lambda::Errors::BadRequest + _(client_span.status.code).must_equal(2) + _(client_span.events[0].name).must_equal('exception') + _(internal_span.attributes['http.status_code']).must_equal('400') + end + end + end + + describe 'SNS' do + let(:service_name) { 'SNS' } + let(:client) do + Aws::SNS::Client.new( + telemetry_provider: otel_provider, + stub_responses: true + ) + end + let(:client_span) { spans.find { |s| s.name.include?('SNS.Publish') } } + + let(:expected_client_attrs) do + client_attrs.tap do |attrs| + attrs[otel_semantic::CODE_FUNCTION] = 'publish' + attrs[otel_semantic::RPC_METHOD] = 'Publish' + attrs[otel_semantic::RPC_SERVICE] = service_name + attrs[otel_semantic::MESSAGING_DESTINATION_KIND] = 'topic' + attrs[otel_semantic::MESSAGING_DESTINATION] = 'TopicName' + attrs[otel_semantic::MESSAGING_SYSTEM] = 'aws.sns' + end + end + + let(:expected_stub_attrs) { stub_attrs.tap { |a| a['http.method'] = 'POST' } } + + it 'creates spans with appropriate messaging attributes' do + skip unless TestHelper.telemetry_plugin?(service_name) + + client.publish( + message: 'msg', + topic_arn: 'arn:aws:sns:fake:123:TopicName' + ) + + _(client_span.name).must_equal('SNS.Publish.TopicName.Publish') + _(client_span.kind).must_equal(:producer) + _(stub_span.name).must_equal('Handler.StubResponses') + _(stub_span.kind).must_equal(:internal) + TestHelper.match_span_attrs(expected_client_attrs, client_span, self) + TestHelper.match_span_attrs(expected_stub_attrs, stub_span, self) + _(stub_span.parent_span_id).must_equal(client_span.span_id) + end + + it 'creates a span that includes a phone number' do + # skip if using aws-sdk version before phone_number supported (v2.3.18) + skip if Gem::Version.new('2.3.18') > instrumentation_gem_version + skip unless TestHelper.telemetry_plugin?(service_name) + + client.publish(message: 'msg', phone_number: '123456') + + _(client_span.name).must_equal('SNS.Publish.phone_number.Publish') + _(client_span.attributes[otel_semantic::MESSAGING_DESTINATION]) + .must_equal('phone_number') + end + end + + describe 'SQS' do + let(:service_name) { 'SQS' } + let(:client) do + Aws::SQS::Client.new( + telemetry_provider: otel_provider, + stub_responses: true + ) + end + let(:queue_url) { 'https://sqs.us-east-1.amazonaws.com/1/QueueName' } + let(:expected_client_base_attrs) do + client_attrs.tap do |attrs| + attrs[otel_semantic::RPC_SERVICE] = service_name + attrs[otel_semantic::MESSAGING_DESTINATION_KIND] = 'queue' + attrs[otel_semantic::MESSAGING_DESTINATION] = 'QueueName' + attrs[otel_semantic::MESSAGING_SYSTEM] = 'aws.sqs' + attrs[otel_semantic::MESSAGING_URL] = queue_url + end + end + + let(:expected_stub_attrs) { stub_attrs.tap { |a| a['http.method'] = 'POST' } } + + describe '#SendMessage' do + let(:client_span) { spans.find { |s| s.name.include?('SQS.SendMessage') } } + let(:expected_client_attrs) do + expected_client_base_attrs.tap do |attrs| + attrs[otel_semantic::RPC_METHOD] = 'SendMessage' + end + end + + it 'creates spans with appropriate messaging attributes' do + skip unless TestHelper.telemetry_plugin?(service_name) + + client.send_message(message_body: 'msg', queue_url: queue_url) + + _(client_span.name).must_equal('SQS.SendMessage.QueueName.Publish') + _(client_span.kind).must_equal(:producer) + _(stub_span.name).must_equal('Handler.StubResponses') + _(stub_span.kind).must_equal(:internal) + TestHelper.match_span_attrs(expected_client_attrs, client_span, self) + TestHelper.match_span_attrs(expected_stub_attrs, stub_span, self) + _(stub_span.parent_span_id).must_equal(client_span.span_id) + end + end + + describe '#SendMessageBatch' do + let(:client_span) { spans.find { |s| s.name.include?('SQS.SendMessageBatch') } } + let(:expected_client_attrs) do + expected_client_base_attrs.tap do |attrs| + attrs[otel_semantic::RPC_METHOD] = 'SendMessageBatch' + end + end + + it 'creates spans with appropriate messaging attributes' do + skip unless TestHelper.telemetry_plugin?(service_name) + + client.send_message_batch( + queue_url: queue_url, + entries: [{ id: 'Message1', message_body: 'Body1' }] + ) + + _(client_span.name).must_equal('SQS.SendMessageBatch.QueueName.Publish') + _(client_span.kind).must_equal(:producer) + _(stub_span.name).must_equal('Handler.StubResponses') + _(stub_span.kind).must_equal(:internal) + TestHelper.match_span_attrs(expected_client_attrs, client_span, self) + TestHelper.match_span_attrs(expected_stub_attrs, stub_span, self) + _(stub_span.parent_span_id).must_equal(client_span.span_id) + end + end + + describe '#ReceiveMessage' do + let(:client_span) { spans.find { |s| s.name.include?('SQS.ReceiveMessage') } } + let(:expected_client_attrs) do + expected_client_base_attrs.tap do |attrs| + attrs[otel_semantic::RPC_METHOD] = 'ReceiveMessage' + attrs[otel_semantic::MESSAGING_OPERATION] = 'receive' + end + end + + it 'creates spans with appropriate messaging attributes' do + skip unless TestHelper.telemetry_plugin?(service_name) + + client.receive_message(queue_url: queue_url) + + _(client_span.name).must_equal('SQS.ReceiveMessage.QueueName.Receive') + _(client_span.kind).must_equal(:consumer) + _(stub_span.name).must_equal('Handler.StubResponses') + _(stub_span.kind).must_equal(:internal) + TestHelper.match_span_attrs(expected_client_attrs, client_span, self) + TestHelper.match_span_attrs(expected_stub_attrs, stub_span, self) + _(stub_span.parent_span_id).must_equal(client_span.span_id) + end + end + + describe '#GetQueueUrl' do + let(:client_span) { spans.find { |s| s.name.include?('SQS.GetQueueUrl') } } + + it 'creates a span with appropriate messaging attributes' do + skip unless TestHelper.telemetry_plugin?(service_name) + + client.get_queue_url(queue_name: 'queue-name') + + _(client_span.attributes[otel_semantic::MESSAGING_DESTINATION]).must_equal('unknown') + _(client_span.attributes).wont_include(otel_semantic::MESSAGING_URL) + end + end + end + + describe 'DynamoDB' do + let(:client) do + Aws::DynamoDB::Client.new( + telemetry_provider: otel_provider, + stub_responses: true + ) + end + let(:client_span) { TestHelper.find_span(spans, 'DynamoDB.ListTables') } + let(:client_span) { spans.find { |s| s.name == 'DynamoDB.ListTables' } } + + it 'creates a span with dynamodb-specific attribute' do + skip unless TestHelper.telemetry_plugin?('DynamoDB') + + client.list_tables + + _(client_span.attributes[otel_semantic::DB_SYSTEM]) + .must_equal('dynamodb') + end + end + end +end diff --git a/instrumentation/aws_sdk/test/test_helper.rb b/instrumentation/aws_sdk/test/test_helper.rb index 7153e99b2..b588f8c75 100644 --- a/instrumentation/aws_sdk/test/test_helper.rb +++ b/instrumentation/aws_sdk/test/test_helper.rb @@ -10,6 +10,7 @@ require 'opentelemetry-instrumentation-aws_sdk' require 'minitest/autorun' +require 'webmock/minitest' require 'rspec/mocks/minitest_integration' # global opentelemetry-sdk setup: @@ -22,3 +23,19 @@ c.use 'OpenTelemetry::Instrumentation::AwsSdk' c.add_span_processor span_processor end + +class TestHelper + class << self + def telemetry_plugin?(service) + m = ::Aws.const_get(service).const_get(:Client) + Aws.const_defined?('Plugins::Telemetry') && + m.plugins.include?(Aws::Plugins::Telemetry) + end + + def match_span_attrs(expected_attrs, span, expect) + expected_attrs.each do |key, value| + expect._(span.attributes[key]).must_equal(value) + end + end + end +end From 7856eaeb7c2a9ad10d7f1d15987660cb5e75041e Mon Sep 17 00:00:00 2001 From: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com> Date: Mon, 7 Oct 2024 15:52:13 -0700 Subject: [PATCH 28/58] chore: Update rubocop-performance to 1.22.0 (#1189) --- helpers/mysql/opentelemetry-helpers-mysql.gemspec | 2 +- .../opentelemetry-helpers-sql-obfuscation.gemspec | 2 +- .../opentelemetry-instrumentation-action_mailer.gemspec | 2 +- .../opentelemetry-instrumentation-action_pack.gemspec | 2 +- .../opentelemetry-instrumentation-action_view.gemspec | 2 +- .../active_job/opentelemetry-instrumentation-active_job.gemspec | 2 +- ...entelemetry-instrumentation-active_model_serializers.gemspec | 2 +- .../opentelemetry-instrumentation-active_record.gemspec | 2 +- .../opentelemetry-instrumentation-active_support.gemspec | 2 +- instrumentation/all/opentelemetry-instrumentation-all.gemspec | 2 +- .../aws_lambda/opentelemetry-instrumentation-aws_lambda.gemspec | 2 +- .../aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec | 2 +- instrumentation/base/opentelemetry-instrumentation-base.gemspec | 2 +- .../bunny/opentelemetry-instrumentation-bunny.gemspec | 2 +- .../opentelemetry-instrumentation-concurrent_ruby.gemspec | 2 +- .../dalli/opentelemetry-instrumentation-dalli.gemspec | 2 +- .../opentelemetry-instrumentation-delayed_job.gemspec | 2 +- .../ethon/opentelemetry-instrumentation-ethon.gemspec | 2 +- .../excon/opentelemetry-instrumentation-excon.gemspec | 2 +- .../faraday/opentelemetry-instrumentation-faraday.gemspec | 2 +- .../grape/opentelemetry-instrumentation-grape.gemspec | 2 +- .../graphql/opentelemetry-instrumentation-graphql.gemspec | 2 +- instrumentation/gruf/opentelemetry-instrumentation-gruf.gemspec | 2 +- instrumentation/http/opentelemetry-instrumentation-http.gemspec | 2 +- .../opentelemetry-instrumentation-http_client.gemspec | 2 +- .../httpx/opentelemetry-instrumentation-httpx.gemspec | 2 +- .../koala/opentelemetry-instrumentation-koala.gemspec | 2 +- instrumentation/lmdb/opentelemetry-instrumentation-lmdb.gemspec | 2 +- .../mongo/opentelemetry-instrumentation-mongo.gemspec | 2 +- .../mysql2/opentelemetry-instrumentation-mysql2.gemspec | 2 +- .../net_http/opentelemetry-instrumentation-net_http.gemspec | 2 +- instrumentation/pg/opentelemetry-instrumentation-pg.gemspec | 2 +- instrumentation/que/opentelemetry-instrumentation-que.gemspec | 2 +- .../racecar/opentelemetry-instrumentation-racecar.gemspec | 2 +- instrumentation/rack/opentelemetry-instrumentation-rack.gemspec | 2 +- .../rails/opentelemetry-instrumentation-rails.gemspec | 2 +- instrumentation/rake/opentelemetry-instrumentation-rake.gemspec | 2 +- .../rdkafka/opentelemetry-instrumentation-rdkafka.gemspec | 2 +- .../redis/opentelemetry-instrumentation-redis.gemspec | 2 +- .../resque/opentelemetry-instrumentation-resque.gemspec | 2 +- .../restclient/opentelemetry-instrumentation-restclient.gemspec | 2 +- .../rspec/opentelemetry-instrumentation-rspec.gemspec | 2 +- .../ruby_kafka/opentelemetry-instrumentation-ruby_kafka.gemspec | 2 +- .../sidekiq/opentelemetry-instrumentation-sidekiq.gemspec | 2 +- .../sinatra/opentelemetry-instrumentation-sinatra.gemspec | 2 +- .../trilogy/opentelemetry-instrumentation-trilogy.gemspec | 2 +- processor/baggage/opentelemetry-processor-baggage.gemspec | 2 +- propagator/ottrace/opentelemetry-propagator-ottrace.gemspec | 2 +- propagator/vitess/opentelemetry-propagator-vitess.gemspec | 2 +- propagator/xray/opentelemetry-propagator-xray.gemspec | 2 +- resources/azure/opentelemetry-resource-detector-azure.gemspec | 2 +- .../container/opentelemetry-resource-detector-container.gemspec | 2 +- ...pentelemetry-resource-detector-google_cloud_platform.gemspec | 2 +- 53 files changed, 53 insertions(+), 53 deletions(-) diff --git a/helpers/mysql/opentelemetry-helpers-mysql.gemspec b/helpers/mysql/opentelemetry-helpers-mysql.gemspec index 5cebc24d6..5279d529c 100644 --- a/helpers/mysql/opentelemetry-helpers-mysql.gemspec +++ b/helpers/mysql/opentelemetry-helpers-mysql.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.21.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'yard', '~> 0.9' spec.add_development_dependency 'yard-doctest', '~> 0.1.6' diff --git a/helpers/sql-obfuscation/opentelemetry-helpers-sql-obfuscation.gemspec b/helpers/sql-obfuscation/opentelemetry-helpers-sql-obfuscation.gemspec index 1ce168184..1b1ee1906 100644 --- a/helpers/sql-obfuscation/opentelemetry-helpers-sql-obfuscation.gemspec +++ b/helpers/sql-obfuscation/opentelemetry-helpers-sql-obfuscation.gemspec @@ -32,7 +32,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.21.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'yard', '~> 0.9' spec.add_development_dependency 'yard-doctest', '~> 0.1.6' diff --git a/instrumentation/action_mailer/opentelemetry-instrumentation-action_mailer.gemspec b/instrumentation/action_mailer/opentelemetry-instrumentation-action_mailer.gemspec index 2a00a1534..79f869aa5 100644 --- a/instrumentation/action_mailer/opentelemetry-instrumentation-action_mailer.gemspec +++ b/instrumentation/action_mailer/opentelemetry-instrumentation-action_mailer.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/action_pack/opentelemetry-instrumentation-action_pack.gemspec b/instrumentation/action_pack/opentelemetry-instrumentation-action_pack.gemspec index 27745ffac..05da75032 100644 --- a/instrumentation/action_pack/opentelemetry-instrumentation-action_pack.gemspec +++ b/instrumentation/action_pack/opentelemetry-instrumentation-action_pack.gemspec @@ -37,7 +37,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rails', '>= 6.1' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/action_view/opentelemetry-instrumentation-action_view.gemspec b/instrumentation/action_view/opentelemetry-instrumentation-action_view.gemspec index 79685ab32..d7fd65f0d 100644 --- a/instrumentation/action_view/opentelemetry-instrumentation-action_view.gemspec +++ b/instrumentation/action_view/opentelemetry-instrumentation-action_view.gemspec @@ -37,7 +37,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rails', '>= 6.1' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/active_job/opentelemetry-instrumentation-active_job.gemspec b/instrumentation/active_job/opentelemetry-instrumentation-active_job.gemspec index 974244bd7..9653e2d85 100644 --- a/instrumentation/active_job/opentelemetry-instrumentation-active_job.gemspec +++ b/instrumentation/active_job/opentelemetry-instrumentation-active_job.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/active_model_serializers/opentelemetry-instrumentation-active_model_serializers.gemspec b/instrumentation/active_model_serializers/opentelemetry-instrumentation-active_model_serializers.gemspec index 315ab5e41..ab8be88b4 100644 --- a/instrumentation/active_model_serializers/opentelemetry-instrumentation-active_model_serializers.gemspec +++ b/instrumentation/active_model_serializers/opentelemetry-instrumentation-active_model_serializers.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/active_record/opentelemetry-instrumentation-active_record.gemspec b/instrumentation/active_record/opentelemetry-instrumentation-active_record.gemspec index 29eeab35d..b3d4dfb17 100644 --- a/instrumentation/active_record/opentelemetry-instrumentation-active_record.gemspec +++ b/instrumentation/active_record/opentelemetry-instrumentation-active_record.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/active_support/opentelemetry-instrumentation-active_support.gemspec b/instrumentation/active_support/opentelemetry-instrumentation-active_support.gemspec index e692985f1..1c906197d 100644 --- a/instrumentation/active_support/opentelemetry-instrumentation-active_support.gemspec +++ b/instrumentation/active_support/opentelemetry-instrumentation-active_support.gemspec @@ -40,7 +40,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/all/opentelemetry-instrumentation-all.gemspec b/instrumentation/all/opentelemetry-instrumentation-all.gemspec index 6434734c9..3a4d35cd8 100644 --- a/instrumentation/all/opentelemetry-instrumentation-all.gemspec +++ b/instrumentation/all/opentelemetry-instrumentation-all.gemspec @@ -67,7 +67,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/aws_lambda/opentelemetry-instrumentation-aws_lambda.gemspec b/instrumentation/aws_lambda/opentelemetry-instrumentation-aws_lambda.gemspec index 79937f592..c11c8f653 100644 --- a/instrumentation/aws_lambda/opentelemetry-instrumentation-aws_lambda.gemspec +++ b/instrumentation/aws_lambda/opentelemetry-instrumentation-aws_lambda.gemspec @@ -37,7 +37,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.19.1' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec b/instrumentation/aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec index 6562625c6..84328e3ef 100644 --- a/instrumentation/aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec +++ b/instrumentation/aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec @@ -38,7 +38,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/base/opentelemetry-instrumentation-base.gemspec b/instrumentation/base/opentelemetry-instrumentation-base.gemspec index 97da5f64f..4933ab7c4 100644 --- a/instrumentation/base/opentelemetry-instrumentation-base.gemspec +++ b/instrumentation/base/opentelemetry-instrumentation-base.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/bunny/opentelemetry-instrumentation-bunny.gemspec b/instrumentation/bunny/opentelemetry-instrumentation-bunny.gemspec index 9f94081f0..6fe7ea968 100644 --- a/instrumentation/bunny/opentelemetry-instrumentation-bunny.gemspec +++ b/instrumentation/bunny/opentelemetry-instrumentation-bunny.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/concurrent_ruby/opentelemetry-instrumentation-concurrent_ruby.gemspec b/instrumentation/concurrent_ruby/opentelemetry-instrumentation-concurrent_ruby.gemspec index 539887b96..c7c3cfd75 100644 --- a/instrumentation/concurrent_ruby/opentelemetry-instrumentation-concurrent_ruby.gemspec +++ b/instrumentation/concurrent_ruby/opentelemetry-instrumentation-concurrent_ruby.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/dalli/opentelemetry-instrumentation-dalli.gemspec b/instrumentation/dalli/opentelemetry-instrumentation-dalli.gemspec index 08405e804..6ac5395a2 100644 --- a/instrumentation/dalli/opentelemetry-instrumentation-dalli.gemspec +++ b/instrumentation/dalli/opentelemetry-instrumentation-dalli.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/delayed_job/opentelemetry-instrumentation-delayed_job.gemspec b/instrumentation/delayed_job/opentelemetry-instrumentation-delayed_job.gemspec index 8007aec82..06c73c930 100644 --- a/instrumentation/delayed_job/opentelemetry-instrumentation-delayed_job.gemspec +++ b/instrumentation/delayed_job/opentelemetry-instrumentation-delayed_job.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'sqlite3' spec.add_development_dependency 'webmock', '~> 3.19' diff --git a/instrumentation/ethon/opentelemetry-instrumentation-ethon.gemspec b/instrumentation/ethon/opentelemetry-instrumentation-ethon.gemspec index b5b90f5d4..2a4aa2ab1 100644 --- a/instrumentation/ethon/opentelemetry-instrumentation-ethon.gemspec +++ b/instrumentation/ethon/opentelemetry-instrumentation-ethon.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/excon/opentelemetry-instrumentation-excon.gemspec b/instrumentation/excon/opentelemetry-instrumentation-excon.gemspec index 18c3f82ba..45c42b778 100644 --- a/instrumentation/excon/opentelemetry-instrumentation-excon.gemspec +++ b/instrumentation/excon/opentelemetry-instrumentation-excon.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/faraday/opentelemetry-instrumentation-faraday.gemspec b/instrumentation/faraday/opentelemetry-instrumentation-faraday.gemspec index f08ff6576..8b3f7c740 100644 --- a/instrumentation/faraday/opentelemetry-instrumentation-faraday.gemspec +++ b/instrumentation/faraday/opentelemetry-instrumentation-faraday.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/grape/opentelemetry-instrumentation-grape.gemspec b/instrumentation/grape/opentelemetry-instrumentation-grape.gemspec index 86306cddb..93f61389c 100644 --- a/instrumentation/grape/opentelemetry-instrumentation-grape.gemspec +++ b/instrumentation/grape/opentelemetry-instrumentation-grape.gemspec @@ -39,7 +39,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/graphql/opentelemetry-instrumentation-graphql.gemspec b/instrumentation/graphql/opentelemetry-instrumentation-graphql.gemspec index 36aec82c3..10a53ce3f 100644 --- a/instrumentation/graphql/opentelemetry-instrumentation-graphql.gemspec +++ b/instrumentation/graphql/opentelemetry-instrumentation-graphql.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/gruf/opentelemetry-instrumentation-gruf.gemspec b/instrumentation/gruf/opentelemetry-instrumentation-gruf.gemspec index bff04dd3e..4afb14290 100644 --- a/instrumentation/gruf/opentelemetry-instrumentation-gruf.gemspec +++ b/instrumentation/gruf/opentelemetry-instrumentation-gruf.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers' spec.add_development_dependency 'rake', '~> 12.3.3' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/http/opentelemetry-instrumentation-http.gemspec b/instrumentation/http/opentelemetry-instrumentation-http.gemspec index 54069ff29..38b45dc2e 100644 --- a/instrumentation/http/opentelemetry-instrumentation-http.gemspec +++ b/instrumentation/http/opentelemetry-instrumentation-http.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/http_client/opentelemetry-instrumentation-http_client.gemspec b/instrumentation/http_client/opentelemetry-instrumentation-http_client.gemspec index 98a0a1170..d1abd0f3d 100644 --- a/instrumentation/http_client/opentelemetry-instrumentation-http_client.gemspec +++ b/instrumentation/http_client/opentelemetry-instrumentation-http_client.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/httpx/opentelemetry-instrumentation-httpx.gemspec b/instrumentation/httpx/opentelemetry-instrumentation-httpx.gemspec index b2f48305a..674653f90 100644 --- a/instrumentation/httpx/opentelemetry-instrumentation-httpx.gemspec +++ b/instrumentation/httpx/opentelemetry-instrumentation-httpx.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/koala/opentelemetry-instrumentation-koala.gemspec b/instrumentation/koala/opentelemetry-instrumentation-koala.gemspec index 75d1d574e..2a7d105bf 100644 --- a/instrumentation/koala/opentelemetry-instrumentation-koala.gemspec +++ b/instrumentation/koala/opentelemetry-instrumentation-koala.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/lmdb/opentelemetry-instrumentation-lmdb.gemspec b/instrumentation/lmdb/opentelemetry-instrumentation-lmdb.gemspec index 7a59efcaa..a3edbf6a0 100644 --- a/instrumentation/lmdb/opentelemetry-instrumentation-lmdb.gemspec +++ b/instrumentation/lmdb/opentelemetry-instrumentation-lmdb.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/mongo/opentelemetry-instrumentation-mongo.gemspec b/instrumentation/mongo/opentelemetry-instrumentation-mongo.gemspec index f981355e7..e36f6f07a 100644 --- a/instrumentation/mongo/opentelemetry-instrumentation-mongo.gemspec +++ b/instrumentation/mongo/opentelemetry-instrumentation-mongo.gemspec @@ -37,7 +37,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/mysql2/opentelemetry-instrumentation-mysql2.gemspec b/instrumentation/mysql2/opentelemetry-instrumentation-mysql2.gemspec index 8a3124f0f..992404fa0 100644 --- a/instrumentation/mysql2/opentelemetry-instrumentation-mysql2.gemspec +++ b/instrumentation/mysql2/opentelemetry-instrumentation-mysql2.gemspec @@ -38,7 +38,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'pry' spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/net_http/opentelemetry-instrumentation-net_http.gemspec b/instrumentation/net_http/opentelemetry-instrumentation-net_http.gemspec index c0d4f4857..46efedd88 100644 --- a/instrumentation/net_http/opentelemetry-instrumentation-net_http.gemspec +++ b/instrumentation/net_http/opentelemetry-instrumentation-net_http.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rake', '~> 13.0.1' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/pg/opentelemetry-instrumentation-pg.gemspec b/instrumentation/pg/opentelemetry-instrumentation-pg.gemspec index 29feea416..9a75c42f4 100644 --- a/instrumentation/pg/opentelemetry-instrumentation-pg.gemspec +++ b/instrumentation/pg/opentelemetry-instrumentation-pg.gemspec @@ -38,7 +38,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'pry' spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/que/opentelemetry-instrumentation-que.gemspec b/instrumentation/que/opentelemetry-instrumentation-que.gemspec index 5fa8dfcfb..f12f24eb5 100644 --- a/instrumentation/que/opentelemetry-instrumentation-que.gemspec +++ b/instrumentation/que/opentelemetry-instrumentation-que.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/racecar/opentelemetry-instrumentation-racecar.gemspec b/instrumentation/racecar/opentelemetry-instrumentation-racecar.gemspec index ce4aceae2..de2db9908 100644 --- a/instrumentation/racecar/opentelemetry-instrumentation-racecar.gemspec +++ b/instrumentation/racecar/opentelemetry-instrumentation-racecar.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/rack/opentelemetry-instrumentation-rack.gemspec b/instrumentation/rack/opentelemetry-instrumentation-rack.gemspec index 7ecebeb6b..b60a117bc 100644 --- a/instrumentation/rack/opentelemetry-instrumentation-rack.gemspec +++ b/instrumentation/rack/opentelemetry-instrumentation-rack.gemspec @@ -37,7 +37,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec b/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec index e8db79ecf..bb5aad0ae 100644 --- a/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec +++ b/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec @@ -42,7 +42,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rack-test', '~> 2.1.0' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'webmock', '~> 3.19' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/rake/opentelemetry-instrumentation-rake.gemspec b/instrumentation/rake/opentelemetry-instrumentation-rake.gemspec index f6f8b709b..5188ec5a3 100644 --- a/instrumentation/rake/opentelemetry-instrumentation-rake.gemspec +++ b/instrumentation/rake/opentelemetry-instrumentation-rake.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.0' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/rdkafka/opentelemetry-instrumentation-rdkafka.gemspec b/instrumentation/rdkafka/opentelemetry-instrumentation-rdkafka.gemspec index e7b14e48a..7e2bcbe4f 100644 --- a/instrumentation/rdkafka/opentelemetry-instrumentation-rdkafka.gemspec +++ b/instrumentation/rdkafka/opentelemetry-instrumentation-rdkafka.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/redis/opentelemetry-instrumentation-redis.gemspec b/instrumentation/redis/opentelemetry-instrumentation-redis.gemspec index 183a9d8e0..0c139fcf9 100644 --- a/instrumentation/redis/opentelemetry-instrumentation-redis.gemspec +++ b/instrumentation/redis/opentelemetry-instrumentation-redis.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/resque/opentelemetry-instrumentation-resque.gemspec b/instrumentation/resque/opentelemetry-instrumentation-resque.gemspec index 1c6e8e5ab..4a15f9588 100644 --- a/instrumentation/resque/opentelemetry-instrumentation-resque.gemspec +++ b/instrumentation/resque/opentelemetry-instrumentation-resque.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/restclient/opentelemetry-instrumentation-restclient.gemspec b/instrumentation/restclient/opentelemetry-instrumentation-restclient.gemspec index 2b4823aac..c811e36f8 100644 --- a/instrumentation/restclient/opentelemetry-instrumentation-restclient.gemspec +++ b/instrumentation/restclient/opentelemetry-instrumentation-restclient.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/rspec/opentelemetry-instrumentation-rspec.gemspec b/instrumentation/rspec/opentelemetry-instrumentation-rspec.gemspec index 6c4760d0c..5ca35536e 100644 --- a/instrumentation/rspec/opentelemetry-instrumentation-rspec.gemspec +++ b/instrumentation/rspec/opentelemetry-instrumentation-rspec.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/ruby_kafka/opentelemetry-instrumentation-ruby_kafka.gemspec b/instrumentation/ruby_kafka/opentelemetry-instrumentation-ruby_kafka.gemspec index a6572baa6..50d7e8988 100644 --- a/instrumentation/ruby_kafka/opentelemetry-instrumentation-ruby_kafka.gemspec +++ b/instrumentation/ruby_kafka/opentelemetry-instrumentation-ruby_kafka.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/sidekiq/opentelemetry-instrumentation-sidekiq.gemspec b/instrumentation/sidekiq/opentelemetry-instrumentation-sidekiq.gemspec index dc1939455..604599935 100644 --- a/instrumentation/sidekiq/opentelemetry-instrumentation-sidekiq.gemspec +++ b/instrumentation/sidekiq/opentelemetry-instrumentation-sidekiq.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/sinatra/opentelemetry-instrumentation-sinatra.gemspec b/instrumentation/sinatra/opentelemetry-instrumentation-sinatra.gemspec index 4a1543785..755f7bc26 100644 --- a/instrumentation/sinatra/opentelemetry-instrumentation-sinatra.gemspec +++ b/instrumentation/sinatra/opentelemetry-instrumentation-sinatra.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rack-test', '~> 2.1' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.19' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/trilogy/opentelemetry-instrumentation-trilogy.gemspec b/instrumentation/trilogy/opentelemetry-instrumentation-trilogy.gemspec index 788ab8469..417a61af7 100644 --- a/instrumentation/trilogy/opentelemetry-instrumentation-trilogy.gemspec +++ b/instrumentation/trilogy/opentelemetry-instrumentation-trilogy.gemspec @@ -42,7 +42,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/processor/baggage/opentelemetry-processor-baggage.gemspec b/processor/baggage/opentelemetry-processor-baggage.gemspec index 18ef334bb..d8d6f4978 100644 --- a/processor/baggage/opentelemetry-processor-baggage.gemspec +++ b/processor/baggage/opentelemetry-processor-baggage.gemspec @@ -31,7 +31,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/propagator/ottrace/opentelemetry-propagator-ottrace.gemspec b/propagator/ottrace/opentelemetry-propagator-ottrace.gemspec index d00f57231..3282ee4d3 100644 --- a/propagator/ottrace/opentelemetry-propagator-ottrace.gemspec +++ b/propagator/ottrace/opentelemetry-propagator-ottrace.gemspec @@ -29,7 +29,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/propagator/vitess/opentelemetry-propagator-vitess.gemspec b/propagator/vitess/opentelemetry-propagator-vitess.gemspec index 74d87c68f..2d3295eee 100644 --- a/propagator/vitess/opentelemetry-propagator-vitess.gemspec +++ b/propagator/vitess/opentelemetry-propagator-vitess.gemspec @@ -30,7 +30,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/propagator/xray/opentelemetry-propagator-xray.gemspec b/propagator/xray/opentelemetry-propagator-xray.gemspec index c4c056fc8..51803b368 100644 --- a/propagator/xray/opentelemetry-propagator-xray.gemspec +++ b/propagator/xray/opentelemetry-propagator-xray.gemspec @@ -32,7 +32,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/resources/azure/opentelemetry-resource-detector-azure.gemspec b/resources/azure/opentelemetry-resource-detector-azure.gemspec index 8c92fea3c..585f4a341 100644 --- a/resources/azure/opentelemetry-resource-detector-azure.gemspec +++ b/resources/azure/opentelemetry-resource-detector-azure.gemspec @@ -31,7 +31,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17' spec.add_development_dependency 'webmock', '~> 3.23.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/resources/container/opentelemetry-resource-detector-container.gemspec b/resources/container/opentelemetry-resource-detector-container.gemspec index caf0fc56c..a98a0fb7e 100644 --- a/resources/container/opentelemetry-resource-detector-container.gemspec +++ b/resources/container/opentelemetry-resource-detector-container.gemspec @@ -31,7 +31,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/resources/google_cloud_platform/opentelemetry-resource-detector-google_cloud_platform.gemspec b/resources/google_cloud_platform/opentelemetry-resource-detector-google_cloud_platform.gemspec index 1603b54fe..ae3ecac66 100644 --- a/resources/google_cloud_platform/opentelemetry-resource-detector-google_cloud_platform.gemspec +++ b/resources/google_cloud_platform/opentelemetry-resource-detector-google_cloud_platform.gemspec @@ -32,7 +32,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.66.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.20' + spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17' spec.add_development_dependency 'webmock', '~> 3.23.0' spec.add_development_dependency 'yard', '~> 0.9' From bf5921d42ab9f055cb102d115db2bb4914aa16a4 Mon Sep 17 00:00:00 2001 From: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com> Date: Mon, 7 Oct 2024 15:56:07 -0700 Subject: [PATCH 29/58] chore: Update webmock to 3.24.0 (#1190) --- .instrumentation_generator/templates/gemspec.tt | 2 +- .../opentelemetry-instrumentation-action_mailer.gemspec | 2 +- .../opentelemetry-instrumentation-action_pack.gemspec | 2 +- .../opentelemetry-instrumentation-action_view.gemspec | 2 +- .../active_job/opentelemetry-instrumentation-active_job.gemspec | 2 +- ...entelemetry-instrumentation-active_model_serializers.gemspec | 2 +- .../opentelemetry-instrumentation-active_record.gemspec | 2 +- .../opentelemetry-instrumentation-active_support.gemspec | 2 +- .../aws_lambda/opentelemetry-instrumentation-aws_lambda.gemspec | 2 +- .../aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec | 2 +- .../opentelemetry-instrumentation-delayed_job.gemspec | 2 +- .../excon/opentelemetry-instrumentation-excon.gemspec | 2 +- .../faraday/opentelemetry-instrumentation-faraday.gemspec | 2 +- .../grape/opentelemetry-instrumentation-grape.gemspec | 2 +- .../graphql/opentelemetry-instrumentation-graphql.gemspec | 2 +- instrumentation/gruf/opentelemetry-instrumentation-gruf.gemspec | 2 +- instrumentation/http/opentelemetry-instrumentation-http.gemspec | 2 +- .../opentelemetry-instrumentation-http_client.gemspec | 2 +- .../httpx/opentelemetry-instrumentation-httpx.gemspec | 2 +- .../koala/opentelemetry-instrumentation-koala.gemspec | 2 +- instrumentation/lmdb/opentelemetry-instrumentation-lmdb.gemspec | 2 +- .../mongo/opentelemetry-instrumentation-mongo.gemspec | 2 +- .../net_http/opentelemetry-instrumentation-net_http.gemspec | 2 +- .../racecar/opentelemetry-instrumentation-racecar.gemspec | 2 +- instrumentation/rack/opentelemetry-instrumentation-rack.gemspec | 2 +- .../rails/opentelemetry-instrumentation-rails.gemspec | 2 +- instrumentation/rake/opentelemetry-instrumentation-rake.gemspec | 2 +- .../rdkafka/opentelemetry-instrumentation-rdkafka.gemspec | 2 +- .../resque/opentelemetry-instrumentation-resque.gemspec | 2 +- .../restclient/opentelemetry-instrumentation-restclient.gemspec | 2 +- .../rspec/opentelemetry-instrumentation-rspec.gemspec | 2 +- .../sinatra/opentelemetry-instrumentation-sinatra.gemspec | 2 +- resources/azure/opentelemetry-resource-detector-azure.gemspec | 2 +- ...pentelemetry-resource-detector-google_cloud_platform.gemspec | 2 +- 34 files changed, 34 insertions(+), 34 deletions(-) diff --git a/.instrumentation_generator/templates/gemspec.tt b/.instrumentation_generator/templates/gemspec.tt index fb51740b9..fdc83c9e2 100644 --- a/.instrumentation_generator/templates/gemspec.tt +++ b/.instrumentation_generator/templates/gemspec.tt @@ -37,7 +37,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.19.1' spec.add_development_dependency 'simplecov', '~> 0.17.1' - spec.add_development_dependency 'webmock', '~> 3.7.6' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/instrumentation/action_mailer/opentelemetry-instrumentation-action_mailer.gemspec b/instrumentation/action_mailer/opentelemetry-instrumentation-action_mailer.gemspec index 79f869aa5..df2373c87 100644 --- a/instrumentation/action_mailer/opentelemetry-instrumentation-action_mailer.gemspec +++ b/instrumentation/action_mailer/opentelemetry-instrumentation-action_mailer.gemspec @@ -38,7 +38,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/instrumentation/action_pack/opentelemetry-instrumentation-action_pack.gemspec b/instrumentation/action_pack/opentelemetry-instrumentation-action_pack.gemspec index 05da75032..3218d7075 100644 --- a/instrumentation/action_pack/opentelemetry-instrumentation-action_pack.gemspec +++ b/instrumentation/action_pack/opentelemetry-instrumentation-action_pack.gemspec @@ -39,7 +39,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/instrumentation/action_view/opentelemetry-instrumentation-action_view.gemspec b/instrumentation/action_view/opentelemetry-instrumentation-action_view.gemspec index d7fd65f0d..88d93245e 100644 --- a/instrumentation/action_view/opentelemetry-instrumentation-action_view.gemspec +++ b/instrumentation/action_view/opentelemetry-instrumentation-action_view.gemspec @@ -39,7 +39,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/instrumentation/active_job/opentelemetry-instrumentation-active_job.gemspec b/instrumentation/active_job/opentelemetry-instrumentation-active_job.gemspec index 9653e2d85..abfbd6057 100644 --- a/instrumentation/active_job/opentelemetry-instrumentation-active_job.gemspec +++ b/instrumentation/active_job/opentelemetry-instrumentation-active_job.gemspec @@ -38,7 +38,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/instrumentation/active_model_serializers/opentelemetry-instrumentation-active_model_serializers.gemspec b/instrumentation/active_model_serializers/opentelemetry-instrumentation-active_model_serializers.gemspec index ab8be88b4..0ddac5cf5 100644 --- a/instrumentation/active_model_serializers/opentelemetry-instrumentation-active_model_serializers.gemspec +++ b/instrumentation/active_model_serializers/opentelemetry-instrumentation-active_model_serializers.gemspec @@ -38,7 +38,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/instrumentation/active_record/opentelemetry-instrumentation-active_record.gemspec b/instrumentation/active_record/opentelemetry-instrumentation-active_record.gemspec index b3d4dfb17..fdd43f1a5 100644 --- a/instrumentation/active_record/opentelemetry-instrumentation-active_record.gemspec +++ b/instrumentation/active_record/opentelemetry-instrumentation-active_record.gemspec @@ -38,7 +38,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/instrumentation/active_support/opentelemetry-instrumentation-active_support.gemspec b/instrumentation/active_support/opentelemetry-instrumentation-active_support.gemspec index 1c906197d..eb596dec1 100644 --- a/instrumentation/active_support/opentelemetry-instrumentation-active_support.gemspec +++ b/instrumentation/active_support/opentelemetry-instrumentation-active_support.gemspec @@ -42,7 +42,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/instrumentation/aws_lambda/opentelemetry-instrumentation-aws_lambda.gemspec b/instrumentation/aws_lambda/opentelemetry-instrumentation-aws_lambda.gemspec index c11c8f653..9bf702871 100644 --- a/instrumentation/aws_lambda/opentelemetry-instrumentation-aws_lambda.gemspec +++ b/instrumentation/aws_lambda/opentelemetry-instrumentation-aws_lambda.gemspec @@ -39,7 +39,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/instrumentation/aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec b/instrumentation/aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec index 84328e3ef..7cb853d52 100644 --- a/instrumentation/aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec +++ b/instrumentation/aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec @@ -40,7 +40,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/instrumentation/delayed_job/opentelemetry-instrumentation-delayed_job.gemspec b/instrumentation/delayed_job/opentelemetry-instrumentation-delayed_job.gemspec index 06c73c930..7a2f90cdd 100644 --- a/instrumentation/delayed_job/opentelemetry-instrumentation-delayed_job.gemspec +++ b/instrumentation/delayed_job/opentelemetry-instrumentation-delayed_job.gemspec @@ -38,7 +38,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'sqlite3' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/instrumentation/excon/opentelemetry-instrumentation-excon.gemspec b/instrumentation/excon/opentelemetry-instrumentation-excon.gemspec index 45c42b778..bf532e5d2 100644 --- a/instrumentation/excon/opentelemetry-instrumentation-excon.gemspec +++ b/instrumentation/excon/opentelemetry-instrumentation-excon.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/instrumentation/faraday/opentelemetry-instrumentation-faraday.gemspec b/instrumentation/faraday/opentelemetry-instrumentation-faraday.gemspec index 8b3f7c740..3bcbe0b08 100644 --- a/instrumentation/faraday/opentelemetry-instrumentation-faraday.gemspec +++ b/instrumentation/faraday/opentelemetry-instrumentation-faraday.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/instrumentation/grape/opentelemetry-instrumentation-grape.gemspec b/instrumentation/grape/opentelemetry-instrumentation-grape.gemspec index 93f61389c..992bd08a7 100644 --- a/instrumentation/grape/opentelemetry-instrumentation-grape.gemspec +++ b/instrumentation/grape/opentelemetry-instrumentation-grape.gemspec @@ -41,7 +41,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/instrumentation/graphql/opentelemetry-instrumentation-graphql.gemspec b/instrumentation/graphql/opentelemetry-instrumentation-graphql.gemspec index 10a53ce3f..661ab2810 100644 --- a/instrumentation/graphql/opentelemetry-instrumentation-graphql.gemspec +++ b/instrumentation/graphql/opentelemetry-instrumentation-graphql.gemspec @@ -37,7 +37,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/instrumentation/gruf/opentelemetry-instrumentation-gruf.gemspec b/instrumentation/gruf/opentelemetry-instrumentation-gruf.gemspec index 4afb14290..24fe7727e 100644 --- a/instrumentation/gruf/opentelemetry-instrumentation-gruf.gemspec +++ b/instrumentation/gruf/opentelemetry-instrumentation-gruf.gemspec @@ -38,7 +38,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/instrumentation/http/opentelemetry-instrumentation-http.gemspec b/instrumentation/http/opentelemetry-instrumentation-http.gemspec index 38b45dc2e..b157b2827 100644 --- a/instrumentation/http/opentelemetry-instrumentation-http.gemspec +++ b/instrumentation/http/opentelemetry-instrumentation-http.gemspec @@ -38,7 +38,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/instrumentation/http_client/opentelemetry-instrumentation-http_client.gemspec b/instrumentation/http_client/opentelemetry-instrumentation-http_client.gemspec index d1abd0f3d..30cd1c4c5 100644 --- a/instrumentation/http_client/opentelemetry-instrumentation-http_client.gemspec +++ b/instrumentation/http_client/opentelemetry-instrumentation-http_client.gemspec @@ -37,7 +37,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/instrumentation/httpx/opentelemetry-instrumentation-httpx.gemspec b/instrumentation/httpx/opentelemetry-instrumentation-httpx.gemspec index 674653f90..54e8139e2 100644 --- a/instrumentation/httpx/opentelemetry-instrumentation-httpx.gemspec +++ b/instrumentation/httpx/opentelemetry-instrumentation-httpx.gemspec @@ -38,7 +38,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/instrumentation/koala/opentelemetry-instrumentation-koala.gemspec b/instrumentation/koala/opentelemetry-instrumentation-koala.gemspec index 2a7d105bf..90275d7d5 100644 --- a/instrumentation/koala/opentelemetry-instrumentation-koala.gemspec +++ b/instrumentation/koala/opentelemetry-instrumentation-koala.gemspec @@ -38,7 +38,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/instrumentation/lmdb/opentelemetry-instrumentation-lmdb.gemspec b/instrumentation/lmdb/opentelemetry-instrumentation-lmdb.gemspec index a3edbf6a0..a800b74ea 100644 --- a/instrumentation/lmdb/opentelemetry-instrumentation-lmdb.gemspec +++ b/instrumentation/lmdb/opentelemetry-instrumentation-lmdb.gemspec @@ -37,7 +37,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/instrumentation/mongo/opentelemetry-instrumentation-mongo.gemspec b/instrumentation/mongo/opentelemetry-instrumentation-mongo.gemspec index e36f6f07a..c9710a4ea 100644 --- a/instrumentation/mongo/opentelemetry-instrumentation-mongo.gemspec +++ b/instrumentation/mongo/opentelemetry-instrumentation-mongo.gemspec @@ -39,7 +39,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/instrumentation/net_http/opentelemetry-instrumentation-net_http.gemspec b/instrumentation/net_http/opentelemetry-instrumentation-net_http.gemspec index 46efedd88..78cc638fc 100644 --- a/instrumentation/net_http/opentelemetry-instrumentation-net_http.gemspec +++ b/instrumentation/net_http/opentelemetry-instrumentation-net_http.gemspec @@ -37,7 +37,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/instrumentation/racecar/opentelemetry-instrumentation-racecar.gemspec b/instrumentation/racecar/opentelemetry-instrumentation-racecar.gemspec index de2db9908..ec6ff7596 100644 --- a/instrumentation/racecar/opentelemetry-instrumentation-racecar.gemspec +++ b/instrumentation/racecar/opentelemetry-instrumentation-racecar.gemspec @@ -38,7 +38,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/instrumentation/rack/opentelemetry-instrumentation-rack.gemspec b/instrumentation/rack/opentelemetry-instrumentation-rack.gemspec index b60a117bc..e1feadb7d 100644 --- a/instrumentation/rack/opentelemetry-instrumentation-rack.gemspec +++ b/instrumentation/rack/opentelemetry-instrumentation-rack.gemspec @@ -39,7 +39,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec b/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec index bb5aad0ae..3cd4e629d 100644 --- a/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec +++ b/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec @@ -44,7 +44,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.22.0' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' spec.metadata['source_code_uri'] = 'https://github.com/open-telemetry/opentelemetry-ruby-contrib/tree/main/instrumentation/rails' if spec.respond_to?(:metadata) diff --git a/instrumentation/rake/opentelemetry-instrumentation-rake.gemspec b/instrumentation/rake/opentelemetry-instrumentation-rake.gemspec index 5188ec5a3..a473dfde1 100644 --- a/instrumentation/rake/opentelemetry-instrumentation-rake.gemspec +++ b/instrumentation/rake/opentelemetry-instrumentation-rake.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/instrumentation/rdkafka/opentelemetry-instrumentation-rdkafka.gemspec b/instrumentation/rdkafka/opentelemetry-instrumentation-rdkafka.gemspec index 7e2bcbe4f..c5d085f92 100644 --- a/instrumentation/rdkafka/opentelemetry-instrumentation-rdkafka.gemspec +++ b/instrumentation/rdkafka/opentelemetry-instrumentation-rdkafka.gemspec @@ -38,7 +38,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/instrumentation/resque/opentelemetry-instrumentation-resque.gemspec b/instrumentation/resque/opentelemetry-instrumentation-resque.gemspec index 4a15f9588..ba40ebc8d 100644 --- a/instrumentation/resque/opentelemetry-instrumentation-resque.gemspec +++ b/instrumentation/resque/opentelemetry-instrumentation-resque.gemspec @@ -37,7 +37,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/instrumentation/restclient/opentelemetry-instrumentation-restclient.gemspec b/instrumentation/restclient/opentelemetry-instrumentation-restclient.gemspec index c811e36f8..ab0e98a7b 100644 --- a/instrumentation/restclient/opentelemetry-instrumentation-restclient.gemspec +++ b/instrumentation/restclient/opentelemetry-instrumentation-restclient.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/instrumentation/rspec/opentelemetry-instrumentation-rspec.gemspec b/instrumentation/rspec/opentelemetry-instrumentation-rspec.gemspec index 5ca35536e..6c6ba2a5d 100644 --- a/instrumentation/rspec/opentelemetry-instrumentation-rspec.gemspec +++ b/instrumentation/rspec/opentelemetry-instrumentation-rspec.gemspec @@ -37,7 +37,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/instrumentation/sinatra/opentelemetry-instrumentation-sinatra.gemspec b/instrumentation/sinatra/opentelemetry-instrumentation-sinatra.gemspec index 755f7bc26..b727abf57 100644 --- a/instrumentation/sinatra/opentelemetry-instrumentation-sinatra.gemspec +++ b/instrumentation/sinatra/opentelemetry-instrumentation-sinatra.gemspec @@ -38,7 +38,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' - spec.add_development_dependency 'webmock', '~> 3.19' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/resources/azure/opentelemetry-resource-detector-azure.gemspec b/resources/azure/opentelemetry-resource-detector-azure.gemspec index 585f4a341..45362a4ea 100644 --- a/resources/azure/opentelemetry-resource-detector-azure.gemspec +++ b/resources/azure/opentelemetry-resource-detector-azure.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17' - spec.add_development_dependency 'webmock', '~> 3.23.0' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) diff --git a/resources/google_cloud_platform/opentelemetry-resource-detector-google_cloud_platform.gemspec b/resources/google_cloud_platform/opentelemetry-resource-detector-google_cloud_platform.gemspec index ae3ecac66..ff176fa07 100644 --- a/resources/google_cloud_platform/opentelemetry-resource-detector-google_cloud_platform.gemspec +++ b/resources/google_cloud_platform/opentelemetry-resource-detector-google_cloud_platform.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rubocop', '~> 1.66.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17' - spec.add_development_dependency 'webmock', '~> 3.23.0' + spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' if spec.respond_to?(:metadata) From 3ecf423c275d650896bd8ec5fa5612c6d4624410 Mon Sep 17 00:00:00 2001 From: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com> Date: Mon, 7 Oct 2024 16:16:26 -0700 Subject: [PATCH 30/58] chore: Update instrumentation/aws_sdk CODEOWNERS (#1191) Update instrumentation/aws_sdk CODEOWNERS The wonderful @jterapin and @alextwoods are members of the team at AWS who own the AWS SDK for Ruby. They've contributed a few changes to the aws_sdk instrumentation for enhanced compatibility with v2 and v3. This commit adds them to the codeowners list for the opentelemetry-instrumentation-aws_sdk gem. --- CODEOWNERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CODEOWNERS b/CODEOWNERS index 732650bfb..96e9c51be 100644 --- a/CODEOWNERS +++ b/CODEOWNERS @@ -16,7 +16,7 @@ resources/container/ @scbjans @open-telemetry/ruby-contrib-maintainers @open-telemetry/ruby-contrib-approvers @fbogsany @mwear @robertlaurin @dazuma @ericmustin @arielvalentin @ahayworth @plantfansam @robbkidd @simi @kaylareopelle @xuan-cao-swi -instrumentation/aws_sdk/ @NathanielRN @open-telemetry/ruby-contrib-maintainers @open-telemetry/ruby-contrib-approvers @fbogsany @mwear @robertlaurin @dazuma @ericmustin @arielvalentin @ahayworth @plantfansam @robbkidd @simi @kaylareopelle @xuan-cao-swi +instrumentation/aws_sdk/ @jterapin @alextwoods @NathanielRN @open-telemetry/ruby-contrib-maintainers @open-telemetry/ruby-contrib-approvers @fbogsany @mwear @robertlaurin @dazuma @ericmustin @arielvalentin @ahayworth @plantfansam @robbkidd @simi @kaylareopelle @xuan-cao-swi instrumentation/grape/ @muripic @open-telemetry/ruby-contrib-maintainers @open-telemetry/ruby-contrib-approvers @fbogsany @mwear @robertlaurin @dazuma @ericmustin @arielvalentin @ahayworth @plantfansam @robbkidd @simi @kaylareopelle @xuan-cao-swi From 0571e2e70cd3aaa88e1c91a319c6a194151667cd Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Tue, 8 Oct 2024 12:50:48 -0700 Subject: [PATCH 31/58] release: Release 3 gems (#1193) * release: Release 3 gems * opentelemetry-instrumentation-all 0.66.0 (was 0.65.0) * opentelemetry-instrumentation-aws_sdk 0.7.0 (was 0.6.0) * opentelemetry-instrumentation-que 0.8.4 (was 0.8.3) --------- Co-authored-by: OpenTelemetry Bot <107717825+opentelemetrybot@users.noreply.github.com> Co-authored-by: Kayla Reopelle --- instrumentation/all/CHANGELOG.md | 4 ++++ .../all/lib/opentelemetry/instrumentation/all/version.rb | 2 +- instrumentation/all/opentelemetry-instrumentation-all.gemspec | 2 +- instrumentation/aws_sdk/CHANGELOG.md | 4 ++++ .../lib/opentelemetry/instrumentation/aws_sdk/version.rb | 2 +- instrumentation/que/CHANGELOG.md | 4 ++++ .../que/lib/opentelemetry/instrumentation/que/version.rb | 2 +- 7 files changed, 16 insertions(+), 4 deletions(-) diff --git a/instrumentation/all/CHANGELOG.md b/instrumentation/all/CHANGELOG.md index 438034604..459ab7e2b 100644 --- a/instrumentation/all/CHANGELOG.md +++ b/instrumentation/all/CHANGELOG.md @@ -1,5 +1,9 @@ # Release History: opentelemetry-instrumentation-all +### v0.66.0 / 2024-10-08 + +* ADDED: Integration with V3 telemetry provider for the aws-sdk + ### v0.65.0 / 2024-09-19 * ADDED: All AWS services emit traces diff --git a/instrumentation/all/lib/opentelemetry/instrumentation/all/version.rb b/instrumentation/all/lib/opentelemetry/instrumentation/all/version.rb index 987e5b61d..c05a4c33d 100644 --- a/instrumentation/all/lib/opentelemetry/instrumentation/all/version.rb +++ b/instrumentation/all/lib/opentelemetry/instrumentation/all/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Instrumentation module All - VERSION = '0.65.0' + VERSION = '0.66.0' end end end diff --git a/instrumentation/all/opentelemetry-instrumentation-all.gemspec b/instrumentation/all/opentelemetry-instrumentation-all.gemspec index 3a4d35cd8..bccb40e24 100644 --- a/instrumentation/all/opentelemetry-instrumentation-all.gemspec +++ b/instrumentation/all/opentelemetry-instrumentation-all.gemspec @@ -28,7 +28,7 @@ Gem::Specification.new do |spec| spec.add_dependency 'opentelemetry-instrumentation-active_model_serializers', '~> 0.20.1' spec.add_dependency 'opentelemetry-instrumentation-aws_lambda', '~> 0.1.0' - spec.add_dependency 'opentelemetry-instrumentation-aws_sdk', '~> 0.6.0' + spec.add_dependency 'opentelemetry-instrumentation-aws_sdk', '~> 0.7.0' spec.add_dependency 'opentelemetry-instrumentation-bunny', '~> 0.21.0' spec.add_dependency 'opentelemetry-instrumentation-concurrent_ruby', '~> 0.21.1' spec.add_dependency 'opentelemetry-instrumentation-dalli', '~> 0.25.0' diff --git a/instrumentation/aws_sdk/CHANGELOG.md b/instrumentation/aws_sdk/CHANGELOG.md index a382f2c7a..4c00cd561 100644 --- a/instrumentation/aws_sdk/CHANGELOG.md +++ b/instrumentation/aws_sdk/CHANGELOG.md @@ -1,5 +1,9 @@ # Release History: opentelemetry-instrumentation-aws_sdk +### v0.7.0 / 2024-10-08 + +* ADDED: Integration with V3 telemetry provider + ### v0.6.0 / 2024-09-19 * ADDED: All AWS services emit traces diff --git a/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/version.rb b/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/version.rb index 0fbf946cf..6fe03e491 100644 --- a/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/version.rb +++ b/instrumentation/aws_sdk/lib/opentelemetry/instrumentation/aws_sdk/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Instrumentation module AwsSdk - VERSION = '0.6.0' + VERSION = '0.7.0' end end end diff --git a/instrumentation/que/CHANGELOG.md b/instrumentation/que/CHANGELOG.md index d77e66d0f..e9cff0dfd 100644 --- a/instrumentation/que/CHANGELOG.md +++ b/instrumentation/que/CHANGELOG.md @@ -1,5 +1,9 @@ # Release History: opentelemetry-instrumentation-que +### v0.8.4 / 2024-10-08 + +* FIXED: Fix bulk_enqueue when enqueuing more than 5 jobs + ### v0.8.3 / 2024-07-23 * DOCS: Add cspell to CI diff --git a/instrumentation/que/lib/opentelemetry/instrumentation/que/version.rb b/instrumentation/que/lib/opentelemetry/instrumentation/que/version.rb index eaa4552b6..964554f5d 100644 --- a/instrumentation/que/lib/opentelemetry/instrumentation/que/version.rb +++ b/instrumentation/que/lib/opentelemetry/instrumentation/que/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Instrumentation module Que - VERSION = '0.8.3' + VERSION = '0.8.4' end end end From c2ffafc85527a415bbe6d0fccece1130201634c1 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 8 Oct 2024 13:17:31 -0700 Subject: [PATCH 32/58] chore: bump ruby/setup-ruby from 1.194.0 to 1.196.0 (#1192) * chore: bump ruby/setup-ruby from 1.194.0 to 1.196.0 Bumps [ruby/setup-ruby](https://github.com/ruby/setup-ruby) from 1.194.0 to 1.196.0. - [Release notes](https://github.com/ruby/setup-ruby/releases) - [Changelog](https://github.com/ruby/setup-ruby/blob/master/release.rb) - [Commits](https://github.com/ruby/setup-ruby/compare/v1.194.0...v1.196.0) --- updated-dependencies: - dependency-name: ruby/setup-ruby dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] * chore: Update action.yml setup-ruby to 1.196.0 --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Kayla Reopelle Co-authored-by: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com> --- .github/actions/test_gem/action.yml | 4 ++-- .github/workflows/installation-tests.yml | 2 +- .github/workflows/release-hook-on-closed.yml | 2 +- .github/workflows/release-hook-on-push.yml | 2 +- .github/workflows/release-perform.yml | 2 +- .github/workflows/release-please.yaml | 2 +- .github/workflows/release-request-weekly.yml | 2 +- .github/workflows/release-request.yml | 2 +- .github/workflows/release-retry.yml | 2 +- 9 files changed, 10 insertions(+), 10 deletions(-) diff --git a/.github/actions/test_gem/action.yml b/.github/actions/test_gem/action.yml index 4b4ddfbcf..6d18d8997 100644 --- a/.github/actions/test_gem/action.yml +++ b/.github/actions/test_gem/action.yml @@ -66,7 +66,7 @@ runs: # ...but not for appraisals, sadly. - name: Install Ruby ${{ inputs.ruby }} with dependencies if: "${{ steps.setup.outputs.appraisals == 'false' }}" - uses: ruby/setup-ruby@v1.194.0 + uses: ruby/setup-ruby@v1.196.0 with: ruby-version: "${{ inputs.ruby }}" working-directory: "${{ steps.setup.outputs.gem_dir }}" @@ -77,7 +77,7 @@ runs: # If we're using appraisals, do it all manually. - name: Install Ruby ${{ inputs.ruby }} without dependencies if: "${{ steps.setup.outputs.appraisals == 'true' }}" - uses: ruby/setup-ruby@v1.194.0 + uses: ruby/setup-ruby@v1.196.0 with: ruby-version: "${{ inputs.ruby }}" bundler: "latest" diff --git a/.github/workflows/installation-tests.yml b/.github/workflows/installation-tests.yml index 5efb7c95e..c0dd04861 100644 --- a/.github/workflows/installation-tests.yml +++ b/.github/workflows/installation-tests.yml @@ -25,7 +25,7 @@ jobs: - uses: actions/checkout@v4 # ATTENTION: Dependabot does not know how to update shared actions file. # If you see it update setup-ruby here also update it as part of actions/test_gem/action.yml - - uses: ruby/setup-ruby@v1.194.0 + - uses: ruby/setup-ruby@v1.196.0 with: ruby-version: ${{ matrix.ruby-version }} - name: "Install Latest Gem Versions on ${{ matrix.ruby-version }}" diff --git a/.github/workflows/release-hook-on-closed.yml b/.github/workflows/release-hook-on-closed.yml index 29c07df0f..984ded503 100644 --- a/.github/workflows/release-hook-on-closed.yml +++ b/.github/workflows/release-hook-on-closed.yml @@ -12,7 +12,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.194.0 + uses: ruby/setup-ruby@v1.196.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-hook-on-push.yml b/.github/workflows/release-hook-on-push.yml index 66653b863..80c2e3d72 100644 --- a/.github/workflows/release-hook-on-push.yml +++ b/.github/workflows/release-hook-on-push.yml @@ -13,7 +13,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.194.0 + uses: ruby/setup-ruby@v1.196.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-perform.yml b/.github/workflows/release-perform.yml index e7cfd5af5..258414061 100644 --- a/.github/workflows/release-perform.yml +++ b/.github/workflows/release-perform.yml @@ -22,7 +22,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.194.0 + uses: ruby/setup-ruby@v1.196.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-please.yaml b/.github/workflows/release-please.yaml index 0e113ec04..f5a9507a1 100644 --- a/.github/workflows/release-please.yaml +++ b/.github/workflows/release-please.yaml @@ -50,7 +50,7 @@ jobs: chmod 0600 $HOME/.gem/credentials printf -- "---\n:rubygems_api_key: ${GEM_HOST_API_KEY}\n" > $HOME/.gem/credentials - - uses: ruby/setup-ruby@v1.194.0 + - uses: ruby/setup-ruby@v1.196.0 with: ruby-version: "3.0" bundler: latest diff --git a/.github/workflows/release-request-weekly.yml b/.github/workflows/release-request-weekly.yml index 03c1ca27c..65c158239 100644 --- a/.github/workflows/release-request-weekly.yml +++ b/.github/workflows/release-request-weekly.yml @@ -12,7 +12,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.194.0 + uses: ruby/setup-ruby@v1.196.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-request.yml b/.github/workflows/release-request.yml index 6d208071d..9c0a4746d 100644 --- a/.github/workflows/release-request.yml +++ b/.github/workflows/release-request.yml @@ -16,7 +16,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.194.0 + uses: ruby/setup-ruby@v1.196.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-retry.yml b/.github/workflows/release-retry.yml index 27e8149d3..b20aa1fdc 100644 --- a/.github/workflows/release-retry.yml +++ b/.github/workflows/release-retry.yml @@ -19,7 +19,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.194.0 + uses: ruby/setup-ruby@v1.196.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo From 5b68a5bb6bb7edb535bae52d7f2bbc96eb854755 Mon Sep 17 00:00:00 2001 From: Albert Llop Date: Tue, 22 Oct 2024 02:03:08 +0200 Subject: [PATCH 33/58] feat: subscribe to process.action_mailer notifications (#1185) * feat: subscribe to process.action_mailer notifications * doc: add payload table for `process.action_mailer` event * doc: expand ActionMailer::Instrumentation class docs * tests: add test that execute an ActionMailer delivery * tests: disable warnings --------- Co-authored-by: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com> --- instrumentation/action_mailer/README.md | 20 ++- instrumentation/action_mailer/Rakefile | 1 + .../action_mailer/instrumentation.rb | 50 +++++- .../instrumentation/action_mailer/railtie.rb | 27 +++- .../action_mailer/subscription_test.rb | 142 ++++++++++++++++++ .../action_mailer/test/test_helper.rb | 20 +++ 6 files changed, 247 insertions(+), 13 deletions(-) create mode 100644 instrumentation/action_mailer/test/opentelemetry/instrumentation/action_mailer/subscription_test.rb diff --git a/instrumentation/action_mailer/README.md b/instrumentation/action_mailer/README.md index 63c13d810..3d429e7d2 100644 --- a/instrumentation/action_mailer/README.md +++ b/instrumentation/action_mailer/README.md @@ -21,7 +21,7 @@ To use the instrumentation, call `use` with the name of the instrumentation: ```ruby OpenTelemetry::SDK.configure do |c| - # Use only the ActionMailer instrumentation + # Use only the ActionMailer instrumentation c.use 'OpenTelemetry::Instrumentation::ActionMailer' # Use the ActionMailer instrumentation along with the rest of the Rails-related instrumentation c.use 'OpenTelemetry::Instrumentation::Rails' @@ -44,8 +44,8 @@ See the table below for details of what [Rails Framework Hook Events](https://gu | Event Name | Creates Span? | Notes | | - | - | - | -| `deliver.action_mailer` | :white_check_mark: | Creates an span with kind `internal` and email content and status| -| `process.action_mailer` | :x: | Lack of useful info so ignored | +| `deliver.action_mailer` | :white_check_mark: | Creates a span with kind `internal` and email content and status | +| `process.action_mailer` | :white_check_mark: | Creates a span with kind `internal` that will include email rendering spans | ### Options @@ -67,9 +67,9 @@ end ## Semantic Conventions -Internal spans are named using the name of the `ActiveSupport` event that was provided (e.g. `action_mailer deliver`). +Internal spans are named using the name of the `ActiveSupport` event that was provided (e.g. `deliver.action_mailer`). -The following attributes from the notification payload for the `deliver.action_mailer` event are attached to `action_mailer deliver` spans: +### Attributes attached to the `deliver.action_mailer` event payload | Attribute Name | Type | Notes | | - | - | - | @@ -79,7 +79,15 @@ The following attributes from the notification payload for the `deliver.action_m | `email.to.address` | Array | Receiver for mail (omit by default, include when `email_address` set to `:include`) | | `email.from.address` | Array | Sender for mail (omit by default, include when `email_address` set to `:include`) | | `email.cc.address` | Array | mail CC (omit by default, include when `email_address` set to `:include`) | -| `email.bcc.address` | Array | mail BCC (omit by default, include when `email_address` set to `:include`) | +| `email.bcc.address` | Array | mail BCC (omit by default, include when `email_address` set to `:include`) | + +### Attributes attached to the `process.action_mailer` event payload + +| Attribute Name | Type | Notes | +| - | - | - | +| `mailer` | String | Mailer class that is used to render the mail | +| `action` | String | Method from the mailer class called to render the mail | +| `args` | Array | Arguments passed to the method to render the email | ## Examples diff --git a/instrumentation/action_mailer/Rakefile b/instrumentation/action_mailer/Rakefile index 1a64ba842..4b0e9b5a8 100644 --- a/instrumentation/action_mailer/Rakefile +++ b/instrumentation/action_mailer/Rakefile @@ -15,6 +15,7 @@ Rake::TestTask.new :test do |t| t.libs << 'test' t.libs << 'lib' t.test_files = FileList['test/**/*_test.rb'] + t.warning = false end YARD::Rake::YardocTask.new do |t| diff --git a/instrumentation/action_mailer/lib/opentelemetry/instrumentation/action_mailer/instrumentation.rb b/instrumentation/action_mailer/lib/opentelemetry/instrumentation/action_mailer/instrumentation.rb index 2b33478aa..3ba3cb714 100644 --- a/instrumentation/action_mailer/lib/opentelemetry/instrumentation/action_mailer/instrumentation.rb +++ b/instrumentation/action_mailer/lib/opentelemetry/instrumentation/action_mailer/instrumentation.rb @@ -7,7 +7,53 @@ module OpenTelemetry module Instrumentation module ActionMailer - # The Instrumentation class contains logic to detect and install the ActionMailer instrumentation + # The {OpenTelemetry::Instrumentation::ActionMailer::Instrumentation} class contains logic to detect and install the ActionMailer instrumentation + # + # Installation and configuration of this instrumentation is done within the + # {https://www.rubydoc.info/gems/opentelemetry-sdk/OpenTelemetry/SDK#configure-instance_method OpenTelemetry::SDK#configure} + # block, calling {https://www.rubydoc.info/gems/opentelemetry-sdk/OpenTelemetry%2FSDK%2FConfigurator:use use()} + # or {https://www.rubydoc.info/gems/opentelemetry-sdk/OpenTelemetry%2FSDK%2FConfigurator:use_all use_all()}. + # + # ## Configuration keys and options + # + # ### `:disallowed_notification_payload_keys` + # + # Specifies an array of keys that should be excluded from the `deliver.action_mailer` notification payload as span attributes. + # + # ### `:disallowed_process_payload_keys` + # + # Specifies an array of keys that should be excluded from the `process.action_mailer` notification payload as span attributes. + # + # ### `:notification_payload_transform` + # + # - `proc` **default** `nil` + # + # Specifies custom proc used to extract span attributes form the `deliver.action_mailer` notification payload. Use this to rename keys, extract nested values, or perform any other custom logic. + # + # ### `:process_payload_transform` + # + # - `proc` **default** `nil` + # + # Specifies custom proc used to extract span attributes form the `process.action_mailer` notification payload. Use this to rename keys, extract nested values, or perform any other custom logic. + # + # ### `:email_address` + # + # - `symbol` **default** `:omit` + # + # Specifies whether to include email addresses in the notification payload. Valid values are `:omit` and `:include`. + # + # @example An explicit default configuration + # OpenTelemetry::SDK.configure do |c| + # c.use_all({ + # 'OpenTelemetry::Instrumentation::ActionMailer' => { + # disallowed_notification_payload_keys: [], + # disallowed_process_payload_keys: [], + # notification_payload_transform: nil, + # process_payload_transform: nil, + # email_address: :omit, + # }, + # }) + # end class Instrumentation < OpenTelemetry::Instrumentation::Base MINIMUM_VERSION = Gem::Version.new('6.1.0') EMAIL_ATTRIBUTE = %w[email.to.address email.from.address email.cc.address email.bcc.address].freeze @@ -27,7 +73,9 @@ class Instrumentation < OpenTelemetry::Instrumentation::Base end option :disallowed_notification_payload_keys, default: [], validate: :array + option :disallowed_process_payload_keys, default: [], validate: :array option :notification_payload_transform, default: nil, validate: :callable + option :process_payload_transform, default: nil, validate: :callable option :email_address, default: :omit, validate: %I[omit include] private diff --git a/instrumentation/action_mailer/lib/opentelemetry/instrumentation/action_mailer/railtie.rb b/instrumentation/action_mailer/lib/opentelemetry/instrumentation/action_mailer/railtie.rb index 0b036d0e9..724e2a162 100644 --- a/instrumentation/action_mailer/lib/opentelemetry/instrumentation/action_mailer/railtie.rb +++ b/instrumentation/action_mailer/lib/opentelemetry/instrumentation/action_mailer/railtie.rb @@ -7,24 +7,39 @@ module OpenTelemetry module Instrumentation module ActionMailer - SUBSCRIPTIONS = %w[ - deliver.action_mailer - ].freeze + DELIVER_SUBSCRIPTION = 'deliver.action_mailer' + PROCESS_SUBSCRIPTION = 'process.action_mailer' # This Railtie sets up subscriptions to relevant ActionMailer notifications class Railtie < ::Rails::Railtie config.after_initialize do ::OpenTelemetry::Instrumentation::ActiveSupport::Instrumentation.instance.install({}) + subscribe_to_deliver + subscribe_to_process + end - SUBSCRIPTIONS.each do |subscription_name| - config = ActionMailer::Instrumentation.instance.config + class << self + def subscribe_to_deliver ::OpenTelemetry::Instrumentation::ActiveSupport.subscribe( ActionMailer::Instrumentation.instance.tracer, - subscription_name, + DELIVER_SUBSCRIPTION, config[:notification_payload_transform], config[:disallowed_notification_payload_keys] ) end + + def subscribe_to_process + ::OpenTelemetry::Instrumentation::ActiveSupport.subscribe( + ActionMailer::Instrumentation.instance.tracer, + PROCESS_SUBSCRIPTION, + config[:process_payload_transform], + config[:disallowed_process_payload_keys] + ) + end + + def config + ActionMailer::Instrumentation.instance.config + end end end end diff --git a/instrumentation/action_mailer/test/opentelemetry/instrumentation/action_mailer/subscription_test.rb b/instrumentation/action_mailer/test/opentelemetry/instrumentation/action_mailer/subscription_test.rb new file mode 100644 index 000000000..2d22098c6 --- /dev/null +++ b/instrumentation/action_mailer/test/opentelemetry/instrumentation/action_mailer/subscription_test.rb @@ -0,0 +1,142 @@ +# frozen_string_literal: true + +# Copyright The OpenTelemetry Authors +# +# SPDX-License-Identifier: Apache-2.0 + +require 'test_helper' +require 'opentelemetry-instrumentation-active_support' + +describe OpenTelemetry::Instrumentation::ActionMailer do + let(:exporter) { EXPORTER } + let(:spans) { exporter.finished_spans } + let(:instrumentation) { OpenTelemetry::Instrumentation::ActionMailer::Instrumentation.instance } + + before do + exporter.reset + end + + describe 'deliver.action_mailer' do + describe 'with default configuration' do + it 'generates a deliver span' do + subscribing_to_deliver do + TestMailer.hello_world.deliver_now + end + + _(spans.length).must_equal(1) + span = spans.find { |s| s.name == 'deliver.action_mailer' } + + _(span).wont_be_nil + + _(span.attributes['email.x_mailer']).must_equal('TestMailer') + _(span.attributes['email.subject']).must_equal('Hello world') + _(span.attributes['email.message_id']).wont_be_empty + end + end + + describe 'with custom configuration' do + it 'with email_address: :include' do + with_configuration(email_address: :include, disallowed_notification_payload_keys: []) do + subscribing_to_deliver do + TestMailer.hello_world.deliver_now + end + end + + _(spans.length).must_equal(1) + span = spans.find { |s| s.name == 'deliver.action_mailer' } + + _(span).wont_be_nil + + _(span.attributes['email.x_mailer']).must_equal('TestMailer') + _(span.attributes['email.subject']).must_equal('Hello world') + _(span.attributes['email.message_id']).wont_be_empty + _(span.attributes['email.to.address']).must_equal(['to@example.com']) + _(span.attributes['email.from.address']).must_equal(['from@example.com']) + _(span.attributes['email.cc.address']).must_equal(['cc@example.com']) + _(span.attributes['email.bcc.address']).must_equal(['bcc@example.com']) + end + + it 'with a custom transform proc' do + transform = ->(payload) { payload.transform_keys(&:upcase) } + with_configuration(notification_payload_transform: transform) do + instrumentation.send(:ecs_mail_convention) + subscribing_to_deliver do + TestMailer.hello_world.deliver_now + end + end + + _(spans.length).must_equal(1) + span = spans.find { |s| s.name == 'deliver.action_mailer' } + + _(span).wont_be_nil + + _(span.attributes['EMAIL.X_MAILER']).must_equal('TestMailer') + _(span.attributes['EMAIL.SUBJECT']).must_equal('Hello world') + _(span.attributes['EMAIL.MESSAGE_ID']).wont_be_empty + end + end + end + + describe 'process.action_mailer' do + describe 'with default configuration' do + it 'generates a process span' do + transform = ->(payload) { payload.transform_keys(&:upcase) } + with_configuration(disallowed_process_payload_keys: [:ARGS], process_payload_transform: transform) do + subscribing_to_process do + TestMailer.hello_world('Hola mundo').deliver_now + end + end + + _(spans.length).must_equal(1) + span = spans.find { |s| s.name == 'process.action_mailer' } + + _(span).wont_be_nil + + _(span.attributes['MAILER']).must_equal('TestMailer') + _(span.attributes['ACTION']).must_equal('hello_world') + _(span.attributes['ARGS']).must_be_nil + end + end + + describe 'with custom configuration' do + it 'generates a process span' do + subscribing_to_process do + TestMailer.hello_world('Hola mundo').deliver_now + end + + _(spans.length).must_equal(1) + span = spans.find { |s| s.name == 'process.action_mailer' } + + _(span).wont_be_nil + + _(span.attributes['mailer']).must_equal('TestMailer') + _(span.attributes['action']).must_equal('hello_world') + _(span.attributes['args']).must_equal(['Hola mundo']) + end + end + end + + def with_configuration(values, &block) + original_config = instrumentation.instance_variable_get(:@config) + modified_config = original_config.merge(values) + instrumentation.instance_variable_set(:@config, modified_config) + + yield + + instrumentation.instance_variable_set(:@config, original_config) + end + + def subscribing_to_deliver(&block) + subscription = OpenTelemetry::Instrumentation::ActionMailer::Railtie.subscribe_to_deliver + yield + ensure + ActiveSupport::Notifications.unsubscribe(subscription) + end + + def subscribing_to_process(&block) + subscription = OpenTelemetry::Instrumentation::ActionMailer::Railtie.subscribe_to_process + yield + ensure + ActiveSupport::Notifications.unsubscribe(subscription) + end +end diff --git a/instrumentation/action_mailer/test/test_helper.rb b/instrumentation/action_mailer/test/test_helper.rb index b68d22b82..945016422 100644 --- a/instrumentation/action_mailer/test/test_helper.rb +++ b/instrumentation/action_mailer/test/test_helper.rb @@ -22,3 +22,23 @@ c.use 'OpenTelemetry::Instrumentation::ActionMailer' c.add_span_processor span_processor end + +OpenTelemetry::Instrumentation::ActiveSupport::Instrumentation.instance.install({}) +OpenTelemetry::Instrumentation::ActionMailer::Instrumentation.instance.install({}) + +ActionMailer::Base.delivery_method = :test + +class TestMailer < ActionMailer::Base + FROM = 'from@example.com' + TO = 'to@example.com' + CC = 'cc@example.com' + BCC = 'bcc@example.com' + + def hello_world(message = 'Hello world') + @message = message + mail from: FROM, to: TO, cc: CC, bcc: BCC do |format| + format.html { render inline: '

<%= @message %>

' } + format.text { render inline: '<%= @message %>' } + end + end +end From e3bd5241bd4d32cbb9e1c85de1a49ea9c9b28493 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 22 Oct 2024 12:36:39 -0700 Subject: [PATCH 34/58] chore: bump ruby/setup-ruby from 1.196.0 to 1.197.0 (#1195) * chore: bump ruby/setup-ruby from 1.196.0 to 1.197.0 Bumps [ruby/setup-ruby](https://github.com/ruby/setup-ruby) from 1.196.0 to 1.197.0. - [Release notes](https://github.com/ruby/setup-ruby/releases) - [Changelog](https://github.com/ruby/setup-ruby/blob/master/release.rb) - [Commits](https://github.com/ruby/setup-ruby/compare/v1.196.0...v1.197.0) --- updated-dependencies: - dependency-name: ruby/setup-ruby dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] * chore: Update ruby/setup-ruby to 1.197.0 --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Kayla Reopelle Co-authored-by: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com> --- .github/actions/test_gem/action.yml | 4 ++-- .github/workflows/installation-tests.yml | 2 +- .github/workflows/release-hook-on-closed.yml | 2 +- .github/workflows/release-hook-on-push.yml | 2 +- .github/workflows/release-perform.yml | 2 +- .github/workflows/release-please.yaml | 2 +- .github/workflows/release-request-weekly.yml | 2 +- .github/workflows/release-request.yml | 2 +- .github/workflows/release-retry.yml | 2 +- 9 files changed, 10 insertions(+), 10 deletions(-) diff --git a/.github/actions/test_gem/action.yml b/.github/actions/test_gem/action.yml index 6d18d8997..f6637260e 100644 --- a/.github/actions/test_gem/action.yml +++ b/.github/actions/test_gem/action.yml @@ -66,7 +66,7 @@ runs: # ...but not for appraisals, sadly. - name: Install Ruby ${{ inputs.ruby }} with dependencies if: "${{ steps.setup.outputs.appraisals == 'false' }}" - uses: ruby/setup-ruby@v1.196.0 + uses: ruby/setup-ruby@v1.197.0 with: ruby-version: "${{ inputs.ruby }}" working-directory: "${{ steps.setup.outputs.gem_dir }}" @@ -77,7 +77,7 @@ runs: # If we're using appraisals, do it all manually. - name: Install Ruby ${{ inputs.ruby }} without dependencies if: "${{ steps.setup.outputs.appraisals == 'true' }}" - uses: ruby/setup-ruby@v1.196.0 + uses: ruby/setup-ruby@v1.197.0 with: ruby-version: "${{ inputs.ruby }}" bundler: "latest" diff --git a/.github/workflows/installation-tests.yml b/.github/workflows/installation-tests.yml index c0dd04861..87e378b80 100644 --- a/.github/workflows/installation-tests.yml +++ b/.github/workflows/installation-tests.yml @@ -25,7 +25,7 @@ jobs: - uses: actions/checkout@v4 # ATTENTION: Dependabot does not know how to update shared actions file. # If you see it update setup-ruby here also update it as part of actions/test_gem/action.yml - - uses: ruby/setup-ruby@v1.196.0 + - uses: ruby/setup-ruby@v1.197.0 with: ruby-version: ${{ matrix.ruby-version }} - name: "Install Latest Gem Versions on ${{ matrix.ruby-version }}" diff --git a/.github/workflows/release-hook-on-closed.yml b/.github/workflows/release-hook-on-closed.yml index 984ded503..ea751f2d8 100644 --- a/.github/workflows/release-hook-on-closed.yml +++ b/.github/workflows/release-hook-on-closed.yml @@ -12,7 +12,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.196.0 + uses: ruby/setup-ruby@v1.197.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-hook-on-push.yml b/.github/workflows/release-hook-on-push.yml index 80c2e3d72..162c7f7eb 100644 --- a/.github/workflows/release-hook-on-push.yml +++ b/.github/workflows/release-hook-on-push.yml @@ -13,7 +13,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.196.0 + uses: ruby/setup-ruby@v1.197.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-perform.yml b/.github/workflows/release-perform.yml index 258414061..794f91414 100644 --- a/.github/workflows/release-perform.yml +++ b/.github/workflows/release-perform.yml @@ -22,7 +22,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.196.0 + uses: ruby/setup-ruby@v1.197.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-please.yaml b/.github/workflows/release-please.yaml index f5a9507a1..dc39a65cb 100644 --- a/.github/workflows/release-please.yaml +++ b/.github/workflows/release-please.yaml @@ -50,7 +50,7 @@ jobs: chmod 0600 $HOME/.gem/credentials printf -- "---\n:rubygems_api_key: ${GEM_HOST_API_KEY}\n" > $HOME/.gem/credentials - - uses: ruby/setup-ruby@v1.196.0 + - uses: ruby/setup-ruby@v1.197.0 with: ruby-version: "3.0" bundler: latest diff --git a/.github/workflows/release-request-weekly.yml b/.github/workflows/release-request-weekly.yml index 65c158239..73ea683bf 100644 --- a/.github/workflows/release-request-weekly.yml +++ b/.github/workflows/release-request-weekly.yml @@ -12,7 +12,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.196.0 + uses: ruby/setup-ruby@v1.197.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-request.yml b/.github/workflows/release-request.yml index 9c0a4746d..1e34f9fc5 100644 --- a/.github/workflows/release-request.yml +++ b/.github/workflows/release-request.yml @@ -16,7 +16,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.196.0 + uses: ruby/setup-ruby@v1.197.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-retry.yml b/.github/workflows/release-retry.yml index b20aa1fdc..0a9dcadbe 100644 --- a/.github/workflows/release-retry.yml +++ b/.github/workflows/release-retry.yml @@ -19,7 +19,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.196.0 + uses: ruby/setup-ruby@v1.197.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo From 392b35e78eddef5970e39e13e4cfbcbbaceb6878 Mon Sep 17 00:00:00 2001 From: Albert Llop Date: Tue, 22 Oct 2024 22:24:15 +0200 Subject: [PATCH 35/58] fix!: activerecord find_by_sql spans on Rails 7.0+ (#1184) * fix: activerecord find_by_sql spans on Rails 7.0+ * tests: fix create_table call * tests: rubocop tweak * feat: call spans that produce reads `query` * Refactor patching to use define_method --------- Co-authored-by: Ariel Valentin Co-authored-by: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com> --- .../active_record/patches/querying.rb | 8 +++++--- .../active_record/patches/querying_test.rb | 12 +++++++++--- instrumentation/active_record/test/test_helper.rb | 11 ++++++++++- 3 files changed, 24 insertions(+), 7 deletions(-) diff --git a/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/patches/querying.rb b/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/patches/querying.rb index 41280b1f1..094575ae4 100644 --- a/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/patches/querying.rb +++ b/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/patches/querying.rb @@ -18,9 +18,11 @@ class << base # Contains ActiveRecord::Querying to be patched module ClassMethods - def find_by_sql(...) - tracer.in_span("#{self}.find_by_sql") do - super + method_name = ::ActiveRecord.version >= Gem::Version.new('7.0.0') ? :_query_by_sql : :find_by_sql + + define_method(method_name) do |*args, **kwargs| + tracer.in_span("#{self} query") do + super(*args, **kwargs) end end diff --git a/instrumentation/active_record/test/instrumentation/active_record/patches/querying_test.rb b/instrumentation/active_record/test/instrumentation/active_record/patches/querying_test.rb index 6da620512..879af50e6 100644 --- a/instrumentation/active_record/test/instrumentation/active_record/patches/querying_test.rb +++ b/instrumentation/active_record/test/instrumentation/active_record/patches/querying_test.rb @@ -15,12 +15,18 @@ before { exporter.reset } - describe 'find_by_sql' do + describe 'query' do it 'traces' do + Account.create! + User.find_by_sql('SELECT * FROM users') + Account.first.users.to_a + + user_find_spans = spans.select { |s| s.name == 'User query' } + account_find_span = spans.find { |s| s.name == 'Account query' } - find_span = spans.find { |s| s.name == 'User.find_by_sql' } - _(find_span).wont_be_nil + _(user_find_spans.length).must_equal(2) + _(account_find_span).wont_be_nil end end end diff --git a/instrumentation/active_record/test/test_helper.rb b/instrumentation/active_record/test/test_helper.rb index 6cf6d2757..02751e7f6 100644 --- a/instrumentation/active_record/test/test_helper.rb +++ b/instrumentation/active_record/test/test_helper.rb @@ -34,8 +34,14 @@ database: 'db/development.sqlite3' ) -# Create User model +# Create ActiveRecord models +class Account < ActiveRecord::Base + has_many :users +end + class User < ActiveRecord::Base + belongs_to :account + validate :name_if_present scope :recently_created, -> { where('created_at > ?', Time.now - 3600) } @@ -54,9 +60,12 @@ class SuperUser < ActiveRecord::Base; end # Simple migration to create a table to test against class CreateUserTable < ActiveRecord::Migration[migration_version] def change + create_table :accounts, &:timestamps + create_table :users do |t| t.string 'name' t.integer 'counter' + t.references 'account' t.timestamps end From d7e906545468948234b2d7285df33f5ec6285fdf Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Tue, 22 Oct 2024 17:16:18 -0700 Subject: [PATCH 36/58] release: Release 4 gems (#1210) --- instrumentation/action_mailer/CHANGELOG.md | 4 +++ .../instrumentation/action_mailer/version.rb | 2 +- instrumentation/active_record/CHANGELOG.md | 33 +++++++++++-------- .../instrumentation/active_record/version.rb | 2 +- instrumentation/all/CHANGELOG.md | 6 ++++ .../instrumentation/all/version.rb | 2 +- .../opentelemetry-instrumentation-all.gemspec | 2 +- instrumentation/rails/CHANGELOG.md | 6 ++++ instrumentation/rails/Gemfile | 5 +-- .../instrumentation/rails/version.rb | 2 +- ...pentelemetry-instrumentation-rails.gemspec | 4 +-- 11 files changed, 45 insertions(+), 23 deletions(-) diff --git a/instrumentation/action_mailer/CHANGELOG.md b/instrumentation/action_mailer/CHANGELOG.md index 8f0fc70b8..00f95806c 100644 --- a/instrumentation/action_mailer/CHANGELOG.md +++ b/instrumentation/action_mailer/CHANGELOG.md @@ -1,5 +1,9 @@ # Release History: opentelemetry-instrumentation-action_mailer +### v0.2.0 / 2024-10-22 + +* ADDED: Subscribe to process.action_mailer notifications + ### v0.1.0 / 2024-05-13 Initial release. diff --git a/instrumentation/action_mailer/lib/opentelemetry/instrumentation/action_mailer/version.rb b/instrumentation/action_mailer/lib/opentelemetry/instrumentation/action_mailer/version.rb index 20756b5f2..ff958a4cc 100644 --- a/instrumentation/action_mailer/lib/opentelemetry/instrumentation/action_mailer/version.rb +++ b/instrumentation/action_mailer/lib/opentelemetry/instrumentation/action_mailer/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Instrumentation module ActionMailer - VERSION = '0.1.0' + VERSION = '0.2.0' end end end diff --git a/instrumentation/active_record/CHANGELOG.md b/instrumentation/active_record/CHANGELOG.md index e78491912..1d9746ce9 100644 --- a/instrumentation/active_record/CHANGELOG.md +++ b/instrumentation/active_record/CHANGELOG.md @@ -1,8 +1,13 @@ # Release History: opentelemetry-instrumentation-active_record +### v0.8.0 / 2024-10-22 + +* BREAKING CHANGE: Rename Active Record find_by_sql spans to query +* FIXED: Emit Active Record query spans for Rails 7.0+ + ### v0.7.4 / 2024-08-19 -* FIXED: Use ActiveSupport from top-level namespace (NoMethodError on_load) +* FIXED: Use ActiveSupport from top-level namespace (NoMethodError on_load) ### v0.7.3 / 2024-08-15 @@ -32,38 +37,38 @@ ### v0.6.1 / 2023-06-05 -* FIXED: Base config options +* FIXED: Base config options ### v0.6.0 / 2023-04-17 -* BREAKING CHANGE: Drop support for EoL Ruby 2.7 +* BREAKING CHANGE: Drop support for EoL Ruby 2.7 -* ADDED: Drop support for EoL Ruby 2.7 +* ADDED: Drop support for EoL Ruby 2.7 ### v0.5.0 / 2023-02-01 -* BREAKING CHANGE: Drop Rails 5 Support +* BREAKING CHANGE: Drop Rails 5 Support -* ADDED: Drop Rails 5 Support +* ADDED: Drop Rails 5 Support ### v0.4.1 / 2023-01-14 -* DOCS: Fix gem homepage -* DOCS: More gem documentation fixes +* DOCS: Fix gem homepage +* DOCS: More gem documentation fixes ### v0.4.0 / 2022-06-09 * Upgrading Base dependency version -* FIXED: Broken test file requirements +* FIXED: Broken test file requirements ### v0.3.0 / 2022-05-02 -* ADDED: Make ActiveRecord 7 compatible -* FIXED: RubyGems Fallback +* ADDED: Make ActiveRecord 7 compatible +* FIXED: RubyGems Fallback ### v0.2.2 / 2021-12-01 -* FIXED: Add max supported version for active record +* FIXED: Add max supported version for active record ### v0.2.1 / 2021-09-29 @@ -71,8 +76,8 @@ ### v0.2.0 / 2021-09-29 -* ADDED: Trace update_all and delete_all calls in ActiveRecord -* FIXED: Remove Active Record instantiation patch +* ADDED: Trace update_all and delete_all calls in ActiveRecord +* FIXED: Remove Active Record instantiation patch ### v0.1.1 / 2021-08-12 diff --git a/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/version.rb b/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/version.rb index 8726c55e3..1f42c3003 100644 --- a/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/version.rb +++ b/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Instrumentation module ActiveRecord - VERSION = '0.7.4' + VERSION = '0.8.0' end end end diff --git a/instrumentation/all/CHANGELOG.md b/instrumentation/all/CHANGELOG.md index 459ab7e2b..2864061ee 100644 --- a/instrumentation/all/CHANGELOG.md +++ b/instrumentation/all/CHANGELOG.md @@ -1,5 +1,11 @@ # Release History: opentelemetry-instrumentation-all +### v0.67.0 / 2024-10-22 + +* BREAKING CHANGE: Rename Active Record find_by_sql spans to query +* FIXED: Emit Active Record query spans for Rails 7.0+ +* ADDED: Subscribe to process.action_mailer notifications + ### v0.66.0 / 2024-10-08 * ADDED: Integration with V3 telemetry provider for the aws-sdk diff --git a/instrumentation/all/lib/opentelemetry/instrumentation/all/version.rb b/instrumentation/all/lib/opentelemetry/instrumentation/all/version.rb index c05a4c33d..83c44deeb 100644 --- a/instrumentation/all/lib/opentelemetry/instrumentation/all/version.rb +++ b/instrumentation/all/lib/opentelemetry/instrumentation/all/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Instrumentation module All - VERSION = '0.66.0' + VERSION = '0.67.0' end end end diff --git a/instrumentation/all/opentelemetry-instrumentation-all.gemspec b/instrumentation/all/opentelemetry-instrumentation-all.gemspec index bccb40e24..20bd4f537 100644 --- a/instrumentation/all/opentelemetry-instrumentation-all.gemspec +++ b/instrumentation/all/opentelemetry-instrumentation-all.gemspec @@ -50,7 +50,7 @@ Gem::Specification.new do |spec| spec.add_dependency 'opentelemetry-instrumentation-que', '~> 0.8.0' spec.add_dependency 'opentelemetry-instrumentation-racecar', '~> 0.3.0' spec.add_dependency 'opentelemetry-instrumentation-rack', '~> 0.24.0' - spec.add_dependency 'opentelemetry-instrumentation-rails', '~> 0.31.0' + spec.add_dependency 'opentelemetry-instrumentation-rails', '~> 0.32.0' spec.add_dependency 'opentelemetry-instrumentation-rake', '~> 0.2.1' spec.add_dependency 'opentelemetry-instrumentation-rdkafka', '~> 0.4.0' spec.add_dependency 'opentelemetry-instrumentation-redis', '~> 0.25.1' diff --git a/instrumentation/rails/CHANGELOG.md b/instrumentation/rails/CHANGELOG.md index f3a462ef8..2ff3b0533 100644 --- a/instrumentation/rails/CHANGELOG.md +++ b/instrumentation/rails/CHANGELOG.md @@ -1,5 +1,11 @@ # Release History: opentelemetry-instrumentation-rails +### v0.32.0 / 2024-10-22 + +* BREAKING CHANGE: Rename Active Record find_by_sql spans to query +* FIXED: Emit Active Record query spans for Rails 7.0+ +* ADDED: Subscribe to process.action_mailer notifications + ### v0.31.2 / 2024-08-15 * FIXED: Rails instrumentation should load ActiveJob instrumentation diff --git a/instrumentation/rails/Gemfile b/instrumentation/rails/Gemfile index 198c4eff8..2c08ce501 100644 --- a/instrumentation/rails/Gemfile +++ b/instrumentation/rails/Gemfile @@ -11,10 +11,11 @@ gemspec group :test, :development do gem 'pry-byebug' gem 'opentelemetry-instrumentation-base', path: '../base' - gem 'opentelemetry-instrumentation-action_pack', path: '../action_pack' - gem 'opentelemetry-instrumentation-action_view', path: '../action_view' gem 'opentelemetry-instrumentation-active_job', path: '../active_job' + gem 'opentelemetry-instrumentation-action_mailer', path: '../action_mailer' + gem 'opentelemetry-instrumentation-action_pack', path: '../action_pack' gem 'opentelemetry-instrumentation-active_record', path: '../active_record' gem 'opentelemetry-instrumentation-active_support', path: '../active_support' + gem 'opentelemetry-instrumentation-action_view', path: '../action_view' gem 'opentelemetry-instrumentation-rack', path: '../rack' end diff --git a/instrumentation/rails/lib/opentelemetry/instrumentation/rails/version.rb b/instrumentation/rails/lib/opentelemetry/instrumentation/rails/version.rb index 490c785c4..f5ddd41cb 100644 --- a/instrumentation/rails/lib/opentelemetry/instrumentation/rails/version.rb +++ b/instrumentation/rails/lib/opentelemetry/instrumentation/rails/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Instrumentation module Rails - VERSION = '0.31.2' + VERSION = '0.32.0' end end end diff --git a/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec b/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec index 3cd4e629d..914edc9ab 100644 --- a/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec +++ b/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec @@ -26,11 +26,11 @@ Gem::Specification.new do |spec| spec.required_ruby_version = '>= 3.0' spec.add_dependency 'opentelemetry-api', '~> 1.0' - spec.add_dependency 'opentelemetry-instrumentation-action_mailer', '~> 0.1.0' + spec.add_dependency 'opentelemetry-instrumentation-action_mailer', '~> 0.2.0' spec.add_dependency 'opentelemetry-instrumentation-action_pack', '~> 0.9.0' spec.add_dependency 'opentelemetry-instrumentation-action_view', '~> 0.7.0' spec.add_dependency 'opentelemetry-instrumentation-active_job', '~> 0.7.0' - spec.add_dependency 'opentelemetry-instrumentation-active_record', '~> 0.7.0' + spec.add_dependency 'opentelemetry-instrumentation-active_record', '~> 0.8.0' spec.add_dependency 'opentelemetry-instrumentation-active_support', '~> 0.6.0' spec.add_dependency 'opentelemetry-instrumentation-base', '~> 0.22.1' From 5c647b56c2794c137c77a28c17b4bac1ec82a5bc Mon Sep 17 00:00:00 2001 From: Jean-Philippe Doyle Date: Wed, 23 Oct 2024 15:34:37 -0400 Subject: [PATCH 37/58] feat: Set span error only for 5xx response range (#1196) feat: Sets span error only for 5xx response range This also avoids setting span in error when a Rails ActionCable hijacked response returns a -1 status code Co-authored-by: Ariel Valentin --- .../rack/middlewares/event_handler.rb | 3 +-- .../rack/middlewares/tracer_middleware.rb | 2 +- .../rack/middlewares/event_handler_test.rb | 13 +++++++++++++ .../rack/middlewares/tracer_middleware_test.rb | 13 +++++++++++++ 4 files changed, 28 insertions(+), 3 deletions(-) diff --git a/instrumentation/rack/lib/opentelemetry/instrumentation/rack/middlewares/event_handler.rb b/instrumentation/rack/lib/opentelemetry/instrumentation/rack/middlewares/event_handler.rb index 5475a4fc5..a77448cb7 100644 --- a/instrumentation/rack/lib/opentelemetry/instrumentation/rack/middlewares/event_handler.rb +++ b/instrumentation/rack/lib/opentelemetry/instrumentation/rack/middlewares/event_handler.rb @@ -43,7 +43,6 @@ class EventHandler include ::Rack::Events::Abstract OTEL_TOKEN_AND_SPAN = 'otel.rack.token_and_span' - GOOD_HTTP_STATUSES = (100..499) # Creates a server span for this current request using the incoming parent context # and registers them as the {current_span} @@ -208,7 +207,7 @@ def detach_context(request) end def add_response_attributes(span, response) - span.status = OpenTelemetry::Trace::Status.error unless GOOD_HTTP_STATUSES.include?(response.status.to_i) + span.status = OpenTelemetry::Trace::Status.error if response.server_error? attributes = extract_response_attributes(response) span.add_attributes(attributes) rescue StandardError => e diff --git a/instrumentation/rack/lib/opentelemetry/instrumentation/rack/middlewares/tracer_middleware.rb b/instrumentation/rack/lib/opentelemetry/instrumentation/rack/middlewares/tracer_middleware.rb index 608728ac6..e6aceba7d 100644 --- a/instrumentation/rack/lib/opentelemetry/instrumentation/rack/middlewares/tracer_middleware.rb +++ b/instrumentation/rack/lib/opentelemetry/instrumentation/rack/middlewares/tracer_middleware.rb @@ -152,7 +152,7 @@ def create_request_span_name(request_uri_or_path_info, env) end def set_attributes_after_request(span, status, headers, _response) - span.status = OpenTelemetry::Trace::Status.error unless (100..499).cover?(status.to_i) + span.status = OpenTelemetry::Trace::Status.error if (500..599).cover?(status.to_i) span.set_attribute('http.status_code', status) # NOTE: if data is available, it would be good to do this: diff --git a/instrumentation/rack/test/opentelemetry/instrumentation/rack/middlewares/event_handler_test.rb b/instrumentation/rack/test/opentelemetry/instrumentation/rack/middlewares/event_handler_test.rb index b106a5d0d..afb254bca 100644 --- a/instrumentation/rack/test/opentelemetry/instrumentation/rack/middlewares/event_handler_test.rb +++ b/instrumentation/rack/test/opentelemetry/instrumentation/rack/middlewares/event_handler_test.rb @@ -105,6 +105,19 @@ _(proxy_event).must_be_nil end + describe 'with a hijacked response' do + let(:service) do + lambda do |env| + env['rack.hijack?'] = true + [-1, {}, []] + end + end + + it 'sets the span status to "unset"' do + _(rack_span.status.code).must_equal OpenTelemetry::Trace::Status::UNSET + end + end + describe 'when baggage is set' do let(:headers) do Hash( diff --git a/instrumentation/rack/test/opentelemetry/instrumentation/rack/middlewares/tracer_middleware_test.rb b/instrumentation/rack/test/opentelemetry/instrumentation/rack/middlewares/tracer_middleware_test.rb index 89c68c328..b17f60ed9 100644 --- a/instrumentation/rack/test/opentelemetry/instrumentation/rack/middlewares/tracer_middleware_test.rb +++ b/instrumentation/rack/test/opentelemetry/instrumentation/rack/middlewares/tracer_middleware_test.rb @@ -72,6 +72,19 @@ _(first_span.status.code).must_equal OpenTelemetry::Trace::Status::UNSET end + describe 'with a hijacked response' do + let(:app) do + lambda do |env| + env['rack.hijack?'] = true + [-1, {}, []] + end + end + + it 'sets the span status to "unset"' do + _(first_span.status.code).must_equal OpenTelemetry::Trace::Status::UNSET + end + end + it 'has no parent' do _(first_span.parent_span_id).must_equal OpenTelemetry::Trace::INVALID_SPAN_ID end From 75836ce6e5f66f14b93d94924df6843279cc0c31 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Wed, 23 Oct 2024 15:34:47 -0500 Subject: [PATCH 38/58] release: Release opentelemetry-instrumentation-rack 0.25.0 (was 0.24.6) (#1212) --- instrumentation/all/CHANGELOG.md | 4 ++++ .../all/lib/opentelemetry/instrumentation/all/version.rb | 2 +- instrumentation/all/opentelemetry-instrumentation-all.gemspec | 2 +- instrumentation/rack/CHANGELOG.md | 4 ++++ .../rack/lib/opentelemetry/instrumentation/rack/version.rb | 2 +- 5 files changed, 11 insertions(+), 3 deletions(-) diff --git a/instrumentation/all/CHANGELOG.md b/instrumentation/all/CHANGELOG.md index 2864061ee..8bc1cd95a 100644 --- a/instrumentation/all/CHANGELOG.md +++ b/instrumentation/all/CHANGELOG.md @@ -1,5 +1,9 @@ # Release History: opentelemetry-instrumentation-all +### v0.68.0 / 2024-10-23 + +* ADDED: Set span error only for 5xx response range + ### v0.67.0 / 2024-10-22 * BREAKING CHANGE: Rename Active Record find_by_sql spans to query diff --git a/instrumentation/all/lib/opentelemetry/instrumentation/all/version.rb b/instrumentation/all/lib/opentelemetry/instrumentation/all/version.rb index 83c44deeb..be8895ff5 100644 --- a/instrumentation/all/lib/opentelemetry/instrumentation/all/version.rb +++ b/instrumentation/all/lib/opentelemetry/instrumentation/all/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Instrumentation module All - VERSION = '0.67.0' + VERSION = '0.68.0' end end end diff --git a/instrumentation/all/opentelemetry-instrumentation-all.gemspec b/instrumentation/all/opentelemetry-instrumentation-all.gemspec index 20bd4f537..509b017fa 100644 --- a/instrumentation/all/opentelemetry-instrumentation-all.gemspec +++ b/instrumentation/all/opentelemetry-instrumentation-all.gemspec @@ -49,7 +49,7 @@ Gem::Specification.new do |spec| spec.add_dependency 'opentelemetry-instrumentation-pg', '~> 0.29.0' spec.add_dependency 'opentelemetry-instrumentation-que', '~> 0.8.0' spec.add_dependency 'opentelemetry-instrumentation-racecar', '~> 0.3.0' - spec.add_dependency 'opentelemetry-instrumentation-rack', '~> 0.24.0' + spec.add_dependency 'opentelemetry-instrumentation-rack', '~> 0.25.0' spec.add_dependency 'opentelemetry-instrumentation-rails', '~> 0.32.0' spec.add_dependency 'opentelemetry-instrumentation-rake', '~> 0.2.1' spec.add_dependency 'opentelemetry-instrumentation-rdkafka', '~> 0.4.0' diff --git a/instrumentation/rack/CHANGELOG.md b/instrumentation/rack/CHANGELOG.md index 2f82b82fa..7fa9fe445 100644 --- a/instrumentation/rack/CHANGELOG.md +++ b/instrumentation/rack/CHANGELOG.md @@ -1,5 +1,9 @@ # Release History: opentelemetry-instrumentation-rack +### v0.25.0 / 2024-10-23 + +* ADDED: Set span error only for 5xx response range + ### v0.24.6 / 2024-07-23 * DOCS: Add cspell to CI diff --git a/instrumentation/rack/lib/opentelemetry/instrumentation/rack/version.rb b/instrumentation/rack/lib/opentelemetry/instrumentation/rack/version.rb index f958c372f..50e682692 100644 --- a/instrumentation/rack/lib/opentelemetry/instrumentation/rack/version.rb +++ b/instrumentation/rack/lib/opentelemetry/instrumentation/rack/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Instrumentation module Rack - VERSION = '0.24.6' + VERSION = '0.25.0' end end end From fcb40dab71f2928891e463b9eec23e94185d4e2d Mon Sep 17 00:00:00 2001 From: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com> Date: Wed, 23 Oct 2024 17:07:35 -0700 Subject: [PATCH 39/58] chore: Update rubocop from 1.66.0 to 1.67.0 (#1207) --- Gemfile | 2 +- helpers/mysql/opentelemetry-helpers-mysql.gemspec | 2 +- .../opentelemetry-helpers-sql-obfuscation.gemspec | 2 +- .../opentelemetry-instrumentation-action_mailer.gemspec | 2 +- .../opentelemetry-instrumentation-action_pack.gemspec | 2 +- .../opentelemetry-instrumentation-action_view.gemspec | 2 +- .../active_job/opentelemetry-instrumentation-active_job.gemspec | 2 +- ...entelemetry-instrumentation-active_model_serializers.gemspec | 2 +- .../opentelemetry-instrumentation-active_record.gemspec | 2 +- .../opentelemetry-instrumentation-active_support.gemspec | 2 +- instrumentation/all/opentelemetry-instrumentation-all.gemspec | 2 +- .../aws_lambda/opentelemetry-instrumentation-aws_lambda.gemspec | 2 +- .../aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec | 2 +- instrumentation/base/opentelemetry-instrumentation-base.gemspec | 2 +- .../bunny/opentelemetry-instrumentation-bunny.gemspec | 2 +- .../opentelemetry-instrumentation-concurrent_ruby.gemspec | 2 +- .../dalli/opentelemetry-instrumentation-dalli.gemspec | 2 +- .../opentelemetry-instrumentation-delayed_job.gemspec | 2 +- .../ethon/opentelemetry-instrumentation-ethon.gemspec | 2 +- .../excon/opentelemetry-instrumentation-excon.gemspec | 2 +- .../faraday/opentelemetry-instrumentation-faraday.gemspec | 2 +- .../grape/opentelemetry-instrumentation-grape.gemspec | 2 +- .../graphql/opentelemetry-instrumentation-graphql.gemspec | 2 +- instrumentation/gruf/opentelemetry-instrumentation-gruf.gemspec | 2 +- instrumentation/http/opentelemetry-instrumentation-http.gemspec | 2 +- .../opentelemetry-instrumentation-http_client.gemspec | 2 +- .../httpx/opentelemetry-instrumentation-httpx.gemspec | 2 +- .../koala/opentelemetry-instrumentation-koala.gemspec | 2 +- instrumentation/lmdb/opentelemetry-instrumentation-lmdb.gemspec | 2 +- .../mongo/opentelemetry-instrumentation-mongo.gemspec | 2 +- .../mysql2/opentelemetry-instrumentation-mysql2.gemspec | 2 +- .../net_http/opentelemetry-instrumentation-net_http.gemspec | 2 +- instrumentation/pg/opentelemetry-instrumentation-pg.gemspec | 2 +- instrumentation/que/opentelemetry-instrumentation-que.gemspec | 2 +- .../racecar/opentelemetry-instrumentation-racecar.gemspec | 2 +- instrumentation/rack/opentelemetry-instrumentation-rack.gemspec | 2 +- .../rails/opentelemetry-instrumentation-rails.gemspec | 2 +- instrumentation/rake/opentelemetry-instrumentation-rake.gemspec | 2 +- .../rdkafka/opentelemetry-instrumentation-rdkafka.gemspec | 2 +- .../redis/opentelemetry-instrumentation-redis.gemspec | 2 +- .../resque/opentelemetry-instrumentation-resque.gemspec | 2 +- .../restclient/opentelemetry-instrumentation-restclient.gemspec | 2 +- .../rspec/opentelemetry-instrumentation-rspec.gemspec | 2 +- .../ruby_kafka/opentelemetry-instrumentation-ruby_kafka.gemspec | 2 +- .../sidekiq/opentelemetry-instrumentation-sidekiq.gemspec | 2 +- .../sinatra/opentelemetry-instrumentation-sinatra.gemspec | 2 +- .../trilogy/opentelemetry-instrumentation-trilogy.gemspec | 2 +- processor/baggage/opentelemetry-processor-baggage.gemspec | 2 +- propagator/ottrace/opentelemetry-propagator-ottrace.gemspec | 2 +- propagator/vitess/opentelemetry-propagator-vitess.gemspec | 2 +- propagator/xray/opentelemetry-propagator-xray.gemspec | 2 +- resources/azure/opentelemetry-resource-detector-azure.gemspec | 2 +- .../container/opentelemetry-resource-detector-container.gemspec | 2 +- ...pentelemetry-resource-detector-google_cloud_platform.gemspec | 2 +- 54 files changed, 54 insertions(+), 54 deletions(-) diff --git a/Gemfile b/Gemfile index be94fd2e5..2f648ce72 100644 --- a/Gemfile +++ b/Gemfile @@ -7,5 +7,5 @@ source 'https://rubygems.org' gem 'rake', '~> 13.0' -gem 'rubocop', '~> 1.66.0' +gem 'rubocop', '~> 1.67.0' gem 'rubocop-performance', '~> 1.21.0' diff --git a/helpers/mysql/opentelemetry-helpers-mysql.gemspec b/helpers/mysql/opentelemetry-helpers-mysql.gemspec index 5279d529c..ecbcdfd0f 100644 --- a/helpers/mysql/opentelemetry-helpers-mysql.gemspec +++ b/helpers/mysql/opentelemetry-helpers-mysql.gemspec @@ -32,7 +32,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/helpers/sql-obfuscation/opentelemetry-helpers-sql-obfuscation.gemspec b/helpers/sql-obfuscation/opentelemetry-helpers-sql-obfuscation.gemspec index 1b1ee1906..64b691d90 100644 --- a/helpers/sql-obfuscation/opentelemetry-helpers-sql-obfuscation.gemspec +++ b/helpers/sql-obfuscation/opentelemetry-helpers-sql-obfuscation.gemspec @@ -31,7 +31,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'yard', '~> 0.9' spec.add_development_dependency 'yard-doctest', '~> 0.1.6' diff --git a/instrumentation/action_mailer/opentelemetry-instrumentation-action_mailer.gemspec b/instrumentation/action_mailer/opentelemetry-instrumentation-action_mailer.gemspec index df2373c87..c0b3d645e 100644 --- a/instrumentation/action_mailer/opentelemetry-instrumentation-action_mailer.gemspec +++ b/instrumentation/action_mailer/opentelemetry-instrumentation-action_mailer.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/action_pack/opentelemetry-instrumentation-action_pack.gemspec b/instrumentation/action_pack/opentelemetry-instrumentation-action_pack.gemspec index 3218d7075..dc1854bd4 100644 --- a/instrumentation/action_pack/opentelemetry-instrumentation-action_pack.gemspec +++ b/instrumentation/action_pack/opentelemetry-instrumentation-action_pack.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rails', '>= 6.1' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/action_view/opentelemetry-instrumentation-action_view.gemspec b/instrumentation/action_view/opentelemetry-instrumentation-action_view.gemspec index 88d93245e..10a331ab4 100644 --- a/instrumentation/action_view/opentelemetry-instrumentation-action_view.gemspec +++ b/instrumentation/action_view/opentelemetry-instrumentation-action_view.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rails', '>= 6.1' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/active_job/opentelemetry-instrumentation-active_job.gemspec b/instrumentation/active_job/opentelemetry-instrumentation-active_job.gemspec index abfbd6057..88624fe76 100644 --- a/instrumentation/active_job/opentelemetry-instrumentation-active_job.gemspec +++ b/instrumentation/active_job/opentelemetry-instrumentation-active_job.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/active_model_serializers/opentelemetry-instrumentation-active_model_serializers.gemspec b/instrumentation/active_model_serializers/opentelemetry-instrumentation-active_model_serializers.gemspec index 0ddac5cf5..1dd86fc4b 100644 --- a/instrumentation/active_model_serializers/opentelemetry-instrumentation-active_model_serializers.gemspec +++ b/instrumentation/active_model_serializers/opentelemetry-instrumentation-active_model_serializers.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/active_record/opentelemetry-instrumentation-active_record.gemspec b/instrumentation/active_record/opentelemetry-instrumentation-active_record.gemspec index fdd43f1a5..248f23764 100644 --- a/instrumentation/active_record/opentelemetry-instrumentation-active_record.gemspec +++ b/instrumentation/active_record/opentelemetry-instrumentation-active_record.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/active_support/opentelemetry-instrumentation-active_support.gemspec b/instrumentation/active_support/opentelemetry-instrumentation-active_support.gemspec index eb596dec1..438a02994 100644 --- a/instrumentation/active_support/opentelemetry-instrumentation-active_support.gemspec +++ b/instrumentation/active_support/opentelemetry-instrumentation-active_support.gemspec @@ -39,7 +39,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rails', '>= 6.1' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/all/opentelemetry-instrumentation-all.gemspec b/instrumentation/all/opentelemetry-instrumentation-all.gemspec index 509b017fa..8810c3e09 100644 --- a/instrumentation/all/opentelemetry-instrumentation-all.gemspec +++ b/instrumentation/all/opentelemetry-instrumentation-all.gemspec @@ -66,7 +66,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'bundler', '~> 2.4' spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/aws_lambda/opentelemetry-instrumentation-aws_lambda.gemspec b/instrumentation/aws_lambda/opentelemetry-instrumentation-aws_lambda.gemspec index 9bf702871..52955bf62 100644 --- a/instrumentation/aws_lambda/opentelemetry-instrumentation-aws_lambda.gemspec +++ b/instrumentation/aws_lambda/opentelemetry-instrumentation-aws_lambda.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'pry' spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec b/instrumentation/aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec index 7cb853d52..0b94e325c 100644 --- a/instrumentation/aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec +++ b/instrumentation/aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec @@ -37,7 +37,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'pry' spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/base/opentelemetry-instrumentation-base.gemspec b/instrumentation/base/opentelemetry-instrumentation-base.gemspec index 4933ab7c4..218aaab50 100644 --- a/instrumentation/base/opentelemetry-instrumentation-base.gemspec +++ b/instrumentation/base/opentelemetry-instrumentation-base.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/bunny/opentelemetry-instrumentation-bunny.gemspec b/instrumentation/bunny/opentelemetry-instrumentation-bunny.gemspec index 6fe7ea968..bb42ce52f 100644 --- a/instrumentation/bunny/opentelemetry-instrumentation-bunny.gemspec +++ b/instrumentation/bunny/opentelemetry-instrumentation-bunny.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/concurrent_ruby/opentelemetry-instrumentation-concurrent_ruby.gemspec b/instrumentation/concurrent_ruby/opentelemetry-instrumentation-concurrent_ruby.gemspec index c7c3cfd75..635aef38c 100644 --- a/instrumentation/concurrent_ruby/opentelemetry-instrumentation-concurrent_ruby.gemspec +++ b/instrumentation/concurrent_ruby/opentelemetry-instrumentation-concurrent_ruby.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/dalli/opentelemetry-instrumentation-dalli.gemspec b/instrumentation/dalli/opentelemetry-instrumentation-dalli.gemspec index 6ac5395a2..fbd399489 100644 --- a/instrumentation/dalli/opentelemetry-instrumentation-dalli.gemspec +++ b/instrumentation/dalli/opentelemetry-instrumentation-dalli.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/delayed_job/opentelemetry-instrumentation-delayed_job.gemspec b/instrumentation/delayed_job/opentelemetry-instrumentation-delayed_job.gemspec index 7a2f90cdd..4970e4140 100644 --- a/instrumentation/delayed_job/opentelemetry-instrumentation-delayed_job.gemspec +++ b/instrumentation/delayed_job/opentelemetry-instrumentation-delayed_job.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'sqlite3' diff --git a/instrumentation/ethon/opentelemetry-instrumentation-ethon.gemspec b/instrumentation/ethon/opentelemetry-instrumentation-ethon.gemspec index 2a4aa2ab1..f4fc45bd6 100644 --- a/instrumentation/ethon/opentelemetry-instrumentation-ethon.gemspec +++ b/instrumentation/ethon/opentelemetry-instrumentation-ethon.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/excon/opentelemetry-instrumentation-excon.gemspec b/instrumentation/excon/opentelemetry-instrumentation-excon.gemspec index bf532e5d2..d97079859 100644 --- a/instrumentation/excon/opentelemetry-instrumentation-excon.gemspec +++ b/instrumentation/excon/opentelemetry-instrumentation-excon.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/faraday/opentelemetry-instrumentation-faraday.gemspec b/instrumentation/faraday/opentelemetry-instrumentation-faraday.gemspec index 3bcbe0b08..ef630138c 100644 --- a/instrumentation/faraday/opentelemetry-instrumentation-faraday.gemspec +++ b/instrumentation/faraday/opentelemetry-instrumentation-faraday.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/grape/opentelemetry-instrumentation-grape.gemspec b/instrumentation/grape/opentelemetry-instrumentation-grape.gemspec index 992bd08a7..b5b885fe4 100644 --- a/instrumentation/grape/opentelemetry-instrumentation-grape.gemspec +++ b/instrumentation/grape/opentelemetry-instrumentation-grape.gemspec @@ -38,7 +38,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rack-test' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/graphql/opentelemetry-instrumentation-graphql.gemspec b/instrumentation/graphql/opentelemetry-instrumentation-graphql.gemspec index 661ab2810..c8e9f86a4 100644 --- a/instrumentation/graphql/opentelemetry-instrumentation-graphql.gemspec +++ b/instrumentation/graphql/opentelemetry-instrumentation-graphql.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/gruf/opentelemetry-instrumentation-gruf.gemspec b/instrumentation/gruf/opentelemetry-instrumentation-gruf.gemspec index 24fe7727e..ead698e1d 100644 --- a/instrumentation/gruf/opentelemetry-instrumentation-gruf.gemspec +++ b/instrumentation/gruf/opentelemetry-instrumentation-gruf.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.0' spec.add_development_dependency 'opentelemetry-test-helpers' spec.add_development_dependency 'rake', '~> 12.3.3' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/http/opentelemetry-instrumentation-http.gemspec b/instrumentation/http/opentelemetry-instrumentation-http.gemspec index b157b2827..f8deae16a 100644 --- a/instrumentation/http/opentelemetry-instrumentation-http.gemspec +++ b/instrumentation/http/opentelemetry-instrumentation-http.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/http_client/opentelemetry-instrumentation-http_client.gemspec b/instrumentation/http_client/opentelemetry-instrumentation-http_client.gemspec index 30cd1c4c5..60cd751e8 100644 --- a/instrumentation/http_client/opentelemetry-instrumentation-http_client.gemspec +++ b/instrumentation/http_client/opentelemetry-instrumentation-http_client.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/httpx/opentelemetry-instrumentation-httpx.gemspec b/instrumentation/httpx/opentelemetry-instrumentation-httpx.gemspec index 54e8139e2..7b0367aca 100644 --- a/instrumentation/httpx/opentelemetry-instrumentation-httpx.gemspec +++ b/instrumentation/httpx/opentelemetry-instrumentation-httpx.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/koala/opentelemetry-instrumentation-koala.gemspec b/instrumentation/koala/opentelemetry-instrumentation-koala.gemspec index 90275d7d5..c80687d62 100644 --- a/instrumentation/koala/opentelemetry-instrumentation-koala.gemspec +++ b/instrumentation/koala/opentelemetry-instrumentation-koala.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/lmdb/opentelemetry-instrumentation-lmdb.gemspec b/instrumentation/lmdb/opentelemetry-instrumentation-lmdb.gemspec index a800b74ea..ffea2c1a4 100644 --- a/instrumentation/lmdb/opentelemetry-instrumentation-lmdb.gemspec +++ b/instrumentation/lmdb/opentelemetry-instrumentation-lmdb.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/mongo/opentelemetry-instrumentation-mongo.gemspec b/instrumentation/mongo/opentelemetry-instrumentation-mongo.gemspec index c9710a4ea..5f6180f5d 100644 --- a/instrumentation/mongo/opentelemetry-instrumentation-mongo.gemspec +++ b/instrumentation/mongo/opentelemetry-instrumentation-mongo.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'pry' spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/mysql2/opentelemetry-instrumentation-mysql2.gemspec b/instrumentation/mysql2/opentelemetry-instrumentation-mysql2.gemspec index 992404fa0..51f644bab 100644 --- a/instrumentation/mysql2/opentelemetry-instrumentation-mysql2.gemspec +++ b/instrumentation/mysql2/opentelemetry-instrumentation-mysql2.gemspec @@ -37,7 +37,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'pry' spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/net_http/opentelemetry-instrumentation-net_http.gemspec b/instrumentation/net_http/opentelemetry-instrumentation-net_http.gemspec index 78cc638fc..5c2826b6b 100644 --- a/instrumentation/net_http/opentelemetry-instrumentation-net_http.gemspec +++ b/instrumentation/net_http/opentelemetry-instrumentation-net_http.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0.1' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/pg/opentelemetry-instrumentation-pg.gemspec b/instrumentation/pg/opentelemetry-instrumentation-pg.gemspec index 9a75c42f4..ddc1d2662 100644 --- a/instrumentation/pg/opentelemetry-instrumentation-pg.gemspec +++ b/instrumentation/pg/opentelemetry-instrumentation-pg.gemspec @@ -37,7 +37,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'pry' spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/que/opentelemetry-instrumentation-que.gemspec b/instrumentation/que/opentelemetry-instrumentation-que.gemspec index f12f24eb5..9d846749b 100644 --- a/instrumentation/que/opentelemetry-instrumentation-que.gemspec +++ b/instrumentation/que/opentelemetry-instrumentation-que.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/racecar/opentelemetry-instrumentation-racecar.gemspec b/instrumentation/racecar/opentelemetry-instrumentation-racecar.gemspec index ec6ff7596..2e01be3b4 100644 --- a/instrumentation/racecar/opentelemetry-instrumentation-racecar.gemspec +++ b/instrumentation/racecar/opentelemetry-instrumentation-racecar.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/rack/opentelemetry-instrumentation-rack.gemspec b/instrumentation/rack/opentelemetry-instrumentation-rack.gemspec index e1feadb7d..7681ad9f6 100644 --- a/instrumentation/rack/opentelemetry-instrumentation-rack.gemspec +++ b/instrumentation/rack/opentelemetry-instrumentation-rack.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec b/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec index 914edc9ab..79bd909da 100644 --- a/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec +++ b/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec @@ -41,7 +41,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rack-test', '~> 2.1.0' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/rake/opentelemetry-instrumentation-rake.gemspec b/instrumentation/rake/opentelemetry-instrumentation-rake.gemspec index a473dfde1..5bb3ee796 100644 --- a/instrumentation/rake/opentelemetry-instrumentation-rake.gemspec +++ b/instrumentation/rake/opentelemetry-instrumentation-rake.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.0' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/rdkafka/opentelemetry-instrumentation-rdkafka.gemspec b/instrumentation/rdkafka/opentelemetry-instrumentation-rdkafka.gemspec index c5d085f92..8133ddcf9 100644 --- a/instrumentation/rdkafka/opentelemetry-instrumentation-rdkafka.gemspec +++ b/instrumentation/rdkafka/opentelemetry-instrumentation-rdkafka.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/redis/opentelemetry-instrumentation-redis.gemspec b/instrumentation/redis/opentelemetry-instrumentation-redis.gemspec index 0c139fcf9..1964d35f6 100644 --- a/instrumentation/redis/opentelemetry-instrumentation-redis.gemspec +++ b/instrumentation/redis/opentelemetry-instrumentation-redis.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/resque/opentelemetry-instrumentation-resque.gemspec b/instrumentation/resque/opentelemetry-instrumentation-resque.gemspec index ba40ebc8d..6799792e9 100644 --- a/instrumentation/resque/opentelemetry-instrumentation-resque.gemspec +++ b/instrumentation/resque/opentelemetry-instrumentation-resque.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/restclient/opentelemetry-instrumentation-restclient.gemspec b/instrumentation/restclient/opentelemetry-instrumentation-restclient.gemspec index ab0e98a7b..c86c37fd2 100644 --- a/instrumentation/restclient/opentelemetry-instrumentation-restclient.gemspec +++ b/instrumentation/restclient/opentelemetry-instrumentation-restclient.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/rspec/opentelemetry-instrumentation-rspec.gemspec b/instrumentation/rspec/opentelemetry-instrumentation-rspec.gemspec index 6c6ba2a5d..bbb39b0af 100644 --- a/instrumentation/rspec/opentelemetry-instrumentation-rspec.gemspec +++ b/instrumentation/rspec/opentelemetry-instrumentation-rspec.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/ruby_kafka/opentelemetry-instrumentation-ruby_kafka.gemspec b/instrumentation/ruby_kafka/opentelemetry-instrumentation-ruby_kafka.gemspec index 50d7e8988..837fc8328 100644 --- a/instrumentation/ruby_kafka/opentelemetry-instrumentation-ruby_kafka.gemspec +++ b/instrumentation/ruby_kafka/opentelemetry-instrumentation-ruby_kafka.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/sidekiq/opentelemetry-instrumentation-sidekiq.gemspec b/instrumentation/sidekiq/opentelemetry-instrumentation-sidekiq.gemspec index 604599935..495001789 100644 --- a/instrumentation/sidekiq/opentelemetry-instrumentation-sidekiq.gemspec +++ b/instrumentation/sidekiq/opentelemetry-instrumentation-sidekiq.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/sinatra/opentelemetry-instrumentation-sinatra.gemspec b/instrumentation/sinatra/opentelemetry-instrumentation-sinatra.gemspec index b727abf57..821f2f9cc 100644 --- a/instrumentation/sinatra/opentelemetry-instrumentation-sinatra.gemspec +++ b/instrumentation/sinatra/opentelemetry-instrumentation-sinatra.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rack-test', '~> 2.1' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/trilogy/opentelemetry-instrumentation-trilogy.gemspec b/instrumentation/trilogy/opentelemetry-instrumentation-trilogy.gemspec index 417a61af7..197ebe6be 100644 --- a/instrumentation/trilogy/opentelemetry-instrumentation-trilogy.gemspec +++ b/instrumentation/trilogy/opentelemetry-instrumentation-trilogy.gemspec @@ -41,7 +41,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/processor/baggage/opentelemetry-processor-baggage.gemspec b/processor/baggage/opentelemetry-processor-baggage.gemspec index d8d6f4978..23a4f0a8a 100644 --- a/processor/baggage/opentelemetry-processor-baggage.gemspec +++ b/processor/baggage/opentelemetry-processor-baggage.gemspec @@ -30,7 +30,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/propagator/ottrace/opentelemetry-propagator-ottrace.gemspec b/propagator/ottrace/opentelemetry-propagator-ottrace.gemspec index 3282ee4d3..bd988a552 100644 --- a/propagator/ottrace/opentelemetry-propagator-ottrace.gemspec +++ b/propagator/ottrace/opentelemetry-propagator-ottrace.gemspec @@ -28,7 +28,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'bundler', '~> 2.4' spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/propagator/vitess/opentelemetry-propagator-vitess.gemspec b/propagator/vitess/opentelemetry-propagator-vitess.gemspec index 2d3295eee..6508b5730 100644 --- a/propagator/vitess/opentelemetry-propagator-vitess.gemspec +++ b/propagator/vitess/opentelemetry-propagator-vitess.gemspec @@ -29,7 +29,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'bundler', '~> 2.4' spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/propagator/xray/opentelemetry-propagator-xray.gemspec b/propagator/xray/opentelemetry-propagator-xray.gemspec index 51803b368..90c1e1602 100644 --- a/propagator/xray/opentelemetry-propagator-xray.gemspec +++ b/propagator/xray/opentelemetry-propagator-xray.gemspec @@ -31,7 +31,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'bundler', '~> 2.4' spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/resources/azure/opentelemetry-resource-detector-azure.gemspec b/resources/azure/opentelemetry-resource-detector-azure.gemspec index 45362a4ea..db5fd4f46 100644 --- a/resources/azure/opentelemetry-resource-detector-azure.gemspec +++ b/resources/azure/opentelemetry-resource-detector-azure.gemspec @@ -30,7 +30,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'bundler', '~> 2.4' spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/resources/container/opentelemetry-resource-detector-container.gemspec b/resources/container/opentelemetry-resource-detector-container.gemspec index a98a0fb7e..dddc2cea5 100644 --- a/resources/container/opentelemetry-resource-detector-container.gemspec +++ b/resources/container/opentelemetry-resource-detector-container.gemspec @@ -30,7 +30,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'bundler', '~> 2.4' spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/resources/google_cloud_platform/opentelemetry-resource-detector-google_cloud_platform.gemspec b/resources/google_cloud_platform/opentelemetry-resource-detector-google_cloud_platform.gemspec index ff176fa07..0261da6aa 100644 --- a/resources/google_cloud_platform/opentelemetry-resource-detector-google_cloud_platform.gemspec +++ b/resources/google_cloud_platform/opentelemetry-resource-detector-google_cloud_platform.gemspec @@ -31,7 +31,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'bundler', '~> 2.4' spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.66.0' + spec.add_development_dependency 'rubocop', '~> 1.67.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17' spec.add_development_dependency 'webmock', '~> 3.24.0' From 5b1c09d2dbbd34cec698eb738fa01503e21db2cd Mon Sep 17 00:00:00 2001 From: Yohei Kitamura <3087402+yoheyk@users.noreply.github.com> Date: Thu, 24 Oct 2024 23:14:13 +0900 Subject: [PATCH 40/58] fix: ActiveJob Propagate baggage information properly when performing (#1214) --- .../active_job/handlers/perform.rb | 7 ++- .../active_job/handlers/perform_test.rb | 56 ++++++++++--------- 2 files changed, 33 insertions(+), 30 deletions(-) diff --git a/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/handlers/perform.rb b/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/handlers/perform.rb index 88141f754..28981c945 100644 --- a/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/handlers/perform.rb +++ b/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/handlers/perform.rb @@ -34,7 +34,7 @@ def start_span(name, _id, payload) span = tracer.start_root_span(span_name, kind: :consumer, attributes: @mapper.call(payload), links: links) end - { span: span, ctx_token: attach_consumer_context(span) } + { span: span, ctx_token: attach_consumer_context(span, parent_context) } end # This method attaches a span to multiple contexts: @@ -42,9 +42,10 @@ def start_span(name, _id, payload) # This is used later to enrich the ingress span in children, e.g. setting span status to error when a child event like `discard` terminates due to an error # 2. Registers the ingress span as the "active" span, which is the default behavior of the SDK. # @param span [OpenTelemetry::Trace::Span] the currently active span used to record the exception and set the status + # @param parent_context [Context] The context to use as the parent for the consumer context # @return [Numeric] Context token that must be detached when finished - def attach_consumer_context(span) - consumer_context = OpenTelemetry::Trace.context_with_span(span) + def attach_consumer_context(span, parent_context) + consumer_context = OpenTelemetry::Trace.context_with_span(span, parent_context: parent_context) internal_context = OpenTelemetry::Instrumentation::ActiveJob.context_with_span(span, parent_context: consumer_context) OpenTelemetry::Context.attach(internal_context) diff --git a/instrumentation/active_job/test/opentelemetry/instrumentation/active_job/handlers/perform_test.rb b/instrumentation/active_job/test/opentelemetry/instrumentation/active_job/handlers/perform_test.rb index de886c206..b2a19bf34 100644 --- a/instrumentation/active_job/test/opentelemetry/instrumentation/active_job/handlers/perform_test.rb +++ b/instrumentation/active_job/test/opentelemetry/instrumentation/active_job/handlers/perform_test.rb @@ -188,21 +188,6 @@ _(process_span.links[0].span_context.span_id).must_equal(publish_span.span_id) end - it 'propagates baggage' do - ctx = OpenTelemetry::Baggage.set_value('testing_baggage', 'it_worked') - OpenTelemetry::Context.with_current(ctx) do - BaggageJob.perform_later - end - - _(publish_span.trace_id).wont_equal(process_span.trace_id) - - _(process_span.total_recorded_links).must_equal(1) - _(process_span.links[0].span_context.trace_id).must_equal(publish_span.trace_id) - _(process_span.links[0].span_context.span_id).must_equal(publish_span.span_id) - - _(process_span.attributes['success']).must_equal(true) - end - describe 'with an async queue adapter' do before do begin @@ -225,6 +210,21 @@ _(process_span.links[0].span_context.trace_id).must_equal(publish_span.trace_id) _(process_span.links[0].span_context.span_id).must_equal(publish_span.span_id) end + + it 'propagates baggage' do + ctx = OpenTelemetry::Baggage.set_value('testing_baggage', 'it_worked') + OpenTelemetry::Context.with_current(ctx) do + BaggageJob.perform_later + end + perform_enqueued_jobs + + _(publish_span.trace_id).wont_equal(process_span.trace_id) + + _(process_span.total_recorded_links).must_equal(1) + _(process_span.links[0].span_context.trace_id).must_equal(publish_span.trace_id) + _(process_span.links[0].span_context.span_id).must_equal(publish_span.span_id) + _(process_span.attributes['success']).must_equal(true) + end end end @@ -251,18 +251,6 @@ _(process_span.parent_span_id).must_equal(publish_span.span_id) end - it 'propagates baggage' do - ctx = OpenTelemetry::Baggage.set_value('testing_baggage', 'it_worked') - OpenTelemetry::Context.with_current(ctx) do - BaggageJob.perform_later - end - _(process_span.total_recorded_links).must_equal(0) - - _(publish_span.trace_id).must_equal(process_span.trace_id) - _(process_span.parent_span_id).must_equal(publish_span.span_id) - _(process_span.attributes['success']).must_equal(true) - end - describe 'with an async queue adapter' do before do begin @@ -284,6 +272,20 @@ _(publish_span.trace_id).must_equal(process_span.trace_id) _(process_span.parent_span_id).must_equal(publish_span.span_id) end + + it 'propagates baggage' do + ctx = OpenTelemetry::Baggage.set_value('testing_baggage', 'it_worked') + OpenTelemetry::Context.with_current(ctx) do + BaggageJob.perform_later + end + perform_enqueued_jobs + + _(process_span.total_recorded_links).must_equal(0) + + _(publish_span.trace_id).must_equal(process_span.trace_id) + _(process_span.parent_span_id).must_equal(publish_span.span_id) + _(process_span.attributes['success']).must_equal(true) + end end end From 9af2b646c1f27c2437fbf1ab91cc277221b36863 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Thu, 24 Oct 2024 10:42:52 -0500 Subject: [PATCH 41/58] release: Release opentelemetry-instrumentation-active_job 0.7.8 (was 0.7.7) (#1215) * release: Release opentelemetry-instrumentation-active_job 0.7.8 (was 0.7.7) * ci: force --------- Co-authored-by: OpenTelemetry Bot <107717825+opentelemetrybot@users.noreply.github.com> Co-authored-by: Ariel Valentin --- instrumentation/active_job/CHANGELOG.md | 4 ++++ .../lib/opentelemetry/instrumentation/active_job/version.rb | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/instrumentation/active_job/CHANGELOG.md b/instrumentation/active_job/CHANGELOG.md index 6bda338c4..7d9e6c941 100644 --- a/instrumentation/active_job/CHANGELOG.md +++ b/instrumentation/active_job/CHANGELOG.md @@ -1,5 +1,9 @@ # Release History: opentelemetry-instrumentation-active_job +### v0.7.8 / 2024-10-24 + +* FIXED: ActiveJob Propagate baggage information properly when performing + ### v0.7.7 / 2024-08-21 * FIXED: Propagate context between enqueue and perform diff --git a/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/version.rb b/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/version.rb index 587255970..5c55ce6dc 100644 --- a/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/version.rb +++ b/instrumentation/active_job/lib/opentelemetry/instrumentation/active_job/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Instrumentation module ActiveJob - VERSION = '0.7.7' + VERSION = '0.7.8' end end end From 2c4f8c9a0f5112cc2b8c7e00cd679d43142029cb Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 31 Oct 2024 02:11:15 +0000 Subject: [PATCH 42/58] chore: bump ruby/setup-ruby from 1.197.0 to 1.198.0 (#1218) * chore: bump ruby/setup-ruby from 1.197.0 to 1.198.0 Bumps [ruby/setup-ruby](https://github.com/ruby/setup-ruby) from 1.197.0 to 1.198.0. - [Release notes](https://github.com/ruby/setup-ruby/releases) - [Changelog](https://github.com/ruby/setup-ruby/blob/master/release.rb) - [Commits](https://github.com/ruby/setup-ruby/compare/v1.197.0...v1.198.0) --- updated-dependencies: - dependency-name: ruby/setup-ruby dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] * squash: you missed a spot --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Ariel Valentin --- .github/actions/test_gem/action.yml | 4 ++-- .github/workflows/installation-tests.yml | 2 +- .github/workflows/release-hook-on-closed.yml | 2 +- .github/workflows/release-hook-on-push.yml | 2 +- .github/workflows/release-perform.yml | 2 +- .github/workflows/release-please.yaml | 2 +- .github/workflows/release-request-weekly.yml | 2 +- .github/workflows/release-request.yml | 2 +- .github/workflows/release-retry.yml | 2 +- 9 files changed, 10 insertions(+), 10 deletions(-) diff --git a/.github/actions/test_gem/action.yml b/.github/actions/test_gem/action.yml index f6637260e..220f01a8e 100644 --- a/.github/actions/test_gem/action.yml +++ b/.github/actions/test_gem/action.yml @@ -66,7 +66,7 @@ runs: # ...but not for appraisals, sadly. - name: Install Ruby ${{ inputs.ruby }} with dependencies if: "${{ steps.setup.outputs.appraisals == 'false' }}" - uses: ruby/setup-ruby@v1.197.0 + uses: ruby/setup-ruby@v1.198.0 with: ruby-version: "${{ inputs.ruby }}" working-directory: "${{ steps.setup.outputs.gem_dir }}" @@ -77,7 +77,7 @@ runs: # If we're using appraisals, do it all manually. - name: Install Ruby ${{ inputs.ruby }} without dependencies if: "${{ steps.setup.outputs.appraisals == 'true' }}" - uses: ruby/setup-ruby@v1.197.0 + uses: ruby/setup-ruby@v1.198.0 with: ruby-version: "${{ inputs.ruby }}" bundler: "latest" diff --git a/.github/workflows/installation-tests.yml b/.github/workflows/installation-tests.yml index 87e378b80..f6c6189ec 100644 --- a/.github/workflows/installation-tests.yml +++ b/.github/workflows/installation-tests.yml @@ -25,7 +25,7 @@ jobs: - uses: actions/checkout@v4 # ATTENTION: Dependabot does not know how to update shared actions file. # If you see it update setup-ruby here also update it as part of actions/test_gem/action.yml - - uses: ruby/setup-ruby@v1.197.0 + - uses: ruby/setup-ruby@v1.198.0 with: ruby-version: ${{ matrix.ruby-version }} - name: "Install Latest Gem Versions on ${{ matrix.ruby-version }}" diff --git a/.github/workflows/release-hook-on-closed.yml b/.github/workflows/release-hook-on-closed.yml index ea751f2d8..919e52b5d 100644 --- a/.github/workflows/release-hook-on-closed.yml +++ b/.github/workflows/release-hook-on-closed.yml @@ -12,7 +12,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.197.0 + uses: ruby/setup-ruby@v1.198.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-hook-on-push.yml b/.github/workflows/release-hook-on-push.yml index 162c7f7eb..dbe96c3d8 100644 --- a/.github/workflows/release-hook-on-push.yml +++ b/.github/workflows/release-hook-on-push.yml @@ -13,7 +13,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.197.0 + uses: ruby/setup-ruby@v1.198.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-perform.yml b/.github/workflows/release-perform.yml index 794f91414..f8d9ceab8 100644 --- a/.github/workflows/release-perform.yml +++ b/.github/workflows/release-perform.yml @@ -22,7 +22,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.197.0 + uses: ruby/setup-ruby@v1.198.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-please.yaml b/.github/workflows/release-please.yaml index dc39a65cb..cbe0c89ba 100644 --- a/.github/workflows/release-please.yaml +++ b/.github/workflows/release-please.yaml @@ -50,7 +50,7 @@ jobs: chmod 0600 $HOME/.gem/credentials printf -- "---\n:rubygems_api_key: ${GEM_HOST_API_KEY}\n" > $HOME/.gem/credentials - - uses: ruby/setup-ruby@v1.197.0 + - uses: ruby/setup-ruby@v1.198.0 with: ruby-version: "3.0" bundler: latest diff --git a/.github/workflows/release-request-weekly.yml b/.github/workflows/release-request-weekly.yml index 73ea683bf..a298a6aa6 100644 --- a/.github/workflows/release-request-weekly.yml +++ b/.github/workflows/release-request-weekly.yml @@ -12,7 +12,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.197.0 + uses: ruby/setup-ruby@v1.198.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-request.yml b/.github/workflows/release-request.yml index 1e34f9fc5..3990f5e1a 100644 --- a/.github/workflows/release-request.yml +++ b/.github/workflows/release-request.yml @@ -16,7 +16,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.197.0 + uses: ruby/setup-ruby@v1.198.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-retry.yml b/.github/workflows/release-retry.yml index 0a9dcadbe..f3e0d13cf 100644 --- a/.github/workflows/release-retry.yml +++ b/.github/workflows/release-retry.yml @@ -19,7 +19,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.197.0 + uses: ruby/setup-ruby@v1.198.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo From 7ef8f01f1a9de466715152c84c74951951ce9374 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 5 Nov 2024 13:13:14 -0800 Subject: [PATCH 43/58] chore: bump ruby/setup-ruby from 1.198.0 to 1.199.0 (#1220) * chore: bump ruby/setup-ruby from 1.198.0 to 1.199.0 Bumps [ruby/setup-ruby](https://github.com/ruby/setup-ruby) from 1.198.0 to 1.199.0. - [Release notes](https://github.com/ruby/setup-ruby/releases) - [Changelog](https://github.com/ruby/setup-ruby/blob/master/release.rb) - [Commits](https://github.com/ruby/setup-ruby/compare/v1.198.0...v1.199.0) --- updated-dependencies: - dependency-name: ruby/setup-ruby dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] * chore: Bump setup-ruby in test_gem action --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Kayla Reopelle --- .github/actions/test_gem/action.yml | 4 ++-- .github/workflows/installation-tests.yml | 2 +- .github/workflows/release-hook-on-closed.yml | 2 +- .github/workflows/release-hook-on-push.yml | 2 +- .github/workflows/release-perform.yml | 2 +- .github/workflows/release-please.yaml | 2 +- .github/workflows/release-request-weekly.yml | 2 +- .github/workflows/release-request.yml | 2 +- .github/workflows/release-retry.yml | 2 +- 9 files changed, 10 insertions(+), 10 deletions(-) diff --git a/.github/actions/test_gem/action.yml b/.github/actions/test_gem/action.yml index 220f01a8e..dfd3fb834 100644 --- a/.github/actions/test_gem/action.yml +++ b/.github/actions/test_gem/action.yml @@ -66,7 +66,7 @@ runs: # ...but not for appraisals, sadly. - name: Install Ruby ${{ inputs.ruby }} with dependencies if: "${{ steps.setup.outputs.appraisals == 'false' }}" - uses: ruby/setup-ruby@v1.198.0 + uses: ruby/setup-ruby@v1.199.0 with: ruby-version: "${{ inputs.ruby }}" working-directory: "${{ steps.setup.outputs.gem_dir }}" @@ -77,7 +77,7 @@ runs: # If we're using appraisals, do it all manually. - name: Install Ruby ${{ inputs.ruby }} without dependencies if: "${{ steps.setup.outputs.appraisals == 'true' }}" - uses: ruby/setup-ruby@v1.198.0 + uses: ruby/setup-ruby@v1.199.0 with: ruby-version: "${{ inputs.ruby }}" bundler: "latest" diff --git a/.github/workflows/installation-tests.yml b/.github/workflows/installation-tests.yml index f6c6189ec..1280ebb16 100644 --- a/.github/workflows/installation-tests.yml +++ b/.github/workflows/installation-tests.yml @@ -25,7 +25,7 @@ jobs: - uses: actions/checkout@v4 # ATTENTION: Dependabot does not know how to update shared actions file. # If you see it update setup-ruby here also update it as part of actions/test_gem/action.yml - - uses: ruby/setup-ruby@v1.198.0 + - uses: ruby/setup-ruby@v1.199.0 with: ruby-version: ${{ matrix.ruby-version }} - name: "Install Latest Gem Versions on ${{ matrix.ruby-version }}" diff --git a/.github/workflows/release-hook-on-closed.yml b/.github/workflows/release-hook-on-closed.yml index 919e52b5d..d2375ed37 100644 --- a/.github/workflows/release-hook-on-closed.yml +++ b/.github/workflows/release-hook-on-closed.yml @@ -12,7 +12,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.198.0 + uses: ruby/setup-ruby@v1.199.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-hook-on-push.yml b/.github/workflows/release-hook-on-push.yml index dbe96c3d8..31f770693 100644 --- a/.github/workflows/release-hook-on-push.yml +++ b/.github/workflows/release-hook-on-push.yml @@ -13,7 +13,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.198.0 + uses: ruby/setup-ruby@v1.199.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-perform.yml b/.github/workflows/release-perform.yml index f8d9ceab8..be75e17a5 100644 --- a/.github/workflows/release-perform.yml +++ b/.github/workflows/release-perform.yml @@ -22,7 +22,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.198.0 + uses: ruby/setup-ruby@v1.199.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-please.yaml b/.github/workflows/release-please.yaml index cbe0c89ba..581ef32b8 100644 --- a/.github/workflows/release-please.yaml +++ b/.github/workflows/release-please.yaml @@ -50,7 +50,7 @@ jobs: chmod 0600 $HOME/.gem/credentials printf -- "---\n:rubygems_api_key: ${GEM_HOST_API_KEY}\n" > $HOME/.gem/credentials - - uses: ruby/setup-ruby@v1.198.0 + - uses: ruby/setup-ruby@v1.199.0 with: ruby-version: "3.0" bundler: latest diff --git a/.github/workflows/release-request-weekly.yml b/.github/workflows/release-request-weekly.yml index a298a6aa6..f6063d304 100644 --- a/.github/workflows/release-request-weekly.yml +++ b/.github/workflows/release-request-weekly.yml @@ -12,7 +12,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.198.0 + uses: ruby/setup-ruby@v1.199.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-request.yml b/.github/workflows/release-request.yml index 3990f5e1a..210f1c44d 100644 --- a/.github/workflows/release-request.yml +++ b/.github/workflows/release-request.yml @@ -16,7 +16,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.198.0 + uses: ruby/setup-ruby@v1.199.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-retry.yml b/.github/workflows/release-retry.yml index f3e0d13cf..2f42e104b 100644 --- a/.github/workflows/release-retry.yml +++ b/.github/workflows/release-retry.yml @@ -19,7 +19,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.198.0 + uses: ruby/setup-ruby@v1.199.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo From 7f6ff9ad703223ee002dd7566484a00c97b8b7fd Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 13 Nov 2024 17:02:11 -0800 Subject: [PATCH 44/58] chore: bump ruby/setup-ruby from 1.199.0 to 1.202.0 (#1237) * chore: bump ruby/setup-ruby from 1.199.0 to 1.202.0 Bumps [ruby/setup-ruby](https://github.com/ruby/setup-ruby) from 1.199.0 to 1.202.0. - [Release notes](https://github.com/ruby/setup-ruby/releases) - [Changelog](https://github.com/ruby/setup-ruby/blob/master/release.rb) - [Commits](https://github.com/ruby/setup-ruby/compare/v1.199.0...v1.202.0) --- updated-dependencies: - dependency-name: ruby/setup-ruby dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] * chore: Update "Test JRuby" version to 9.4.9.0 * chore: Update test_gem setup-ruby to v1.202.0 --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Kayla Reopelle --- .github/actions/test_gem/action.yml | 4 ++-- .github/workflows/ci-contrib.yml | 8 ++++---- .github/workflows/ci-instrumentation-with-services.yml | 2 +- .github/workflows/ci-instrumentation.yml | 2 +- .github/workflows/installation-tests.yml | 2 +- .github/workflows/release-hook-on-closed.yml | 2 +- .github/workflows/release-hook-on-push.yml | 2 +- .github/workflows/release-perform.yml | 2 +- .github/workflows/release-please.yaml | 2 +- .github/workflows/release-request-weekly.yml | 2 +- .github/workflows/release-request.yml | 2 +- .github/workflows/release-retry.yml | 2 +- 12 files changed, 16 insertions(+), 16 deletions(-) diff --git a/.github/actions/test_gem/action.yml b/.github/actions/test_gem/action.yml index dfd3fb834..0d4feddb8 100644 --- a/.github/actions/test_gem/action.yml +++ b/.github/actions/test_gem/action.yml @@ -66,7 +66,7 @@ runs: # ...but not for appraisals, sadly. - name: Install Ruby ${{ inputs.ruby }} with dependencies if: "${{ steps.setup.outputs.appraisals == 'false' }}" - uses: ruby/setup-ruby@v1.199.0 + uses: ruby/setup-ruby@v1.202.0 with: ruby-version: "${{ inputs.ruby }}" working-directory: "${{ steps.setup.outputs.gem_dir }}" @@ -77,7 +77,7 @@ runs: # If we're using appraisals, do it all manually. - name: Install Ruby ${{ inputs.ruby }} without dependencies if: "${{ steps.setup.outputs.appraisals == 'true' }}" - uses: ruby/setup-ruby@v1.199.0 + uses: ruby/setup-ruby@v1.202.0 with: ruby-version: "${{ inputs.ruby }}" bundler: "latest" diff --git a/.github/workflows/ci-contrib.yml b/.github/workflows/ci-contrib.yml index b74aa6f57..1c8593069 100644 --- a/.github/workflows/ci-contrib.yml +++ b/.github/workflows/ci-contrib.yml @@ -58,7 +58,7 @@ jobs: uses: ./.github/actions/test_gem with: gem: "opentelemetry-helpers-${{ matrix.gem }}" - ruby: "jruby-9.4.8.0" + ruby: "jruby-9.4.9.0" propagators: strategy: @@ -103,7 +103,7 @@ jobs: uses: ./.github/actions/test_gem with: gem: "opentelemetry-propagator-${{ matrix.gem }}" - ruby: "jruby-9.4.8.0" + ruby: "jruby-9.4.9.0" resource-detectors: strategy: @@ -148,7 +148,7 @@ jobs: uses: ./.github/actions/test_gem with: gem: "opentelemetry-${{ matrix.gem }}" - ruby: "jruby-9.4.8.0" + ruby: "jruby-9.4.9.0" processors: strategy: @@ -191,4 +191,4 @@ jobs: uses: ./.github/actions/test_gem with: gem: "opentelemetry-processor-${{ matrix.gem }}" - ruby: "jruby-9.4.8.0" + ruby: "jruby-9.4.9.0" diff --git a/.github/workflows/ci-instrumentation-with-services.yml b/.github/workflows/ci-instrumentation-with-services.yml index 4eb5a1215..74ba690d2 100644 --- a/.github/workflows/ci-instrumentation-with-services.yml +++ b/.github/workflows/ci-instrumentation-with-services.yml @@ -56,7 +56,7 @@ jobs: uses: ./.github/actions/test_gem with: gem: "opentelemetry-instrumentation-${{ matrix.gem }}" - ruby: "jruby-9.4.8.0" + ruby: "jruby-9.4.9.0" services: memcached: image: memcached:alpine diff --git a/.github/workflows/ci-instrumentation.yml b/.github/workflows/ci-instrumentation.yml index b86f73555..cf938e48f 100644 --- a/.github/workflows/ci-instrumentation.yml +++ b/.github/workflows/ci-instrumentation.yml @@ -110,4 +110,4 @@ jobs: uses: ./.github/actions/test_gem with: gem: "opentelemetry-instrumentation-${{ matrix.gem }}" - ruby: "jruby-9.4.8.0" + ruby: "jruby-9.4.9.0" diff --git a/.github/workflows/installation-tests.yml b/.github/workflows/installation-tests.yml index 1280ebb16..3135ab25e 100644 --- a/.github/workflows/installation-tests.yml +++ b/.github/workflows/installation-tests.yml @@ -25,7 +25,7 @@ jobs: - uses: actions/checkout@v4 # ATTENTION: Dependabot does not know how to update shared actions file. # If you see it update setup-ruby here also update it as part of actions/test_gem/action.yml - - uses: ruby/setup-ruby@v1.199.0 + - uses: ruby/setup-ruby@v1.202.0 with: ruby-version: ${{ matrix.ruby-version }} - name: "Install Latest Gem Versions on ${{ matrix.ruby-version }}" diff --git a/.github/workflows/release-hook-on-closed.yml b/.github/workflows/release-hook-on-closed.yml index d2375ed37..e75031e80 100644 --- a/.github/workflows/release-hook-on-closed.yml +++ b/.github/workflows/release-hook-on-closed.yml @@ -12,7 +12,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.199.0 + uses: ruby/setup-ruby@v1.202.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-hook-on-push.yml b/.github/workflows/release-hook-on-push.yml index 31f770693..956938e3e 100644 --- a/.github/workflows/release-hook-on-push.yml +++ b/.github/workflows/release-hook-on-push.yml @@ -13,7 +13,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.199.0 + uses: ruby/setup-ruby@v1.202.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-perform.yml b/.github/workflows/release-perform.yml index be75e17a5..dd1a72511 100644 --- a/.github/workflows/release-perform.yml +++ b/.github/workflows/release-perform.yml @@ -22,7 +22,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.199.0 + uses: ruby/setup-ruby@v1.202.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-please.yaml b/.github/workflows/release-please.yaml index 581ef32b8..b42ab8153 100644 --- a/.github/workflows/release-please.yaml +++ b/.github/workflows/release-please.yaml @@ -50,7 +50,7 @@ jobs: chmod 0600 $HOME/.gem/credentials printf -- "---\n:rubygems_api_key: ${GEM_HOST_API_KEY}\n" > $HOME/.gem/credentials - - uses: ruby/setup-ruby@v1.199.0 + - uses: ruby/setup-ruby@v1.202.0 with: ruby-version: "3.0" bundler: latest diff --git a/.github/workflows/release-request-weekly.yml b/.github/workflows/release-request-weekly.yml index f6063d304..d230a0279 100644 --- a/.github/workflows/release-request-weekly.yml +++ b/.github/workflows/release-request-weekly.yml @@ -12,7 +12,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.199.0 + uses: ruby/setup-ruby@v1.202.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-request.yml b/.github/workflows/release-request.yml index 210f1c44d..e5520216a 100644 --- a/.github/workflows/release-request.yml +++ b/.github/workflows/release-request.yml @@ -16,7 +16,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.199.0 + uses: ruby/setup-ruby@v1.202.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo diff --git a/.github/workflows/release-retry.yml b/.github/workflows/release-retry.yml index 2f42e104b..fd1e81b46 100644 --- a/.github/workflows/release-retry.yml +++ b/.github/workflows/release-retry.yml @@ -19,7 +19,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Install Ruby ${{ env.ruby_version }} - uses: ruby/setup-ruby@v1.199.0 + uses: ruby/setup-ruby@v1.202.0 with: ruby-version: ${{ env.ruby_version }} - name: Checkout repo From 1147bbcf35a0e1183df6d68026f77c04981e8385 Mon Sep 17 00:00:00 2001 From: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com> Date: Thu, 14 Nov 2024 10:28:12 -0800 Subject: [PATCH 45/58] chore: Update Rubocop 1.67.0 -> 1.68.0 (#1241) * chore: Update Rubocop 1.67.0 -> 1.68.0 * chore: Rubocop Lint/UselessAssignment Useless assignment to variable - span_kind --- Gemfile | 2 +- helpers/mysql/opentelemetry-helpers-mysql.gemspec | 2 +- .../opentelemetry-helpers-sql-obfuscation.gemspec | 2 +- .../opentelemetry-instrumentation-action_mailer.gemspec | 2 +- .../opentelemetry-instrumentation-action_pack.gemspec | 2 +- .../opentelemetry-instrumentation-action_view.gemspec | 2 +- .../active_job/opentelemetry-instrumentation-active_job.gemspec | 2 +- ...entelemetry-instrumentation-active_model_serializers.gemspec | 2 +- .../opentelemetry-instrumentation-active_record.gemspec | 2 +- .../opentelemetry-instrumentation-active_support.gemspec | 2 +- instrumentation/all/opentelemetry-instrumentation-all.gemspec | 2 +- .../lib/opentelemetry/instrumentation/aws_lambda/handler.rb | 1 - .../aws_lambda/opentelemetry-instrumentation-aws_lambda.gemspec | 2 +- .../aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec | 2 +- instrumentation/base/opentelemetry-instrumentation-base.gemspec | 2 +- .../bunny/opentelemetry-instrumentation-bunny.gemspec | 2 +- .../opentelemetry-instrumentation-concurrent_ruby.gemspec | 2 +- .../dalli/opentelemetry-instrumentation-dalli.gemspec | 2 +- .../opentelemetry-instrumentation-delayed_job.gemspec | 2 +- .../ethon/opentelemetry-instrumentation-ethon.gemspec | 2 +- .../excon/opentelemetry-instrumentation-excon.gemspec | 2 +- .../faraday/opentelemetry-instrumentation-faraday.gemspec | 2 +- .../grape/opentelemetry-instrumentation-grape.gemspec | 2 +- .../graphql/opentelemetry-instrumentation-graphql.gemspec | 2 +- instrumentation/gruf/opentelemetry-instrumentation-gruf.gemspec | 2 +- instrumentation/http/opentelemetry-instrumentation-http.gemspec | 2 +- .../opentelemetry-instrumentation-http_client.gemspec | 2 +- .../httpx/opentelemetry-instrumentation-httpx.gemspec | 2 +- .../koala/opentelemetry-instrumentation-koala.gemspec | 2 +- instrumentation/lmdb/opentelemetry-instrumentation-lmdb.gemspec | 2 +- .../mongo/opentelemetry-instrumentation-mongo.gemspec | 2 +- .../mysql2/opentelemetry-instrumentation-mysql2.gemspec | 2 +- .../net_http/opentelemetry-instrumentation-net_http.gemspec | 2 +- instrumentation/pg/opentelemetry-instrumentation-pg.gemspec | 2 +- instrumentation/que/opentelemetry-instrumentation-que.gemspec | 2 +- .../racecar/opentelemetry-instrumentation-racecar.gemspec | 2 +- instrumentation/rack/opentelemetry-instrumentation-rack.gemspec | 2 +- .../rails/opentelemetry-instrumentation-rails.gemspec | 2 +- instrumentation/rake/opentelemetry-instrumentation-rake.gemspec | 2 +- .../rdkafka/opentelemetry-instrumentation-rdkafka.gemspec | 2 +- .../redis/opentelemetry-instrumentation-redis.gemspec | 2 +- .../resque/opentelemetry-instrumentation-resque.gemspec | 2 +- .../restclient/opentelemetry-instrumentation-restclient.gemspec | 2 +- .../rspec/opentelemetry-instrumentation-rspec.gemspec | 2 +- .../ruby_kafka/opentelemetry-instrumentation-ruby_kafka.gemspec | 2 +- .../sidekiq/opentelemetry-instrumentation-sidekiq.gemspec | 2 +- .../sinatra/opentelemetry-instrumentation-sinatra.gemspec | 2 +- .../trilogy/opentelemetry-instrumentation-trilogy.gemspec | 2 +- processor/baggage/opentelemetry-processor-baggage.gemspec | 2 +- propagator/ottrace/opentelemetry-propagator-ottrace.gemspec | 2 +- propagator/vitess/opentelemetry-propagator-vitess.gemspec | 2 +- propagator/xray/opentelemetry-propagator-xray.gemspec | 2 +- resources/azure/opentelemetry-resource-detector-azure.gemspec | 2 +- .../container/opentelemetry-resource-detector-container.gemspec | 2 +- ...pentelemetry-resource-detector-google_cloud_platform.gemspec | 2 +- 55 files changed, 54 insertions(+), 55 deletions(-) diff --git a/Gemfile b/Gemfile index 2f648ce72..30ecc9373 100644 --- a/Gemfile +++ b/Gemfile @@ -7,5 +7,5 @@ source 'https://rubygems.org' gem 'rake', '~> 13.0' -gem 'rubocop', '~> 1.67.0' +gem 'rubocop', '~> 1.68.0' gem 'rubocop-performance', '~> 1.21.0' diff --git a/helpers/mysql/opentelemetry-helpers-mysql.gemspec b/helpers/mysql/opentelemetry-helpers-mysql.gemspec index ecbcdfd0f..36a9e5df0 100644 --- a/helpers/mysql/opentelemetry-helpers-mysql.gemspec +++ b/helpers/mysql/opentelemetry-helpers-mysql.gemspec @@ -32,7 +32,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/helpers/sql-obfuscation/opentelemetry-helpers-sql-obfuscation.gemspec b/helpers/sql-obfuscation/opentelemetry-helpers-sql-obfuscation.gemspec index 64b691d90..5eacadb13 100644 --- a/helpers/sql-obfuscation/opentelemetry-helpers-sql-obfuscation.gemspec +++ b/helpers/sql-obfuscation/opentelemetry-helpers-sql-obfuscation.gemspec @@ -31,7 +31,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'yard', '~> 0.9' spec.add_development_dependency 'yard-doctest', '~> 0.1.6' diff --git a/instrumentation/action_mailer/opentelemetry-instrumentation-action_mailer.gemspec b/instrumentation/action_mailer/opentelemetry-instrumentation-action_mailer.gemspec index c0b3d645e..529e98f42 100644 --- a/instrumentation/action_mailer/opentelemetry-instrumentation-action_mailer.gemspec +++ b/instrumentation/action_mailer/opentelemetry-instrumentation-action_mailer.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/action_pack/opentelemetry-instrumentation-action_pack.gemspec b/instrumentation/action_pack/opentelemetry-instrumentation-action_pack.gemspec index dc1854bd4..4a5a07995 100644 --- a/instrumentation/action_pack/opentelemetry-instrumentation-action_pack.gemspec +++ b/instrumentation/action_pack/opentelemetry-instrumentation-action_pack.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rails', '>= 6.1' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/action_view/opentelemetry-instrumentation-action_view.gemspec b/instrumentation/action_view/opentelemetry-instrumentation-action_view.gemspec index 10a331ab4..721f509c6 100644 --- a/instrumentation/action_view/opentelemetry-instrumentation-action_view.gemspec +++ b/instrumentation/action_view/opentelemetry-instrumentation-action_view.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rails', '>= 6.1' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/active_job/opentelemetry-instrumentation-active_job.gemspec b/instrumentation/active_job/opentelemetry-instrumentation-active_job.gemspec index 88624fe76..2a4e6c9f8 100644 --- a/instrumentation/active_job/opentelemetry-instrumentation-active_job.gemspec +++ b/instrumentation/active_job/opentelemetry-instrumentation-active_job.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/active_model_serializers/opentelemetry-instrumentation-active_model_serializers.gemspec b/instrumentation/active_model_serializers/opentelemetry-instrumentation-active_model_serializers.gemspec index 1dd86fc4b..3383c1f28 100644 --- a/instrumentation/active_model_serializers/opentelemetry-instrumentation-active_model_serializers.gemspec +++ b/instrumentation/active_model_serializers/opentelemetry-instrumentation-active_model_serializers.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/active_record/opentelemetry-instrumentation-active_record.gemspec b/instrumentation/active_record/opentelemetry-instrumentation-active_record.gemspec index 248f23764..ad6ca55eb 100644 --- a/instrumentation/active_record/opentelemetry-instrumentation-active_record.gemspec +++ b/instrumentation/active_record/opentelemetry-instrumentation-active_record.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/active_support/opentelemetry-instrumentation-active_support.gemspec b/instrumentation/active_support/opentelemetry-instrumentation-active_support.gemspec index 438a02994..a5d3fe882 100644 --- a/instrumentation/active_support/opentelemetry-instrumentation-active_support.gemspec +++ b/instrumentation/active_support/opentelemetry-instrumentation-active_support.gemspec @@ -39,7 +39,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rails', '>= 6.1' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/all/opentelemetry-instrumentation-all.gemspec b/instrumentation/all/opentelemetry-instrumentation-all.gemspec index 8810c3e09..b9906921a 100644 --- a/instrumentation/all/opentelemetry-instrumentation-all.gemspec +++ b/instrumentation/all/opentelemetry-instrumentation-all.gemspec @@ -66,7 +66,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'bundler', '~> 2.4' spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/aws_lambda/lib/opentelemetry/instrumentation/aws_lambda/handler.rb b/instrumentation/aws_lambda/lib/opentelemetry/instrumentation/aws_lambda/handler.rb index 69c050be5..fa0f55de2 100644 --- a/instrumentation/aws_lambda/lib/opentelemetry/instrumentation/aws_lambda/handler.rb +++ b/instrumentation/aws_lambda/lib/opentelemetry/instrumentation/aws_lambda/handler.rb @@ -30,7 +30,6 @@ def initialize def call_wrapped(event:, context:) parent_context = extract_parent_context(event) - span_kind = nil span_kind = if event['Records'] && AWS_TRIGGERS.include?(event['Records'].dig(0, 'eventSource')) :consumer else diff --git a/instrumentation/aws_lambda/opentelemetry-instrumentation-aws_lambda.gemspec b/instrumentation/aws_lambda/opentelemetry-instrumentation-aws_lambda.gemspec index 52955bf62..c2d9b96e4 100644 --- a/instrumentation/aws_lambda/opentelemetry-instrumentation-aws_lambda.gemspec +++ b/instrumentation/aws_lambda/opentelemetry-instrumentation-aws_lambda.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'pry' spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec b/instrumentation/aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec index 0b94e325c..797c0ab37 100644 --- a/instrumentation/aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec +++ b/instrumentation/aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec @@ -37,7 +37,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'pry' spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/base/opentelemetry-instrumentation-base.gemspec b/instrumentation/base/opentelemetry-instrumentation-base.gemspec index 218aaab50..502e21e24 100644 --- a/instrumentation/base/opentelemetry-instrumentation-base.gemspec +++ b/instrumentation/base/opentelemetry-instrumentation-base.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/bunny/opentelemetry-instrumentation-bunny.gemspec b/instrumentation/bunny/opentelemetry-instrumentation-bunny.gemspec index bb42ce52f..0a4b39b6f 100644 --- a/instrumentation/bunny/opentelemetry-instrumentation-bunny.gemspec +++ b/instrumentation/bunny/opentelemetry-instrumentation-bunny.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/concurrent_ruby/opentelemetry-instrumentation-concurrent_ruby.gemspec b/instrumentation/concurrent_ruby/opentelemetry-instrumentation-concurrent_ruby.gemspec index 635aef38c..0e356e43b 100644 --- a/instrumentation/concurrent_ruby/opentelemetry-instrumentation-concurrent_ruby.gemspec +++ b/instrumentation/concurrent_ruby/opentelemetry-instrumentation-concurrent_ruby.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/dalli/opentelemetry-instrumentation-dalli.gemspec b/instrumentation/dalli/opentelemetry-instrumentation-dalli.gemspec index fbd399489..5ef0f6bc7 100644 --- a/instrumentation/dalli/opentelemetry-instrumentation-dalli.gemspec +++ b/instrumentation/dalli/opentelemetry-instrumentation-dalli.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/delayed_job/opentelemetry-instrumentation-delayed_job.gemspec b/instrumentation/delayed_job/opentelemetry-instrumentation-delayed_job.gemspec index 4970e4140..48dea0abd 100644 --- a/instrumentation/delayed_job/opentelemetry-instrumentation-delayed_job.gemspec +++ b/instrumentation/delayed_job/opentelemetry-instrumentation-delayed_job.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'sqlite3' diff --git a/instrumentation/ethon/opentelemetry-instrumentation-ethon.gemspec b/instrumentation/ethon/opentelemetry-instrumentation-ethon.gemspec index f4fc45bd6..4a9b1050f 100644 --- a/instrumentation/ethon/opentelemetry-instrumentation-ethon.gemspec +++ b/instrumentation/ethon/opentelemetry-instrumentation-ethon.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/excon/opentelemetry-instrumentation-excon.gemspec b/instrumentation/excon/opentelemetry-instrumentation-excon.gemspec index d97079859..3c07dd9b7 100644 --- a/instrumentation/excon/opentelemetry-instrumentation-excon.gemspec +++ b/instrumentation/excon/opentelemetry-instrumentation-excon.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/faraday/opentelemetry-instrumentation-faraday.gemspec b/instrumentation/faraday/opentelemetry-instrumentation-faraday.gemspec index ef630138c..a115967d5 100644 --- a/instrumentation/faraday/opentelemetry-instrumentation-faraday.gemspec +++ b/instrumentation/faraday/opentelemetry-instrumentation-faraday.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/grape/opentelemetry-instrumentation-grape.gemspec b/instrumentation/grape/opentelemetry-instrumentation-grape.gemspec index b5b885fe4..71d355fe3 100644 --- a/instrumentation/grape/opentelemetry-instrumentation-grape.gemspec +++ b/instrumentation/grape/opentelemetry-instrumentation-grape.gemspec @@ -38,7 +38,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rack-test' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/graphql/opentelemetry-instrumentation-graphql.gemspec b/instrumentation/graphql/opentelemetry-instrumentation-graphql.gemspec index c8e9f86a4..43ad220bf 100644 --- a/instrumentation/graphql/opentelemetry-instrumentation-graphql.gemspec +++ b/instrumentation/graphql/opentelemetry-instrumentation-graphql.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/gruf/opentelemetry-instrumentation-gruf.gemspec b/instrumentation/gruf/opentelemetry-instrumentation-gruf.gemspec index ead698e1d..4a955c9a3 100644 --- a/instrumentation/gruf/opentelemetry-instrumentation-gruf.gemspec +++ b/instrumentation/gruf/opentelemetry-instrumentation-gruf.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.0' spec.add_development_dependency 'opentelemetry-test-helpers' spec.add_development_dependency 'rake', '~> 12.3.3' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/http/opentelemetry-instrumentation-http.gemspec b/instrumentation/http/opentelemetry-instrumentation-http.gemspec index f8deae16a..88a000aba 100644 --- a/instrumentation/http/opentelemetry-instrumentation-http.gemspec +++ b/instrumentation/http/opentelemetry-instrumentation-http.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/http_client/opentelemetry-instrumentation-http_client.gemspec b/instrumentation/http_client/opentelemetry-instrumentation-http_client.gemspec index 60cd751e8..a5b722937 100644 --- a/instrumentation/http_client/opentelemetry-instrumentation-http_client.gemspec +++ b/instrumentation/http_client/opentelemetry-instrumentation-http_client.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/httpx/opentelemetry-instrumentation-httpx.gemspec b/instrumentation/httpx/opentelemetry-instrumentation-httpx.gemspec index 7b0367aca..0f56283b8 100644 --- a/instrumentation/httpx/opentelemetry-instrumentation-httpx.gemspec +++ b/instrumentation/httpx/opentelemetry-instrumentation-httpx.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/koala/opentelemetry-instrumentation-koala.gemspec b/instrumentation/koala/opentelemetry-instrumentation-koala.gemspec index c80687d62..61a611cec 100644 --- a/instrumentation/koala/opentelemetry-instrumentation-koala.gemspec +++ b/instrumentation/koala/opentelemetry-instrumentation-koala.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/lmdb/opentelemetry-instrumentation-lmdb.gemspec b/instrumentation/lmdb/opentelemetry-instrumentation-lmdb.gemspec index ffea2c1a4..12056bc40 100644 --- a/instrumentation/lmdb/opentelemetry-instrumentation-lmdb.gemspec +++ b/instrumentation/lmdb/opentelemetry-instrumentation-lmdb.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/mongo/opentelemetry-instrumentation-mongo.gemspec b/instrumentation/mongo/opentelemetry-instrumentation-mongo.gemspec index 5f6180f5d..c70528fc7 100644 --- a/instrumentation/mongo/opentelemetry-instrumentation-mongo.gemspec +++ b/instrumentation/mongo/opentelemetry-instrumentation-mongo.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'pry' spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/mysql2/opentelemetry-instrumentation-mysql2.gemspec b/instrumentation/mysql2/opentelemetry-instrumentation-mysql2.gemspec index 51f644bab..2f09b9e9b 100644 --- a/instrumentation/mysql2/opentelemetry-instrumentation-mysql2.gemspec +++ b/instrumentation/mysql2/opentelemetry-instrumentation-mysql2.gemspec @@ -37,7 +37,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'pry' spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/net_http/opentelemetry-instrumentation-net_http.gemspec b/instrumentation/net_http/opentelemetry-instrumentation-net_http.gemspec index 5c2826b6b..c9603deaa 100644 --- a/instrumentation/net_http/opentelemetry-instrumentation-net_http.gemspec +++ b/instrumentation/net_http/opentelemetry-instrumentation-net_http.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0.1' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/pg/opentelemetry-instrumentation-pg.gemspec b/instrumentation/pg/opentelemetry-instrumentation-pg.gemspec index ddc1d2662..0d040639d 100644 --- a/instrumentation/pg/opentelemetry-instrumentation-pg.gemspec +++ b/instrumentation/pg/opentelemetry-instrumentation-pg.gemspec @@ -37,7 +37,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'pry' spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/que/opentelemetry-instrumentation-que.gemspec b/instrumentation/que/opentelemetry-instrumentation-que.gemspec index 9d846749b..bd6a2e5df 100644 --- a/instrumentation/que/opentelemetry-instrumentation-que.gemspec +++ b/instrumentation/que/opentelemetry-instrumentation-que.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/racecar/opentelemetry-instrumentation-racecar.gemspec b/instrumentation/racecar/opentelemetry-instrumentation-racecar.gemspec index 2e01be3b4..cf093ecba 100644 --- a/instrumentation/racecar/opentelemetry-instrumentation-racecar.gemspec +++ b/instrumentation/racecar/opentelemetry-instrumentation-racecar.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/rack/opentelemetry-instrumentation-rack.gemspec b/instrumentation/rack/opentelemetry-instrumentation-rack.gemspec index 7681ad9f6..d3029b8d6 100644 --- a/instrumentation/rack/opentelemetry-instrumentation-rack.gemspec +++ b/instrumentation/rack/opentelemetry-instrumentation-rack.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec b/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec index 79bd909da..8182d9f69 100644 --- a/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec +++ b/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec @@ -41,7 +41,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rack-test', '~> 2.1.0' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/rake/opentelemetry-instrumentation-rake.gemspec b/instrumentation/rake/opentelemetry-instrumentation-rake.gemspec index 5bb3ee796..9cc83ecde 100644 --- a/instrumentation/rake/opentelemetry-instrumentation-rake.gemspec +++ b/instrumentation/rake/opentelemetry-instrumentation-rake.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.0' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/rdkafka/opentelemetry-instrumentation-rdkafka.gemspec b/instrumentation/rdkafka/opentelemetry-instrumentation-rdkafka.gemspec index 8133ddcf9..a2e7bd62f 100644 --- a/instrumentation/rdkafka/opentelemetry-instrumentation-rdkafka.gemspec +++ b/instrumentation/rdkafka/opentelemetry-instrumentation-rdkafka.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/redis/opentelemetry-instrumentation-redis.gemspec b/instrumentation/redis/opentelemetry-instrumentation-redis.gemspec index 1964d35f6..e5beb6d00 100644 --- a/instrumentation/redis/opentelemetry-instrumentation-redis.gemspec +++ b/instrumentation/redis/opentelemetry-instrumentation-redis.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/resque/opentelemetry-instrumentation-resque.gemspec b/instrumentation/resque/opentelemetry-instrumentation-resque.gemspec index 6799792e9..6aa0fec81 100644 --- a/instrumentation/resque/opentelemetry-instrumentation-resque.gemspec +++ b/instrumentation/resque/opentelemetry-instrumentation-resque.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/restclient/opentelemetry-instrumentation-restclient.gemspec b/instrumentation/restclient/opentelemetry-instrumentation-restclient.gemspec index c86c37fd2..1788cbe54 100644 --- a/instrumentation/restclient/opentelemetry-instrumentation-restclient.gemspec +++ b/instrumentation/restclient/opentelemetry-instrumentation-restclient.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/rspec/opentelemetry-instrumentation-rspec.gemspec b/instrumentation/rspec/opentelemetry-instrumentation-rspec.gemspec index bbb39b0af..3aa906b8a 100644 --- a/instrumentation/rspec/opentelemetry-instrumentation-rspec.gemspec +++ b/instrumentation/rspec/opentelemetry-instrumentation-rspec.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/ruby_kafka/opentelemetry-instrumentation-ruby_kafka.gemspec b/instrumentation/ruby_kafka/opentelemetry-instrumentation-ruby_kafka.gemspec index 837fc8328..d6376ae92 100644 --- a/instrumentation/ruby_kafka/opentelemetry-instrumentation-ruby_kafka.gemspec +++ b/instrumentation/ruby_kafka/opentelemetry-instrumentation-ruby_kafka.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/sidekiq/opentelemetry-instrumentation-sidekiq.gemspec b/instrumentation/sidekiq/opentelemetry-instrumentation-sidekiq.gemspec index 495001789..a2fa3b643 100644 --- a/instrumentation/sidekiq/opentelemetry-instrumentation-sidekiq.gemspec +++ b/instrumentation/sidekiq/opentelemetry-instrumentation-sidekiq.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/sinatra/opentelemetry-instrumentation-sinatra.gemspec b/instrumentation/sinatra/opentelemetry-instrumentation-sinatra.gemspec index 821f2f9cc..e5347d480 100644 --- a/instrumentation/sinatra/opentelemetry-instrumentation-sinatra.gemspec +++ b/instrumentation/sinatra/opentelemetry-instrumentation-sinatra.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rack-test', '~> 2.1' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/trilogy/opentelemetry-instrumentation-trilogy.gemspec b/instrumentation/trilogy/opentelemetry-instrumentation-trilogy.gemspec index 197ebe6be..081536c7a 100644 --- a/instrumentation/trilogy/opentelemetry-instrumentation-trilogy.gemspec +++ b/instrumentation/trilogy/opentelemetry-instrumentation-trilogy.gemspec @@ -41,7 +41,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/processor/baggage/opentelemetry-processor-baggage.gemspec b/processor/baggage/opentelemetry-processor-baggage.gemspec index 23a4f0a8a..700b16646 100644 --- a/processor/baggage/opentelemetry-processor-baggage.gemspec +++ b/processor/baggage/opentelemetry-processor-baggage.gemspec @@ -30,7 +30,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/propagator/ottrace/opentelemetry-propagator-ottrace.gemspec b/propagator/ottrace/opentelemetry-propagator-ottrace.gemspec index bd988a552..7d3b3894d 100644 --- a/propagator/ottrace/opentelemetry-propagator-ottrace.gemspec +++ b/propagator/ottrace/opentelemetry-propagator-ottrace.gemspec @@ -28,7 +28,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'bundler', '~> 2.4' spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/propagator/vitess/opentelemetry-propagator-vitess.gemspec b/propagator/vitess/opentelemetry-propagator-vitess.gemspec index 6508b5730..aaaf55a97 100644 --- a/propagator/vitess/opentelemetry-propagator-vitess.gemspec +++ b/propagator/vitess/opentelemetry-propagator-vitess.gemspec @@ -29,7 +29,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'bundler', '~> 2.4' spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/propagator/xray/opentelemetry-propagator-xray.gemspec b/propagator/xray/opentelemetry-propagator-xray.gemspec index 90c1e1602..b1bffaa23 100644 --- a/propagator/xray/opentelemetry-propagator-xray.gemspec +++ b/propagator/xray/opentelemetry-propagator-xray.gemspec @@ -31,7 +31,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'bundler', '~> 2.4' spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/resources/azure/opentelemetry-resource-detector-azure.gemspec b/resources/azure/opentelemetry-resource-detector-azure.gemspec index db5fd4f46..be2a85147 100644 --- a/resources/azure/opentelemetry-resource-detector-azure.gemspec +++ b/resources/azure/opentelemetry-resource-detector-azure.gemspec @@ -30,7 +30,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'bundler', '~> 2.4' spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/resources/container/opentelemetry-resource-detector-container.gemspec b/resources/container/opentelemetry-resource-detector-container.gemspec index dddc2cea5..6160f36d7 100644 --- a/resources/container/opentelemetry-resource-detector-container.gemspec +++ b/resources/container/opentelemetry-resource-detector-container.gemspec @@ -30,7 +30,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'bundler', '~> 2.4' spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/resources/google_cloud_platform/opentelemetry-resource-detector-google_cloud_platform.gemspec b/resources/google_cloud_platform/opentelemetry-resource-detector-google_cloud_platform.gemspec index 0261da6aa..11ad9a060 100644 --- a/resources/google_cloud_platform/opentelemetry-resource-detector-google_cloud_platform.gemspec +++ b/resources/google_cloud_platform/opentelemetry-resource-detector-google_cloud_platform.gemspec @@ -31,7 +31,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'bundler', '~> 2.4' spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' - spec.add_development_dependency 'rubocop', '~> 1.67.0' + spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' spec.add_development_dependency 'simplecov', '~> 0.17' spec.add_development_dependency 'webmock', '~> 3.24.0' From acac4fd6b835b4ad8023e3bc6d8b454bc922c726 Mon Sep 17 00:00:00 2001 From: Ariel Valentin Date: Fri, 15 Nov 2024 13:08:56 -0700 Subject: [PATCH 46/58] feat: Use Semconv Naming For ActionPack (#1224) * feat: Use Semconv Naming For ActionPack Aligns the span name closer to the specification instead of using Ruby class/method naming syntax Fixes https://github.com/open-telemetry/opentelemetry-ruby-contrib/issues/961 * squash: remove conditional logic on rails version * squash: add leading slash * squash: fix gem version references for 3.0 * squash: relax the test a little * squash: added some docs and refactored the code a little * squash: tests and more docs * squash: spelling errors * squash: Re-add assertions --- instrumentation/action_pack/README.md | 19 ++++ .../action_pack/handlers/action_controller.rb | 48 ++++++--- .../action_pack/instrumentation.rb | 28 ++++- ...emetry-instrumentation-action_pack.gemspec | 1 - .../handlers/action_controller_test.rb | 102 ++++++++++++++---- .../controllers/example_controller.rb | 2 +- .../patches/action_controller/metal_test.rb | 4 +- 7 files changed, 166 insertions(+), 38 deletions(-) diff --git a/instrumentation/action_pack/README.md b/instrumentation/action_pack/README.md index 4eb0b6c97..c8b84f5ef 100644 --- a/instrumentation/action_pack/README.md +++ b/instrumentation/action_pack/README.md @@ -42,6 +42,25 @@ See the table below for details of what [Rails Framework Hook Events](https://gu | - | - | - | - | | `process_action.action_controller` | :white_check_mark: | :x: | It modifies the existing Rack span | +## Semantic Conventions + +This instrumentation generally uses [HTTP server semantic conventions](https://opentelemetry.io/docs/specs/semconv/http/http-spans/) to update the existing Rack span. + +For Rails 7.1+, the span name is updated to match the HTTP method and route that was matched for the request using [`ActionDispatch::Request#route_uri_pattern`](https://api.rubyonrails.org/classes/ActionDispatch/Request.html#method-i-route_uri_pattern), e.g.: `GET /users/:id` + +For older versions of Rails the span name is updated to match the HTTP method, controller, and action name that was the target of the request, e.g.: `GET /example/index` + +> ![NOTE]: Users may override the `span_naming` option to default to Legacy Span Naming Behavior that uses the controller's class name and action in Ruby documentation syntax, e.g. `ExampleController#index`. + +This instrumentation does not emit any custom attributes. + +| Attribute Name | Type | Notes | +| - | - | - | +| `code.namespace` | String | `ActionController` class name | +| `code.function` | String | `ActionController` action name e.g. `index`, `show`, `edit`, etc... | +| `http.route` | String | (Rails 7.1+) the route that was matched for the request | +| `http.target` | String | The `request.filtered_path` | + ### Error Handling for Action Controller If an error is triggered by Action Controller (such as a 500 internal server error), Action Pack will typically employ the default `ActionDispatch::PublicExceptions.new(Rails.public_path)` as the `exceptions_app`, as detailed in the [documentation](https://guides.rubyonrails.org/configuring.html#config-exceptions-app). diff --git a/instrumentation/action_pack/lib/opentelemetry/instrumentation/action_pack/handlers/action_controller.rb b/instrumentation/action_pack/lib/opentelemetry/instrumentation/action_pack/handlers/action_controller.rb index d7b79b64d..843af4633 100644 --- a/instrumentation/action_pack/lib/opentelemetry/instrumentation/action_pack/handlers/action_controller.rb +++ b/instrumentation/action_pack/lib/opentelemetry/instrumentation/action_pack/handlers/action_controller.rb @@ -13,6 +13,7 @@ class ActionController # @param config [Hash] of instrumentation options def initialize(config) @config = config + @span_naming = config.fetch(:span_naming) end # Invoked by ActiveSupport::Notifications at the start of the instrumentation block @@ -22,20 +23,11 @@ def initialize(config) # @param payload [Hash] the payload passed as a method argument # @return [Hash] the payload passed as a method argument def start(_name, _id, payload) - rack_span = OpenTelemetry::Instrumentation::Rack.current_span + span_name, attributes = to_span_name_and_attributes(payload) - request = payload[:request] - - rack_span.name = "#{payload[:controller]}##{payload[:action]}" unless request.env['action_dispatch.exception'] - - attributes_to_append = { - OpenTelemetry::SemanticConventions::Trace::CODE_NAMESPACE => String(payload[:controller]), - OpenTelemetry::SemanticConventions::Trace::CODE_FUNCTION => String(payload[:action]) - } - - attributes_to_append[OpenTelemetry::SemanticConventions::Trace::HTTP_TARGET] = request.filtered_path if request.filtered_path != request.fullpath - - rack_span.add_attributes(attributes_to_append) + span = OpenTelemetry::Instrumentation::Rack.current_span + span.name = span_name + span.add_attributes(attributes) rescue StandardError => e OpenTelemetry.handle_error(exception: e) end @@ -47,11 +39,37 @@ def start(_name, _id, payload) # @param payload [Hash] the payload passed as a method argument # @return [Hash] the payload passed as a method argument def finish(_name, _id, payload) - rack_span = OpenTelemetry::Instrumentation::Rack.current_span - rack_span.record_exception(payload[:exception_object]) if payload[:exception_object] + span = OpenTelemetry::Instrumentation::Rack.current_span + span.record_exception(payload[:exception_object]) if payload[:exception_object] rescue StandardError => e OpenTelemetry.handle_error(exception: e) end + + private + + # Extracts the span name and attributes from the payload + # + # @param payload [Hash] the payload passed from ActiveSupport::Notifications + # @return [Array] the span name and attributes + def to_span_name_and_attributes(payload) + request = payload[:request] + http_route = request.route_uri_pattern if request.respond_to?(:route_uri_pattern) + + attributes = { + OpenTelemetry::SemanticConventions::Trace::CODE_NAMESPACE => String(payload[:controller]), + OpenTelemetry::SemanticConventions::Trace::CODE_FUNCTION => String(payload[:action]) + } + attributes[OpenTelemetry::SemanticConventions::Trace::HTTP_ROUTE] = http_route if http_route + attributes[OpenTelemetry::SemanticConventions::Trace::HTTP_TARGET] = request.filtered_path if request.filtered_path != request.fullpath + + if @span_naming == :semconv + return ["#{request.method} #{http_route.gsub('(.:format)', '')}", attributes] if http_route + + return ["#{request.method} /#{payload.dig(:params, :controller)}/#{payload.dig(:params, :action)}", attributes] + end + + ["#{payload[:controller]}##{payload[:action]}", attributes] + end end end end diff --git a/instrumentation/action_pack/lib/opentelemetry/instrumentation/action_pack/instrumentation.rb b/instrumentation/action_pack/lib/opentelemetry/instrumentation/action_pack/instrumentation.rb index cad8a14a4..b81362f5a 100644 --- a/instrumentation/action_pack/lib/opentelemetry/instrumentation/action_pack/instrumentation.rb +++ b/instrumentation/action_pack/lib/opentelemetry/instrumentation/action_pack/instrumentation.rb @@ -7,7 +7,31 @@ module OpenTelemetry module Instrumentation module ActionPack - # The Instrumentation class contains logic to detect and install the ActionPack instrumentation + # The {OpenTelemetry::Instrumentation::ActionPack::Instrumentation} class contains logic to detect and install the ActionPack instrumentation + # + # Installation and configuration of this instrumentation is done within the + # {https://www.rubydoc.info/gems/opentelemetry-sdk/OpenTelemetry/SDK#configure-instance_method OpenTelemetry::SDK#configure} + # block, calling {https://www.rubydoc.info/gems/opentelemetry-sdk/OpenTelemetry%2FSDK%2FConfigurator:use use()} + # or {https://www.rubydoc.info/gems/opentelemetry-sdk/OpenTelemetry%2FSDK%2FConfigurator:use_all use_all()}. + # + # ## Configuration keys and options + # + # ### `:span_naming` + # + # Specifies how the span names are set. Can be one of: + # + # - `:semconv` **(default)** - The span name will use HTTP semantic conventions '{method http.route}', for example `GET /users/:id` + # - `:class` - The span name will appear as '#', + # for example `UsersController#show`. + # + # @example An explicit default configuration + # OpenTelemetry::SDK.configure do |c| + # c.use_all({ + # 'OpenTelemetry::Instrumentation::ActionPack' => { + # span_naming: :class + # }, + # }) + # end class Instrumentation < OpenTelemetry::Instrumentation::Base MINIMUM_VERSION = Gem::Version.new('6.1.0') @@ -17,6 +41,8 @@ class Instrumentation < OpenTelemetry::Instrumentation::Base patch end + option :span_naming, default: :semconv, validate: %i[semconv class] + present do defined?(::ActionController) end diff --git a/instrumentation/action_pack/opentelemetry-instrumentation-action_pack.gemspec b/instrumentation/action_pack/opentelemetry-instrumentation-action_pack.gemspec index 4a5a07995..c7ccb8689 100644 --- a/instrumentation/action_pack/opentelemetry-instrumentation-action_pack.gemspec +++ b/instrumentation/action_pack/opentelemetry-instrumentation-action_pack.gemspec @@ -34,7 +34,6 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' - spec.add_development_dependency 'rails', '>= 6.1' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.68.0' spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' diff --git a/instrumentation/action_pack/test/opentelemetry/instrumentation/action_pack/handlers/action_controller_test.rb b/instrumentation/action_pack/test/opentelemetry/instrumentation/action_pack/handlers/action_controller_test.rb index 0da17ab15..00433df24 100644 --- a/instrumentation/action_pack/test/opentelemetry/instrumentation/action_pack/handlers/action_controller_test.rb +++ b/instrumentation/action_pack/test/opentelemetry/instrumentation/action_pack/handlers/action_controller_test.rb @@ -36,7 +36,6 @@ _(last_response.body).must_equal 'actually ok' _(last_response.ok?).must_equal true - _(span.name).must_equal 'ExampleController#ok' _(span.kind).must_equal :server _(span.status.ok?).must_equal true @@ -65,7 +64,7 @@ _(last_response.body).must_equal 'created new item' _(last_response.ok?).must_equal true - _(span.name).must_equal 'ExampleController#new_item' + _(span.name).must_match(/^GET/) _(span.kind).must_equal :server _(span.status.ok?).must_equal true @@ -82,24 +81,25 @@ _(span.attributes['code.function']).must_equal 'new_item' end - it 'sets the span name when the controller raises an exception' do - get 'internal_server_error' + describe 'when encountering server side errors' do + it 'sets semconv attributes' do + get 'internal_server_error' - _(span.name).must_equal 'ExampleController#internal_server_error' - _(span.kind).must_equal :server - _(span.status.ok?).must_equal false + _(span.kind).must_equal :server + _(span.status.ok?).must_equal false - _(span.instrumentation_library.name).must_equal 'OpenTelemetry::Instrumentation::Rack' - _(span.instrumentation_library.version).must_equal OpenTelemetry::Instrumentation::Rack::VERSION + _(span.instrumentation_library.name).must_equal 'OpenTelemetry::Instrumentation::Rack' + _(span.instrumentation_library.version).must_equal OpenTelemetry::Instrumentation::Rack::VERSION - _(span.attributes['http.method']).must_equal 'GET' - _(span.attributes['http.host']).must_equal 'example.org' - _(span.attributes['http.scheme']).must_equal 'http' - _(span.attributes['http.target']).must_equal '/internal_server_error' - _(span.attributes['http.status_code']).must_equal 500 - _(span.attributes['http.user_agent']).must_be_nil - _(span.attributes['code.namespace']).must_equal 'ExampleController' - _(span.attributes['code.function']).must_equal 'internal_server_error' + _(span.attributes['http.method']).must_equal 'GET' + _(span.attributes['http.host']).must_equal 'example.org' + _(span.attributes['http.scheme']).must_equal 'http' + _(span.attributes['http.target']).must_equal '/internal_server_error' + _(span.attributes['http.status_code']).must_equal 500 + _(span.attributes['http.user_agent']).must_be_nil + _(span.attributes['code.namespace']).must_equal 'ExampleController' + _(span.attributes['code.function']).must_equal 'internal_server_error' + end end it 'does not set the span name when an exception is raised in middleware' do @@ -139,13 +139,79 @@ _(span.attributes['code.function']).must_be_nil end + describe 'span naming' do + describe 'when using the default span_naming configuration' do + describe 'successful requests' do + describe 'Rails Version < 7.1' do + it 'uses the http method controller and action name' do + skip "Rails #{Rails.gem_version} uses ActionDispatch::Request#route_uri_pattern" if Rails.gem_version >= Gem::Version.new('7.1') + get '/ok' + + _(span.name).must_equal 'GET /example/ok' + end + + it 'excludes route params' do + skip "Rails #{Rails.gem_version} uses ActionDispatch::Request#route_uri_pattern" if Rails.gem_version >= Gem::Version.new('7.1') + get '/items/1234' + + _(span.name).must_equal 'GET /example/item' + end + end + + describe 'Rails Version >= 7.1' do + it 'uses the Rails route' do + skip "Rails #{Rails.gem_version} does not define ActionDispatch::Request#route_uri_pattern" if Rails.gem_version < Gem::Version.new('7.1') + get '/ok' + + _(span.name).must_equal 'GET /ok' + end + + it 'includes route params' do + skip "Rails #{Rails.gem_version} does not define ActionDispatch::Request#route_uri_pattern" if Rails.gem_version < Gem::Version.new('7.1') + get '/items/1234' + + _(span.name).must_equal 'GET /items/:id' + end + end + end + + describe 'server errors' do + it 'uses the http method controller and action name for server side errors' do + skip "Rails #{Rails.gem_version} uses ActionDispatch::Request#route_uri_pattern" if Rails.gem_version >= Gem::Version.new('7.1') + + get 'internal_server_error' + + _(span.name).must_equal 'GET /example/internal_server_error' + end + + it 'uses the Rails route for server side errors' do + skip "Rails #{Rails.gem_version} uses ActionDispatch::Request#route_uri_pattern" if Rails.gem_version < Gem::Version.new('7.1') + + get 'internal_server_error' + + _(span.name).must_equal 'GET /internal_server_error' + end + end + end + + describe 'when using the class span_naming' do + let(:config) { { span_naming: :class } } + + it 'uses the http method and controller name' do + get '/ok' + + _(span.name).must_equal 'ExampleController#ok' + end + end + end + describe 'when the application has exceptions_app configured' do let(:rails_app) { AppConfig.initialize_app(use_exceptions_app: true) } it 'does not overwrite the span name from the controller that raised' do get 'internal_server_error' - _(span.name).must_equal 'ExampleController#internal_server_error' + _(span.name).must_match(/^GET/) _(span.kind).must_equal :server _(span.status.ok?).must_equal false diff --git a/instrumentation/action_pack/test/test_helpers/controllers/example_controller.rb b/instrumentation/action_pack/test/test_helpers/controllers/example_controller.rb index 228c3c8c2..7c17d55c7 100644 --- a/instrumentation/action_pack/test/test_helpers/controllers/example_controller.rb +++ b/instrumentation/action_pack/test/test_helpers/controllers/example_controller.rb @@ -20,6 +20,6 @@ def new_item end def internal_server_error - raise :internal_server_error + raise 'internal_server_error' end end diff --git a/instrumentation/rails/test/instrumentation/opentelemetry/instrumentation/rails/patches/action_controller/metal_test.rb b/instrumentation/rails/test/instrumentation/opentelemetry/instrumentation/rails/patches/action_controller/metal_test.rb index aa34213d2..96fd40cb3 100644 --- a/instrumentation/rails/test/instrumentation/opentelemetry/instrumentation/rails/patches/action_controller/metal_test.rb +++ b/instrumentation/rails/test/instrumentation/opentelemetry/instrumentation/rails/patches/action_controller/metal_test.rb @@ -17,12 +17,12 @@ # Clear captured spans before { exporter.reset } - it 'sets the span name to the format: HTTP_METHOD /rails/route(.:format)' do + it 'sets the span name to the format: HTTP_METHOD /rails/route' do get '/ok' _(last_response.body).must_equal 'actually ok' _(last_response.ok?).must_equal true - _(span.name).must_equal 'ExampleController#ok' + _(span.name).must_match %r{GET.*/ok} _(span.kind).must_equal :server _(span.status.ok?).must_equal true From c28588eab848237e415901a72be84d61e6acdcda Mon Sep 17 00:00:00 2001 From: Ariel Valentin Date: Tue, 19 Nov 2024 10:37:50 -0600 Subject: [PATCH 47/58] test: Fix Sinatra Tests (#1253) * test: Fix Sinatra Tests Sinatra 4.1 now includes a stricter host authorization check by default, which caused our tests to fail. The host authorization is not enforced in development and test mode so this PR sets the Sinatra environment to run in `test` mode. See: https://github.com/sinatra/sinatra/pull/2053 fixes https://github.com/open-telemetry/opentelemetry-ruby-contrib/issues/1252 * squash: update appraisals --------- Co-authored-by: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com> --- instrumentation/sinatra/Appraisals | 14 ++++---------- .../opentelemetry/instrumentation/sinatra_test.rb | 5 ++++- instrumentation/sinatra/test/test_helper.rb | 1 + 3 files changed, 9 insertions(+), 11 deletions(-) diff --git a/instrumentation/sinatra/Appraisals b/instrumentation/sinatra/Appraisals index f04c6775b..73cb3a9d4 100644 --- a/instrumentation/sinatra/Appraisals +++ b/instrumentation/sinatra/Appraisals @@ -4,16 +4,10 @@ # # SPDX-License-Identifier: Apache-2.0 -appraise 'sinatra-4.x' do - gem 'sinatra', '~> 4.0' -end - -appraise 'sinatra-3.x' do - gem 'sinatra', '~> 3.0' -end - -appraise 'sinatra-2.x' do - gem 'sinatra', '~> 2.1' +%w[4.1 3.0 2.1].each do |version| + appraise "sinatra-#{version}" do + gem 'sinatra', "~> #{version}" + end end appraise 'sinatra-latest' do diff --git a/instrumentation/sinatra/test/opentelemetry/instrumentation/sinatra_test.rb b/instrumentation/sinatra/test/opentelemetry/instrumentation/sinatra_test.rb index 0425595b8..4c9d5814a 100644 --- a/instrumentation/sinatra/test/opentelemetry/instrumentation/sinatra_test.rb +++ b/instrumentation/sinatra/test/opentelemetry/instrumentation/sinatra_test.rb @@ -17,6 +17,7 @@ class CustomError < StandardError; end let(:app_one) do Class.new(Sinatra::Application) do + set :raise_errors, false get '/endpoint' do '1' end @@ -41,6 +42,7 @@ class CustomError < StandardError; end let(:app_two) do Class.new(Sinatra::Application) do + set :raise_errors, false get '/endpoint' do '2' end @@ -165,7 +167,8 @@ class CustomError < StandardError; end 'http.method' => 'GET', 'http.route' => '/error', 'http.scheme' => 'http', - 'http.target' => '/error' + 'http.target' => '/error', + 'http.status_code' => 500 ) _(exporter.finished_spans.flat_map(&:events).map(&:name)).must_equal(['exception']) end diff --git a/instrumentation/sinatra/test/test_helper.rb b/instrumentation/sinatra/test/test_helper.rb index 6caf4af52..48ae2a681 100644 --- a/instrumentation/sinatra/test/test_helper.rb +++ b/instrumentation/sinatra/test/test_helper.rb @@ -3,6 +3,7 @@ # Copyright The OpenTelemetry Authors # # SPDX-License-Identifier: Apache-2.0 +ENV['APP_ENV'] = 'test' require 'bundler/setup' Bundler.require(:default, :development, :test) From 37584d018df41addb259cbe9ec58002769039ef9 Mon Sep 17 00:00:00 2001 From: Ariel Valentin Date: Tue, 19 Nov 2024 10:53:35 -0600 Subject: [PATCH 48/58] test: Add Rails 7.2 to Appraisals (#1242) * test: Add Rails 7.2 to Appraisals --- .github/actions/test_gem/action.yml | 1 + .gitignore | 2 ++ instrumentation/action_mailer/Appraisals | 24 ++++++++--------- instrumentation/action_pack/Appraisals | 24 ++++++++--------- .../handlers/action_controller_test.rb | 2 +- .../action_pack/test/test_helper.rb | 5 ---- .../test/test_helpers/app_config.rb | 4 +-- instrumentation/action_view/Appraisals | 24 ++++++++--------- instrumentation/active_job/Appraisals | 12 +++++++-- instrumentation/active_record/Appraisals | 27 ++++++++++--------- instrumentation/active_record/Gemfile | 1 - instrumentation/active_support/Appraisals | 24 ++++++++--------- instrumentation/delayed_job/Appraisals | 27 +++++++++++-------- instrumentation/delayed_job/Gemfile | 1 - instrumentation/rails/Appraisals | 24 ++++++++--------- .../patches/action_controller/metal_test.rb | 2 +- .../rails/test/instrumentation/test_helper.rb | 5 ---- .../test_helpers/app_config.rb | 9 +++---- .../controllers/example_controller.rb | 2 +- .../instrumentation/test_helpers/routes.rb | 2 +- .../rails/test/railtie/dummy/tmp/.gitkeep | 0 21 files changed, 114 insertions(+), 108 deletions(-) create mode 100644 instrumentation/rails/test/railtie/dummy/tmp/.gitkeep diff --git a/.github/actions/test_gem/action.yml b/.github/actions/test_gem/action.yml index 0d4feddb8..d68836326 100644 --- a/.github/actions/test_gem/action.yml +++ b/.github/actions/test_gem/action.yml @@ -95,6 +95,7 @@ runs: run: | # 💎 Install dependencies and generate appraisals 💎 bundle install --quiet --jobs=3 --retry=4 + bundle exec appraisal clean bundle exec appraisal generate working-directory: "${{ steps.setup.outputs.gem_dir }}" diff --git a/.gitignore b/.gitignore index a14376cfb..616fb0f93 100644 --- a/.gitignore +++ b/.gitignore @@ -12,6 +12,7 @@ # Appraisals instrumentation/**/gemfiles +instrumentation/**/tmp/**/* # Sqlite file for tests instrumentation/active_record/db @@ -26,3 +27,4 @@ instrumentation/active_record/db .ruby-version tags +!**/*/.gitkeep diff --git a/instrumentation/action_mailer/Appraisals b/instrumentation/action_mailer/Appraisals index e6c48d017..bd32cbe25 100644 --- a/instrumentation/action_mailer/Appraisals +++ b/instrumentation/action_mailer/Appraisals @@ -4,20 +4,20 @@ # # SPDX-License-Identifier: Apache-2.0 -appraise 'rails-6.1' do - gem 'rails', '~> 6.1.0' -end - -appraise 'rails-7.0' do - gem 'rails', '~> 7.0.0' -end - -appraise 'rails-7.1' do - gem 'rails', '~> 7.1.0' +%w[6.1.0 7.0.0 7.1.0].each do |version| + appraise "action_mailer-#{version}" do + gem 'rails', "~> #{version}" + end end if Gem::Version.new(RUBY_VERSION) >= Gem::Version.new('3.1.0') - appraise 'rails-7.2' do - gem 'rails', '~> 7.2.0' + %w[7.2.0].each do |version| + appraise "action_mailer-#{version}" do + gem 'rails', "~> #{version}" + end + end + + appraise 'action_mailer-latest' do + gem 'rails' end end diff --git a/instrumentation/action_pack/Appraisals b/instrumentation/action_pack/Appraisals index e6c48d017..2f466100e 100644 --- a/instrumentation/action_pack/Appraisals +++ b/instrumentation/action_pack/Appraisals @@ -4,20 +4,20 @@ # # SPDX-License-Identifier: Apache-2.0 -appraise 'rails-6.1' do - gem 'rails', '~> 6.1.0' -end - -appraise 'rails-7.0' do - gem 'rails', '~> 7.0.0' -end - -appraise 'rails-7.1' do - gem 'rails', '~> 7.1.0' +%w[6.1.0 7.0.0 7.1.0].each do |version| + appraise "rails-#{version}" do + gem 'rails', "~> #{version}" + end end if Gem::Version.new(RUBY_VERSION) >= Gem::Version.new('3.1.0') - appraise 'rails-7.2' do - gem 'rails', '~> 7.2.0' + %w[7.2.0].each do |version| + appraise "rails-#{version}" do + gem 'rails', "~> #{version}" + end + end + + appraise 'rails-latest' do + gem 'rails' end end diff --git a/instrumentation/action_pack/test/opentelemetry/instrumentation/action_pack/handlers/action_controller_test.rb b/instrumentation/action_pack/test/opentelemetry/instrumentation/action_pack/handlers/action_controller_test.rb index 00433df24..bec7648c5 100644 --- a/instrumentation/action_pack/test/opentelemetry/instrumentation/action_pack/handlers/action_controller_test.rb +++ b/instrumentation/action_pack/test/opentelemetry/instrumentation/action_pack/handlers/action_controller_test.rb @@ -16,7 +16,7 @@ let(:exporter) { EXPORTER } let(:spans) { exporter.finished_spans } let(:span) { exporter.finished_spans.last } - let(:rails_app) { DEFAULT_RAILS_APP } + let(:rails_app) { AppConfig.initialize_app } let(:config) { {} } # Clear captured spans diff --git a/instrumentation/action_pack/test/test_helper.rb b/instrumentation/action_pack/test/test_helper.rb index 4405450bc..c6ad0deee 100644 --- a/instrumentation/action_pack/test/test_helper.rb +++ b/instrumentation/action_pack/test/test_helper.rb @@ -22,8 +22,3 @@ c.use 'OpenTelemetry::Instrumentation::ActionPack' c.add_span_processor span_processor end - -# Create a globally available Rails app, this should be used in test unless -# specifically testing behaviour with different initialization configs. -DEFAULT_RAILS_APP = AppConfig.initialize_app -Rails.application = DEFAULT_RAILS_APP diff --git a/instrumentation/action_pack/test/test_helpers/app_config.rb b/instrumentation/action_pack/test/test_helpers/app_config.rb index f00733ad4..ce0f7ff6d 100644 --- a/instrumentation/action_pack/test/test_helpers/app_config.rb +++ b/instrumentation/action_pack/test/test_helpers/app_config.rb @@ -4,8 +4,8 @@ # # SPDX-License-Identifier: Apache-2.0 -class Application < Rails::Application; end require 'action_controller/railtie' +class Application < Rails::Application; end require_relative 'middlewares' require_relative 'controllers' require_relative 'routes' @@ -30,7 +30,7 @@ def initialize_app(use_exceptions_app: false, remove_rack_tracer_middleware: fal case Rails.version when /^6\.1/ apply_rails_6_1_configs(new_app) - when /^7\./ + when /^7|8\./ apply_rails_7_configs(new_app) end diff --git a/instrumentation/action_view/Appraisals b/instrumentation/action_view/Appraisals index e6c48d017..76b37a422 100644 --- a/instrumentation/action_view/Appraisals +++ b/instrumentation/action_view/Appraisals @@ -4,20 +4,20 @@ # # SPDX-License-Identifier: Apache-2.0 -appraise 'rails-6.1' do - gem 'rails', '~> 6.1.0' -end - -appraise 'rails-7.0' do - gem 'rails', '~> 7.0.0' -end - -appraise 'rails-7.1' do - gem 'rails', '~> 7.1.0' +%w[6.1.0 7.0.0 7.1.0].each do |version| + appraise "action_view-#{version}" do + gem 'rails', "~> #{version}" + end end if Gem::Version.new(RUBY_VERSION) >= Gem::Version.new('3.1.0') - appraise 'rails-7.2' do - gem 'rails', '~> 7.2.0' + %w[7.2.0].each do |version| + appraise "rails-#{version}" do + gem 'rails', "~> #{version}" + end + end + + appraise 'rails-latest' do + gem 'rails' end end diff --git a/instrumentation/active_job/Appraisals b/instrumentation/active_job/Appraisals index a25edd334..6d4d4dc42 100644 --- a/instrumentation/active_job/Appraisals +++ b/instrumentation/active_job/Appraisals @@ -10,6 +10,14 @@ end end -appraise 'activejob-latest' do - gem 'activejob' +if Gem::Version.new(RUBY_VERSION) >= Gem::Version.new('3.1.0') + %w[7.2.0].each do |version| + appraise "activejob-#{version}" do + gem 'activejob', "~> #{version}" + end + end + + appraise 'activejob-latest' do + gem 'activejob' + end end diff --git a/instrumentation/active_record/Appraisals b/instrumentation/active_record/Appraisals index 36f641b64..faa0add16 100644 --- a/instrumentation/active_record/Appraisals +++ b/instrumentation/active_record/Appraisals @@ -4,20 +4,23 @@ # # SPDX-License-Identifier: Apache-2.0 -appraise 'activerecord-6.1' do - gem 'activerecord', '~> 6.1.0' -end - -appraise 'activerecord-7.0' do - gem 'activerecord', '~> 7.0.0' -end - -appraise 'activerecord-7.1' do - gem 'activerecord', '~> 7.1.0' +%w[6.1.0 7.0.0 7.1.0].each do |version| + appraise "activerecord-#{version}" do + gem 'sqlite3', '~> 1.4' + gem 'activerecord', "~> #{version}" + end end if Gem::Version.new(RUBY_VERSION) >= Gem::Version.new('3.1.0') - appraise 'activerecord-7.2' do - gem 'activerecord', '~> 7.2.0' + %w[7.2.0].each do |version| + appraise "activerecord-#{version}" do + gem 'sqlite3', '~> 1.4' + gem 'activerecord', "~> #{version}" + end + end + + appraise 'activerecord-latest' do + gem 'sqlite3', '>= 2.1' + gem 'activerecord' end end diff --git a/instrumentation/active_record/Gemfile b/instrumentation/active_record/Gemfile index 4475d27bf..02f64ca9a 100644 --- a/instrumentation/active_record/Gemfile +++ b/instrumentation/active_record/Gemfile @@ -12,5 +12,4 @@ group :test do gem 'byebug' gem 'opentelemetry-instrumentation-base', path: '../base' gem 'pry-byebug' - gem 'sqlite3', '~> 1.4' end diff --git a/instrumentation/active_support/Appraisals b/instrumentation/active_support/Appraisals index ef832823b..3a6dfc3fe 100644 --- a/instrumentation/active_support/Appraisals +++ b/instrumentation/active_support/Appraisals @@ -4,20 +4,20 @@ # # SPDX-License-Identifier: Apache-2.0 -appraise 'activesupport-6.1' do - gem 'activesupport', '~> 6.1.0' -end - -appraise 'activesupport-7.0' do - gem 'activesupport', '~> 7.0.0' -end - -appraise 'activesupport-7.1' do - gem 'activesupport', '~> 7.1.0' +%w[6.1.0 7.0.0 7.1.0].each do |version| + appraise "activesupport-#{version}" do + gem 'activesupport', "~> #{version}" + end end if Gem::Version.new(RUBY_VERSION) >= Gem::Version.new('3.1.0') - appraise 'activesupport-7.2' do - gem 'activesupport', '~> 7.2.0' + %w[7.2.0].each do |version| + appraise "activesupport-#{version}" do + gem 'activesupport', "~> #{version}" + end + end + + appraise 'activesupport-latest' do + gem 'activesupport' end end diff --git a/instrumentation/delayed_job/Appraisals b/instrumentation/delayed_job/Appraisals index e4d86e84f..9099f1369 100644 --- a/instrumentation/delayed_job/Appraisals +++ b/instrumentation/delayed_job/Appraisals @@ -4,18 +4,23 @@ # # SPDX-License-Identifier: Apache-2.0 -appraise 'delayed_job_4.1-rails-latest' do - gem 'activejob' +%w[6.1.0 7.0.0 7.1.0].each do |version| + appraise "delayed_job_4.1-activejob-#{version}" do + gem 'delayed_job', '~> 4.1' + gem 'activejob', "~> #{version}" + end end -appraise 'delayed_job_4.1-rails-7.1' do - gem 'activejob', '~> 7.1.0' -end - -appraise 'delayed_job_4.1-rails-7.0' do - gem 'activejob', '~> 7.0.0' -end +if Gem::Version.new(RUBY_VERSION) >= Gem::Version.new('3.1.0') + %w[7.2.0].each do |version| + appraise "delayed_job-4.1-activejob-#{version}" do + gem 'delayed_job', '~> 4.1' + gem 'activejob', "~> #{version}" + end + end -appraise 'delayed_job-4.1-rails-6.1' do - gem 'activejob', '~> 6.1.0' + appraise 'delayed_job-latest' do + gem 'delayed_job' + gem 'activejob' + end end diff --git a/instrumentation/delayed_job/Gemfile b/instrumentation/delayed_job/Gemfile index 3c182227f..2baf57ac4 100644 --- a/instrumentation/delayed_job/Gemfile +++ b/instrumentation/delayed_job/Gemfile @@ -9,6 +9,5 @@ source 'https://rubygems.org' gemspec group :test do - gem 'delayed_job', '~> 4.1' gem 'opentelemetry-instrumentation-base', path: '../base' end diff --git a/instrumentation/rails/Appraisals b/instrumentation/rails/Appraisals index e6c48d017..2f466100e 100644 --- a/instrumentation/rails/Appraisals +++ b/instrumentation/rails/Appraisals @@ -4,20 +4,20 @@ # # SPDX-License-Identifier: Apache-2.0 -appraise 'rails-6.1' do - gem 'rails', '~> 6.1.0' -end - -appraise 'rails-7.0' do - gem 'rails', '~> 7.0.0' -end - -appraise 'rails-7.1' do - gem 'rails', '~> 7.1.0' +%w[6.1.0 7.0.0 7.1.0].each do |version| + appraise "rails-#{version}" do + gem 'rails', "~> #{version}" + end end if Gem::Version.new(RUBY_VERSION) >= Gem::Version.new('3.1.0') - appraise 'rails-7.2' do - gem 'rails', '~> 7.2.0' + %w[7.2.0].each do |version| + appraise "rails-#{version}" do + gem 'rails', "~> #{version}" + end + end + + appraise 'rails-latest' do + gem 'rails' end end diff --git a/instrumentation/rails/test/instrumentation/opentelemetry/instrumentation/rails/patches/action_controller/metal_test.rb b/instrumentation/rails/test/instrumentation/opentelemetry/instrumentation/rails/patches/action_controller/metal_test.rb index 96fd40cb3..731d4fead 100644 --- a/instrumentation/rails/test/instrumentation/opentelemetry/instrumentation/rails/patches/action_controller/metal_test.rb +++ b/instrumentation/rails/test/instrumentation/opentelemetry/instrumentation/rails/patches/action_controller/metal_test.rb @@ -12,7 +12,7 @@ let(:exporter) { EXPORTER } let(:spans) { exporter.finished_spans } let(:span) { exporter.finished_spans.last } - let(:rails_app) { DEFAULT_RAILS_APP } + let(:rails_app) { AppConfig.initialize_app } # Clear captured spans before { exporter.reset } diff --git a/instrumentation/rails/test/instrumentation/test_helper.rb b/instrumentation/rails/test/instrumentation/test_helper.rb index 2690c04d0..b95b64235 100644 --- a/instrumentation/rails/test/instrumentation/test_helper.rb +++ b/instrumentation/rails/test/instrumentation/test_helper.rb @@ -23,8 +23,3 @@ c.use_all c.add_span_processor span_processor end - -# Create a globally available Rails app, this should be used in test unless -# specifically testing behaviour with different initialization configs. -DEFAULT_RAILS_APP = AppConfig.initialize_app -Rails.application = DEFAULT_RAILS_APP diff --git a/instrumentation/rails/test/instrumentation/test_helpers/app_config.rb b/instrumentation/rails/test/instrumentation/test_helpers/app_config.rb index 3e8c23ee1..ad4898551 100644 --- a/instrumentation/rails/test/instrumentation/test_helpers/app_config.rb +++ b/instrumentation/rails/test/instrumentation/test_helpers/app_config.rb @@ -4,8 +4,9 @@ # # SPDX-License-Identifier: Apache-2.0 -class Application < Rails::Application; end require 'action_controller/railtie' +class Application < Rails::Application; end + require_relative 'middlewares' require_relative 'controllers' require_relative 'routes' @@ -28,7 +29,7 @@ def initialize_app(use_exceptions_app: false, remove_rack_tracer_middleware: fal case Rails.version when /^6\.1/ apply_rails_6_1_configs(new_app) - when /^7\./ + when /^7|8\./ apply_rails_7_configs(new_app) end @@ -46,9 +47,7 @@ def initialize_app(use_exceptions_app: false, remove_rack_tracer_middleware: fal private def remove_rack_middleware(application) - application.middleware.delete( - OpenTelemetry::Instrumentation::Rack::Middlewares::TracerMiddleware - ) + application.middleware.delete(Rack::Events) end def add_exceptions_app(application) diff --git a/instrumentation/rails/test/instrumentation/test_helpers/controllers/example_controller.rb b/instrumentation/rails/test/instrumentation/test_helpers/controllers/example_controller.rb index 9bb554655..abe86b587 100644 --- a/instrumentation/rails/test/instrumentation/test_helpers/controllers/example_controller.rb +++ b/instrumentation/rails/test/instrumentation/test_helpers/controllers/example_controller.rb @@ -12,6 +12,6 @@ def ok end def internal_server_error - raise :internal_server_error + raise 'internal_server_error' end end diff --git a/instrumentation/rails/test/instrumentation/test_helpers/routes.rb b/instrumentation/rails/test/instrumentation/test_helpers/routes.rb index 88f0565f2..bef13feb6 100644 --- a/instrumentation/rails/test/instrumentation/test_helpers/routes.rb +++ b/instrumentation/rails/test/instrumentation/test_helpers/routes.rb @@ -6,7 +6,7 @@ def draw_routes(rails_app) rails_app.routes.draw do - get '/ok', to: 'example#ok' + get 'ok', to: 'example#ok' get '/internal_server_error', to: 'example#internal_server_error' end end diff --git a/instrumentation/rails/test/railtie/dummy/tmp/.gitkeep b/instrumentation/rails/test/railtie/dummy/tmp/.gitkeep new file mode 100644 index 000000000..e69de29bb From bf6394d2ef3918a1a67e03b773352598e40adcbc Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Tue, 19 Nov 2024 15:25:24 -0800 Subject: [PATCH 49/58] release: Release 3 gems (#1255) * release: Release 3 gems * opentelemetry-instrumentation-all 0.69.0 (was 0.68.0) * opentelemetry-instrumentation-action_pack 0.10.0 (was 0.9.0) * opentelemetry-instrumentation-rails 0.33.0 (was 0.32.0) * squash: Update instrumentation/all/CHANGELOG.md * squash: Update opentelemetry-instrumentation-rails.gemspec * squash: Update opentelemetry-instrumentation-all.gemspec --------- Co-authored-by: OpenTelemetry Bot <107717825+opentelemetrybot@users.noreply.github.com> Co-authored-by: Ariel Valentin --- instrumentation/action_pack/CHANGELOG.md | 4 ++++ .../lib/opentelemetry/instrumentation/action_pack/version.rb | 2 +- instrumentation/all/CHANGELOG.md | 4 ++++ .../all/lib/opentelemetry/instrumentation/all/version.rb | 2 +- instrumentation/all/opentelemetry-instrumentation-all.gemspec | 2 +- instrumentation/rails/CHANGELOG.md | 4 ++++ .../rails/lib/opentelemetry/instrumentation/rails/version.rb | 2 +- .../rails/opentelemetry-instrumentation-rails.gemspec | 2 +- 8 files changed, 17 insertions(+), 5 deletions(-) diff --git a/instrumentation/action_pack/CHANGELOG.md b/instrumentation/action_pack/CHANGELOG.md index 015a170fd..2532b7580 100644 --- a/instrumentation/action_pack/CHANGELOG.md +++ b/instrumentation/action_pack/CHANGELOG.md @@ -1,5 +1,9 @@ # Release History: opentelemetry-instrumentation-action_pack +### v0.10.0 / 2024-11-19 + +* ADDED: Use Semconv Naming For ActionPack + ### v0.9.0 / 2024-01-09 * BREAKING CHANGE: Use ActiveSupport instead of patches #703 diff --git a/instrumentation/action_pack/lib/opentelemetry/instrumentation/action_pack/version.rb b/instrumentation/action_pack/lib/opentelemetry/instrumentation/action_pack/version.rb index b746ac414..034f29d38 100644 --- a/instrumentation/action_pack/lib/opentelemetry/instrumentation/action_pack/version.rb +++ b/instrumentation/action_pack/lib/opentelemetry/instrumentation/action_pack/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Instrumentation module ActionPack - VERSION = '0.9.0' + VERSION = '0.10.0' end end end diff --git a/instrumentation/all/CHANGELOG.md b/instrumentation/all/CHANGELOG.md index 8bc1cd95a..5fd7e693d 100644 --- a/instrumentation/all/CHANGELOG.md +++ b/instrumentation/all/CHANGELOG.md @@ -1,5 +1,9 @@ # Release History: opentelemetry-instrumentation-all +### v0.69.0 / 2024-11-19 + +* ADDED: Use Semconv Naming For ActionPack + ### v0.68.0 / 2024-10-23 * ADDED: Set span error only for 5xx response range diff --git a/instrumentation/all/lib/opentelemetry/instrumentation/all/version.rb b/instrumentation/all/lib/opentelemetry/instrumentation/all/version.rb index be8895ff5..4ea9fa7d5 100644 --- a/instrumentation/all/lib/opentelemetry/instrumentation/all/version.rb +++ b/instrumentation/all/lib/opentelemetry/instrumentation/all/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Instrumentation module All - VERSION = '0.68.0' + VERSION = '0.69.0' end end end diff --git a/instrumentation/all/opentelemetry-instrumentation-all.gemspec b/instrumentation/all/opentelemetry-instrumentation-all.gemspec index b9906921a..77e99ba93 100644 --- a/instrumentation/all/opentelemetry-instrumentation-all.gemspec +++ b/instrumentation/all/opentelemetry-instrumentation-all.gemspec @@ -50,7 +50,7 @@ Gem::Specification.new do |spec| spec.add_dependency 'opentelemetry-instrumentation-que', '~> 0.8.0' spec.add_dependency 'opentelemetry-instrumentation-racecar', '~> 0.3.0' spec.add_dependency 'opentelemetry-instrumentation-rack', '~> 0.25.0' - spec.add_dependency 'opentelemetry-instrumentation-rails', '~> 0.32.0' + spec.add_dependency 'opentelemetry-instrumentation-rails', '~> 0.33.0' spec.add_dependency 'opentelemetry-instrumentation-rake', '~> 0.2.1' spec.add_dependency 'opentelemetry-instrumentation-rdkafka', '~> 0.4.0' spec.add_dependency 'opentelemetry-instrumentation-redis', '~> 0.25.1' diff --git a/instrumentation/rails/CHANGELOG.md b/instrumentation/rails/CHANGELOG.md index 2ff3b0533..bffd8095d 100644 --- a/instrumentation/rails/CHANGELOG.md +++ b/instrumentation/rails/CHANGELOG.md @@ -1,5 +1,9 @@ # Release History: opentelemetry-instrumentation-rails +### v0.33.0 / 2024-11-19 + +* ADDED: Use Semconv Naming For ActionPack + ### v0.32.0 / 2024-10-22 * BREAKING CHANGE: Rename Active Record find_by_sql spans to query diff --git a/instrumentation/rails/lib/opentelemetry/instrumentation/rails/version.rb b/instrumentation/rails/lib/opentelemetry/instrumentation/rails/version.rb index f5ddd41cb..aa88ce3c9 100644 --- a/instrumentation/rails/lib/opentelemetry/instrumentation/rails/version.rb +++ b/instrumentation/rails/lib/opentelemetry/instrumentation/rails/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Instrumentation module Rails - VERSION = '0.32.0' + VERSION = '0.33.0' end end end diff --git a/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec b/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec index 8182d9f69..c028fa093 100644 --- a/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec +++ b/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec @@ -27,7 +27,7 @@ Gem::Specification.new do |spec| spec.add_dependency 'opentelemetry-api', '~> 1.0' spec.add_dependency 'opentelemetry-instrumentation-action_mailer', '~> 0.2.0' - spec.add_dependency 'opentelemetry-instrumentation-action_pack', '~> 0.9.0' + spec.add_dependency 'opentelemetry-instrumentation-action_pack', '~> 0.10.0' spec.add_dependency 'opentelemetry-instrumentation-action_view', '~> 0.7.0' spec.add_dependency 'opentelemetry-instrumentation-active_job', '~> 0.7.0' spec.add_dependency 'opentelemetry-instrumentation-active_record', '~> 0.8.0' From 16bef8547c533e8691ef446244ba6603650e4018 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ole=20Peder=20Brandtz=C3=A6g?= Date: Thu, 21 Nov 2024 13:03:58 +0100 Subject: [PATCH 50/58] fix: pass block argument in ActiveRecord `find_by_sql` patch (#1259) --- .../active_record/patches/querying.rb | 4 +- .../active_record/patches/querying_test.rb | 79 +++++++++++++++++++ 2 files changed, 81 insertions(+), 2 deletions(-) diff --git a/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/patches/querying.rb b/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/patches/querying.rb index 094575ae4..0b9f37904 100644 --- a/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/patches/querying.rb +++ b/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/patches/querying.rb @@ -20,9 +20,9 @@ class << base module ClassMethods method_name = ::ActiveRecord.version >= Gem::Version.new('7.0.0') ? :_query_by_sql : :find_by_sql - define_method(method_name) do |*args, **kwargs| + define_method(method_name) do |*args, **kwargs, &block| tracer.in_span("#{self} query") do - super(*args, **kwargs) + super(*args, **kwargs, &block) end end diff --git a/instrumentation/active_record/test/instrumentation/active_record/patches/querying_test.rb b/instrumentation/active_record/test/instrumentation/active_record/patches/querying_test.rb index 879af50e6..5a398a3c2 100644 --- a/instrumentation/active_record/test/instrumentation/active_record/patches/querying_test.rb +++ b/instrumentation/active_record/test/instrumentation/active_record/patches/querying_test.rb @@ -14,6 +14,11 @@ let(:spans) { exporter.finished_spans } before { exporter.reset } + after do + ActiveRecord::Base.subclasses.each do |model| + model.connection.truncate(model.table_name) + end + end describe 'query' do it 'traces' do @@ -28,5 +33,79 @@ _(user_find_spans.length).must_equal(2) _(account_find_span).wont_be_nil end + + describe 'find_by_sql' do + it 'creates a span' do + Account.create! + + Account.find_by_sql('SELECT * FROM accounts') + + account_find_span = spans.find { |s| s.name == 'Account query' } + _(account_find_span).wont_be_nil + _(account_find_span.attributes).must_be_empty + end + + describe 'given a block' do + it 'creates a span' do + account = Account.create! + + record_ids = [] + + Account.find_by_sql('SELECT * FROM accounts') do |record| + record_ids << record.id + end + + account_find_span = spans.find { |s| s.name == 'Account query' } + _(account_find_span).wont_be_nil + _(account_find_span.attributes).must_be_empty + + _(record_ids).must_equal([account.id]) + end + end + end + + describe 'find_by' do + it 'creates a span' do + account = Account.create! + User.create!(account: account) + + Account.find_by(id: account.id) + + account_find_span = spans.find { |s| s.name == 'Account query' } + _(account_find_span).wont_be_nil + _(account_find_span.attributes).must_be_empty + end + end + + describe 'find' do + it 'creates a span' do + account = Account.create! + User.create!(account: account) + + Account.find(account.id) + + account_find_span = spans.find { |s| s.name == 'Account query' } + _(account_find_span).wont_be_nil + _(account_find_span.attributes).must_be_empty + end + + describe 'given a block' do + it 'creates a span' do + account = Account.create! + User.create!(account: account) + + record_ids = [] + + Account.find(account.id) do |record| + record_ids << record.id + end + + account_find_span = spans.find { |s| s.name == 'Account query' } + _(account_find_span).wont_be_nil + _(account_find_span.attributes).must_be_empty + _(record_ids).must_equal([account.id]) + end + end + end end end From 7ad08f9c80e18fd2ae9e5ff56ae23421c1b6aed9 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Thu, 21 Nov 2024 07:17:18 -0600 Subject: [PATCH 51/58] release: Release opentelemetry-instrumentation-active_record 0.8.1 (was 0.8.0) (#1262) * release: Release opentelemetry-instrumentation-active_record 0.8.1 (was 0.8.0) * squash: Update CHANGELOG.md --------- Co-authored-by: OpenTelemetry Bot <107717825+opentelemetrybot@users.noreply.github.com> Co-authored-by: Ariel Valentin --- instrumentation/active_record/CHANGELOG.md | 4 ++++ .../opentelemetry/instrumentation/active_record/version.rb | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/instrumentation/active_record/CHANGELOG.md b/instrumentation/active_record/CHANGELOG.md index 1d9746ce9..4f5f80d27 100644 --- a/instrumentation/active_record/CHANGELOG.md +++ b/instrumentation/active_record/CHANGELOG.md @@ -1,5 +1,9 @@ # Release History: opentelemetry-instrumentation-active_record +### v0.8.1 / 2024-11-21 + +* FIXED: Pass block argument in ActiveRecord `find_by_sql` patch. + ### v0.8.0 / 2024-10-22 * BREAKING CHANGE: Rename Active Record find_by_sql spans to query diff --git a/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/version.rb b/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/version.rb index 1f42c3003..bf2bf31c3 100644 --- a/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/version.rb +++ b/instrumentation/active_record/lib/opentelemetry/instrumentation/active_record/version.rb @@ -7,7 +7,7 @@ module OpenTelemetry module Instrumentation module ActiveRecord - VERSION = '0.8.0' + VERSION = '0.8.1' end end end From 192b26280794ffa572e9c891053adeac5c729277 Mon Sep 17 00:00:00 2001 From: Hielke Jager Date: Sun, 24 Nov 2024 18:38:18 +0100 Subject: [PATCH 52/58] fix: get correct table name if table name is quoted (#1234) * fix: get correct table name if table name is quoted * Remove double test * Add new line to sql_table_name.json * Stop accepting table name in single quotes --------- Co-authored-by: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com> Co-authored-by: Ariel Valentin --- .../opentelemetry/instrumentation/pg/patches/connection.rb | 2 +- instrumentation/pg/test/fixtures/sql_table_name.json | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/instrumentation/pg/lib/opentelemetry/instrumentation/pg/patches/connection.rb b/instrumentation/pg/lib/opentelemetry/instrumentation/pg/patches/connection.rb index 98814950b..a40da7cd7 100644 --- a/instrumentation/pg/lib/opentelemetry/instrumentation/pg/patches/connection.rb +++ b/instrumentation/pg/lib/opentelemetry/instrumentation/pg/patches/connection.rb @@ -15,7 +15,7 @@ module Patches # Module to prepend to PG::Connection for instrumentation module Connection # rubocop:disable Metrics/ModuleLength # Capture the first word (including letters, digits, underscores, & '.', ) that follows common table commands - TABLE_NAME = /\b(?:FROM|INTO|UPDATE|CREATE\s+TABLE(?:\s+IF\s+NOT\s+EXISTS)?|DROP\s+TABLE(?:\s+IF\s+EXISTS)?|ALTER\s+TABLE(?:\s+IF\s+EXISTS)?)\s+([\w\.]+)/i + TABLE_NAME = /\b(?:FROM|INTO|UPDATE|CREATE\s+TABLE(?:\s+IF\s+NOT\s+EXISTS)?|DROP\s+TABLE(?:\s+IF\s+EXISTS)?|ALTER\s+TABLE(?:\s+IF\s+EXISTS)?)\s+["]?([\w\.]+)["]?/i PG::Constants::EXEC_ISH_METHODS.each do |method| define_method method do |*args, &block| diff --git a/instrumentation/pg/test/fixtures/sql_table_name.json b/instrumentation/pg/test/fixtures/sql_table_name.json index eacd9571f..7cf96681f 100644 --- a/instrumentation/pg/test/fixtures/sql_table_name.json +++ b/instrumentation/pg/test/fixtures/sql_table_name.json @@ -50,5 +50,9 @@ { "name": "from_with_join", "sql": "SELECT columns FROM test_table JOIN table2 ON test_table.column = table2.column" + }, + { + "name": "table_name_with_double_quotes", + "sql": "SELECT columns FROM \"test_table\"" } - ] \ No newline at end of file +] From 5970bd39792f3b7a4dd24bc5f1d4c3badee0af13 Mon Sep 17 00:00:00 2001 From: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com> Date: Sun, 24 Nov 2024 09:46:17 -0800 Subject: [PATCH 53/58] chore: Update rubocop-performance to ~> 1.23.0 (#1257) Co-authored-by: Ariel Valentin --- Gemfile | 2 +- helpers/mysql/opentelemetry-helpers-mysql.gemspec | 2 +- .../opentelemetry-helpers-sql-obfuscation.gemspec | 2 +- .../opentelemetry-instrumentation-action_mailer.gemspec | 2 +- .../opentelemetry-instrumentation-action_pack.gemspec | 2 +- .../opentelemetry-instrumentation-action_view.gemspec | 2 +- .../active_job/opentelemetry-instrumentation-active_job.gemspec | 2 +- ...entelemetry-instrumentation-active_model_serializers.gemspec | 2 +- .../opentelemetry-instrumentation-active_record.gemspec | 2 +- .../opentelemetry-instrumentation-active_support.gemspec | 2 +- instrumentation/all/opentelemetry-instrumentation-all.gemspec | 2 +- .../aws_lambda/opentelemetry-instrumentation-aws_lambda.gemspec | 2 +- .../aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec | 2 +- instrumentation/base/opentelemetry-instrumentation-base.gemspec | 2 +- .../bunny/opentelemetry-instrumentation-bunny.gemspec | 2 +- .../opentelemetry-instrumentation-concurrent_ruby.gemspec | 2 +- .../dalli/opentelemetry-instrumentation-dalli.gemspec | 2 +- .../opentelemetry-instrumentation-delayed_job.gemspec | 2 +- .../ethon/opentelemetry-instrumentation-ethon.gemspec | 2 +- .../excon/opentelemetry-instrumentation-excon.gemspec | 2 +- .../faraday/opentelemetry-instrumentation-faraday.gemspec | 2 +- .../grape/opentelemetry-instrumentation-grape.gemspec | 2 +- .../graphql/opentelemetry-instrumentation-graphql.gemspec | 2 +- instrumentation/gruf/opentelemetry-instrumentation-gruf.gemspec | 2 +- instrumentation/http/opentelemetry-instrumentation-http.gemspec | 2 +- .../opentelemetry-instrumentation-http_client.gemspec | 2 +- .../httpx/opentelemetry-instrumentation-httpx.gemspec | 2 +- .../koala/opentelemetry-instrumentation-koala.gemspec | 2 +- instrumentation/lmdb/opentelemetry-instrumentation-lmdb.gemspec | 2 +- .../mongo/opentelemetry-instrumentation-mongo.gemspec | 2 +- .../mysql2/opentelemetry-instrumentation-mysql2.gemspec | 2 +- .../net_http/opentelemetry-instrumentation-net_http.gemspec | 2 +- instrumentation/pg/opentelemetry-instrumentation-pg.gemspec | 2 +- instrumentation/que/opentelemetry-instrumentation-que.gemspec | 2 +- .../racecar/opentelemetry-instrumentation-racecar.gemspec | 2 +- instrumentation/rack/opentelemetry-instrumentation-rack.gemspec | 2 +- .../rails/opentelemetry-instrumentation-rails.gemspec | 2 +- instrumentation/rake/opentelemetry-instrumentation-rake.gemspec | 2 +- .../rdkafka/opentelemetry-instrumentation-rdkafka.gemspec | 2 +- .../redis/opentelemetry-instrumentation-redis.gemspec | 2 +- .../resque/opentelemetry-instrumentation-resque.gemspec | 2 +- .../restclient/opentelemetry-instrumentation-restclient.gemspec | 2 +- .../rspec/opentelemetry-instrumentation-rspec.gemspec | 2 +- .../ruby_kafka/opentelemetry-instrumentation-ruby_kafka.gemspec | 2 +- .../sidekiq/opentelemetry-instrumentation-sidekiq.gemspec | 2 +- .../sinatra/opentelemetry-instrumentation-sinatra.gemspec | 2 +- .../trilogy/opentelemetry-instrumentation-trilogy.gemspec | 2 +- processor/baggage/opentelemetry-processor-baggage.gemspec | 2 +- propagator/ottrace/opentelemetry-propagator-ottrace.gemspec | 2 +- propagator/vitess/opentelemetry-propagator-vitess.gemspec | 2 +- propagator/xray/opentelemetry-propagator-xray.gemspec | 2 +- resources/azure/opentelemetry-resource-detector-azure.gemspec | 2 +- .../container/opentelemetry-resource-detector-container.gemspec | 2 +- ...pentelemetry-resource-detector-google_cloud_platform.gemspec | 2 +- 54 files changed, 54 insertions(+), 54 deletions(-) diff --git a/Gemfile b/Gemfile index 30ecc9373..b68ccbbeb 100644 --- a/Gemfile +++ b/Gemfile @@ -8,4 +8,4 @@ source 'https://rubygems.org' gem 'rake', '~> 13.0' gem 'rubocop', '~> 1.68.0' -gem 'rubocop-performance', '~> 1.21.0' +gem 'rubocop-performance', '~> 1.23.0' diff --git a/helpers/mysql/opentelemetry-helpers-mysql.gemspec b/helpers/mysql/opentelemetry-helpers-mysql.gemspec index 36a9e5df0..ff93af073 100644 --- a/helpers/mysql/opentelemetry-helpers-mysql.gemspec +++ b/helpers/mysql/opentelemetry-helpers-mysql.gemspec @@ -33,7 +33,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'yard', '~> 0.9' spec.add_development_dependency 'yard-doctest', '~> 0.1.6' diff --git a/helpers/sql-obfuscation/opentelemetry-helpers-sql-obfuscation.gemspec b/helpers/sql-obfuscation/opentelemetry-helpers-sql-obfuscation.gemspec index 5eacadb13..89ea0b8b1 100644 --- a/helpers/sql-obfuscation/opentelemetry-helpers-sql-obfuscation.gemspec +++ b/helpers/sql-obfuscation/opentelemetry-helpers-sql-obfuscation.gemspec @@ -32,7 +32,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'yard', '~> 0.9' spec.add_development_dependency 'yard-doctest', '~> 0.1.6' diff --git a/instrumentation/action_mailer/opentelemetry-instrumentation-action_mailer.gemspec b/instrumentation/action_mailer/opentelemetry-instrumentation-action_mailer.gemspec index 529e98f42..5d4ee2bcc 100644 --- a/instrumentation/action_mailer/opentelemetry-instrumentation-action_mailer.gemspec +++ b/instrumentation/action_mailer/opentelemetry-instrumentation-action_mailer.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/action_pack/opentelemetry-instrumentation-action_pack.gemspec b/instrumentation/action_pack/opentelemetry-instrumentation-action_pack.gemspec index c7ccb8689..f0028d35b 100644 --- a/instrumentation/action_pack/opentelemetry-instrumentation-action_pack.gemspec +++ b/instrumentation/action_pack/opentelemetry-instrumentation-action_pack.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/action_view/opentelemetry-instrumentation-action_view.gemspec b/instrumentation/action_view/opentelemetry-instrumentation-action_view.gemspec index 721f509c6..a3dafc907 100644 --- a/instrumentation/action_view/opentelemetry-instrumentation-action_view.gemspec +++ b/instrumentation/action_view/opentelemetry-instrumentation-action_view.gemspec @@ -37,7 +37,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rails', '>= 6.1' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/active_job/opentelemetry-instrumentation-active_job.gemspec b/instrumentation/active_job/opentelemetry-instrumentation-active_job.gemspec index 2a4e6c9f8..18da7cde0 100644 --- a/instrumentation/active_job/opentelemetry-instrumentation-active_job.gemspec +++ b/instrumentation/active_job/opentelemetry-instrumentation-active_job.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/active_model_serializers/opentelemetry-instrumentation-active_model_serializers.gemspec b/instrumentation/active_model_serializers/opentelemetry-instrumentation-active_model_serializers.gemspec index 3383c1f28..0982b584c 100644 --- a/instrumentation/active_model_serializers/opentelemetry-instrumentation-active_model_serializers.gemspec +++ b/instrumentation/active_model_serializers/opentelemetry-instrumentation-active_model_serializers.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/active_record/opentelemetry-instrumentation-active_record.gemspec b/instrumentation/active_record/opentelemetry-instrumentation-active_record.gemspec index ad6ca55eb..1e6809b81 100644 --- a/instrumentation/active_record/opentelemetry-instrumentation-active_record.gemspec +++ b/instrumentation/active_record/opentelemetry-instrumentation-active_record.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/active_support/opentelemetry-instrumentation-active_support.gemspec b/instrumentation/active_support/opentelemetry-instrumentation-active_support.gemspec index a5d3fe882..8c5ad3aa0 100644 --- a/instrumentation/active_support/opentelemetry-instrumentation-active_support.gemspec +++ b/instrumentation/active_support/opentelemetry-instrumentation-active_support.gemspec @@ -40,7 +40,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/all/opentelemetry-instrumentation-all.gemspec b/instrumentation/all/opentelemetry-instrumentation-all.gemspec index 77e99ba93..c9603b518 100644 --- a/instrumentation/all/opentelemetry-instrumentation-all.gemspec +++ b/instrumentation/all/opentelemetry-instrumentation-all.gemspec @@ -67,7 +67,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/aws_lambda/opentelemetry-instrumentation-aws_lambda.gemspec b/instrumentation/aws_lambda/opentelemetry-instrumentation-aws_lambda.gemspec index c2d9b96e4..049911d7c 100644 --- a/instrumentation/aws_lambda/opentelemetry-instrumentation-aws_lambda.gemspec +++ b/instrumentation/aws_lambda/opentelemetry-instrumentation-aws_lambda.gemspec @@ -37,7 +37,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec b/instrumentation/aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec index 797c0ab37..3648bec85 100644 --- a/instrumentation/aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec +++ b/instrumentation/aws_sdk/opentelemetry-instrumentation-aws_sdk.gemspec @@ -38,7 +38,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/base/opentelemetry-instrumentation-base.gemspec b/instrumentation/base/opentelemetry-instrumentation-base.gemspec index 502e21e24..4debdb6fb 100644 --- a/instrumentation/base/opentelemetry-instrumentation-base.gemspec +++ b/instrumentation/base/opentelemetry-instrumentation-base.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/bunny/opentelemetry-instrumentation-bunny.gemspec b/instrumentation/bunny/opentelemetry-instrumentation-bunny.gemspec index 0a4b39b6f..e7dab3aff 100644 --- a/instrumentation/bunny/opentelemetry-instrumentation-bunny.gemspec +++ b/instrumentation/bunny/opentelemetry-instrumentation-bunny.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/concurrent_ruby/opentelemetry-instrumentation-concurrent_ruby.gemspec b/instrumentation/concurrent_ruby/opentelemetry-instrumentation-concurrent_ruby.gemspec index 0e356e43b..1f71f3fde 100644 --- a/instrumentation/concurrent_ruby/opentelemetry-instrumentation-concurrent_ruby.gemspec +++ b/instrumentation/concurrent_ruby/opentelemetry-instrumentation-concurrent_ruby.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/dalli/opentelemetry-instrumentation-dalli.gemspec b/instrumentation/dalli/opentelemetry-instrumentation-dalli.gemspec index 5ef0f6bc7..6803d287c 100644 --- a/instrumentation/dalli/opentelemetry-instrumentation-dalli.gemspec +++ b/instrumentation/dalli/opentelemetry-instrumentation-dalli.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/delayed_job/opentelemetry-instrumentation-delayed_job.gemspec b/instrumentation/delayed_job/opentelemetry-instrumentation-delayed_job.gemspec index 48dea0abd..c92d19f0b 100644 --- a/instrumentation/delayed_job/opentelemetry-instrumentation-delayed_job.gemspec +++ b/instrumentation/delayed_job/opentelemetry-instrumentation-delayed_job.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'sqlite3' spec.add_development_dependency 'webmock', '~> 3.24.0' diff --git a/instrumentation/ethon/opentelemetry-instrumentation-ethon.gemspec b/instrumentation/ethon/opentelemetry-instrumentation-ethon.gemspec index 4a9b1050f..5dfa222ae 100644 --- a/instrumentation/ethon/opentelemetry-instrumentation-ethon.gemspec +++ b/instrumentation/ethon/opentelemetry-instrumentation-ethon.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/excon/opentelemetry-instrumentation-excon.gemspec b/instrumentation/excon/opentelemetry-instrumentation-excon.gemspec index 3c07dd9b7..3373aa8a2 100644 --- a/instrumentation/excon/opentelemetry-instrumentation-excon.gemspec +++ b/instrumentation/excon/opentelemetry-instrumentation-excon.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/faraday/opentelemetry-instrumentation-faraday.gemspec b/instrumentation/faraday/opentelemetry-instrumentation-faraday.gemspec index a115967d5..c74bfc26b 100644 --- a/instrumentation/faraday/opentelemetry-instrumentation-faraday.gemspec +++ b/instrumentation/faraday/opentelemetry-instrumentation-faraday.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/grape/opentelemetry-instrumentation-grape.gemspec b/instrumentation/grape/opentelemetry-instrumentation-grape.gemspec index 71d355fe3..3ee053af9 100644 --- a/instrumentation/grape/opentelemetry-instrumentation-grape.gemspec +++ b/instrumentation/grape/opentelemetry-instrumentation-grape.gemspec @@ -39,7 +39,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/graphql/opentelemetry-instrumentation-graphql.gemspec b/instrumentation/graphql/opentelemetry-instrumentation-graphql.gemspec index 43ad220bf..cbce4c52a 100644 --- a/instrumentation/graphql/opentelemetry-instrumentation-graphql.gemspec +++ b/instrumentation/graphql/opentelemetry-instrumentation-graphql.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/gruf/opentelemetry-instrumentation-gruf.gemspec b/instrumentation/gruf/opentelemetry-instrumentation-gruf.gemspec index 4a955c9a3..a7b95ea1e 100644 --- a/instrumentation/gruf/opentelemetry-instrumentation-gruf.gemspec +++ b/instrumentation/gruf/opentelemetry-instrumentation-gruf.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers' spec.add_development_dependency 'rake', '~> 12.3.3' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/http/opentelemetry-instrumentation-http.gemspec b/instrumentation/http/opentelemetry-instrumentation-http.gemspec index 88a000aba..cee534cc9 100644 --- a/instrumentation/http/opentelemetry-instrumentation-http.gemspec +++ b/instrumentation/http/opentelemetry-instrumentation-http.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/http_client/opentelemetry-instrumentation-http_client.gemspec b/instrumentation/http_client/opentelemetry-instrumentation-http_client.gemspec index a5b722937..99c056b80 100644 --- a/instrumentation/http_client/opentelemetry-instrumentation-http_client.gemspec +++ b/instrumentation/http_client/opentelemetry-instrumentation-http_client.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/httpx/opentelemetry-instrumentation-httpx.gemspec b/instrumentation/httpx/opentelemetry-instrumentation-httpx.gemspec index 0f56283b8..d285bad81 100644 --- a/instrumentation/httpx/opentelemetry-instrumentation-httpx.gemspec +++ b/instrumentation/httpx/opentelemetry-instrumentation-httpx.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/koala/opentelemetry-instrumentation-koala.gemspec b/instrumentation/koala/opentelemetry-instrumentation-koala.gemspec index 61a611cec..7e95f6392 100644 --- a/instrumentation/koala/opentelemetry-instrumentation-koala.gemspec +++ b/instrumentation/koala/opentelemetry-instrumentation-koala.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/lmdb/opentelemetry-instrumentation-lmdb.gemspec b/instrumentation/lmdb/opentelemetry-instrumentation-lmdb.gemspec index 12056bc40..535a9994e 100644 --- a/instrumentation/lmdb/opentelemetry-instrumentation-lmdb.gemspec +++ b/instrumentation/lmdb/opentelemetry-instrumentation-lmdb.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/mongo/opentelemetry-instrumentation-mongo.gemspec b/instrumentation/mongo/opentelemetry-instrumentation-mongo.gemspec index c70528fc7..b1831edd6 100644 --- a/instrumentation/mongo/opentelemetry-instrumentation-mongo.gemspec +++ b/instrumentation/mongo/opentelemetry-instrumentation-mongo.gemspec @@ -37,7 +37,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/mysql2/opentelemetry-instrumentation-mysql2.gemspec b/instrumentation/mysql2/opentelemetry-instrumentation-mysql2.gemspec index 2f09b9e9b..31d521db1 100644 --- a/instrumentation/mysql2/opentelemetry-instrumentation-mysql2.gemspec +++ b/instrumentation/mysql2/opentelemetry-instrumentation-mysql2.gemspec @@ -38,7 +38,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'pry' spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/net_http/opentelemetry-instrumentation-net_http.gemspec b/instrumentation/net_http/opentelemetry-instrumentation-net_http.gemspec index c9603deaa..e557f72a4 100644 --- a/instrumentation/net_http/opentelemetry-instrumentation-net_http.gemspec +++ b/instrumentation/net_http/opentelemetry-instrumentation-net_http.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rake', '~> 13.0.1' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/pg/opentelemetry-instrumentation-pg.gemspec b/instrumentation/pg/opentelemetry-instrumentation-pg.gemspec index 0d040639d..dd985d2e0 100644 --- a/instrumentation/pg/opentelemetry-instrumentation-pg.gemspec +++ b/instrumentation/pg/opentelemetry-instrumentation-pg.gemspec @@ -38,7 +38,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'pry' spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/que/opentelemetry-instrumentation-que.gemspec b/instrumentation/que/opentelemetry-instrumentation-que.gemspec index bd6a2e5df..d9599515d 100644 --- a/instrumentation/que/opentelemetry-instrumentation-que.gemspec +++ b/instrumentation/que/opentelemetry-instrumentation-que.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/racecar/opentelemetry-instrumentation-racecar.gemspec b/instrumentation/racecar/opentelemetry-instrumentation-racecar.gemspec index cf093ecba..842597e02 100644 --- a/instrumentation/racecar/opentelemetry-instrumentation-racecar.gemspec +++ b/instrumentation/racecar/opentelemetry-instrumentation-racecar.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/rack/opentelemetry-instrumentation-rack.gemspec b/instrumentation/rack/opentelemetry-instrumentation-rack.gemspec index d3029b8d6..5f04dbca3 100644 --- a/instrumentation/rack/opentelemetry-instrumentation-rack.gemspec +++ b/instrumentation/rack/opentelemetry-instrumentation-rack.gemspec @@ -37,7 +37,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec b/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec index c028fa093..0328a44ae 100644 --- a/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec +++ b/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec @@ -42,7 +42,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rack-test', '~> 2.1.0' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/rake/opentelemetry-instrumentation-rake.gemspec b/instrumentation/rake/opentelemetry-instrumentation-rake.gemspec index 9cc83ecde..3c6825d72 100644 --- a/instrumentation/rake/opentelemetry-instrumentation-rake.gemspec +++ b/instrumentation/rake/opentelemetry-instrumentation-rake.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.0' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/rdkafka/opentelemetry-instrumentation-rdkafka.gemspec b/instrumentation/rdkafka/opentelemetry-instrumentation-rdkafka.gemspec index a2e7bd62f..72bf2056c 100644 --- a/instrumentation/rdkafka/opentelemetry-instrumentation-rdkafka.gemspec +++ b/instrumentation/rdkafka/opentelemetry-instrumentation-rdkafka.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'pry-byebug' unless RUBY_ENGINE == 'jruby' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/redis/opentelemetry-instrumentation-redis.gemspec b/instrumentation/redis/opentelemetry-instrumentation-redis.gemspec index e5beb6d00..7e00c7a55 100644 --- a/instrumentation/redis/opentelemetry-instrumentation-redis.gemspec +++ b/instrumentation/redis/opentelemetry-instrumentation-redis.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/resque/opentelemetry-instrumentation-resque.gemspec b/instrumentation/resque/opentelemetry-instrumentation-resque.gemspec index 6aa0fec81..89cc03eaf 100644 --- a/instrumentation/resque/opentelemetry-instrumentation-resque.gemspec +++ b/instrumentation/resque/opentelemetry-instrumentation-resque.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/restclient/opentelemetry-instrumentation-restclient.gemspec b/instrumentation/restclient/opentelemetry-instrumentation-restclient.gemspec index 1788cbe54..dadfa6d14 100644 --- a/instrumentation/restclient/opentelemetry-instrumentation-restclient.gemspec +++ b/instrumentation/restclient/opentelemetry-instrumentation-restclient.gemspec @@ -34,7 +34,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/rspec/opentelemetry-instrumentation-rspec.gemspec b/instrumentation/rspec/opentelemetry-instrumentation-rspec.gemspec index 3aa906b8a..f7129e984 100644 --- a/instrumentation/rspec/opentelemetry-instrumentation-rspec.gemspec +++ b/instrumentation/rspec/opentelemetry-instrumentation-rspec.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/ruby_kafka/opentelemetry-instrumentation-ruby_kafka.gemspec b/instrumentation/ruby_kafka/opentelemetry-instrumentation-ruby_kafka.gemspec index d6376ae92..2e8bbfba5 100644 --- a/instrumentation/ruby_kafka/opentelemetry-instrumentation-ruby_kafka.gemspec +++ b/instrumentation/ruby_kafka/opentelemetry-instrumentation-ruby_kafka.gemspec @@ -35,7 +35,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/sidekiq/opentelemetry-instrumentation-sidekiq.gemspec b/instrumentation/sidekiq/opentelemetry-instrumentation-sidekiq.gemspec index a2fa3b643..0e63e3800 100644 --- a/instrumentation/sidekiq/opentelemetry-instrumentation-sidekiq.gemspec +++ b/instrumentation/sidekiq/opentelemetry-instrumentation-sidekiq.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/sinatra/opentelemetry-instrumentation-sinatra.gemspec b/instrumentation/sinatra/opentelemetry-instrumentation-sinatra.gemspec index e5347d480..0f77e5b23 100644 --- a/instrumentation/sinatra/opentelemetry-instrumentation-sinatra.gemspec +++ b/instrumentation/sinatra/opentelemetry-instrumentation-sinatra.gemspec @@ -36,7 +36,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-test-helpers', '~> 0.3' spec.add_development_dependency 'rack-test', '~> 2.1' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/instrumentation/trilogy/opentelemetry-instrumentation-trilogy.gemspec b/instrumentation/trilogy/opentelemetry-instrumentation-trilogy.gemspec index 081536c7a..dca960cb2 100644 --- a/instrumentation/trilogy/opentelemetry-instrumentation-trilogy.gemspec +++ b/instrumentation/trilogy/opentelemetry-instrumentation-trilogy.gemspec @@ -42,7 +42,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rspec-mocks' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17.1' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/processor/baggage/opentelemetry-processor-baggage.gemspec b/processor/baggage/opentelemetry-processor-baggage.gemspec index 700b16646..8d429b12e 100644 --- a/processor/baggage/opentelemetry-processor-baggage.gemspec +++ b/processor/baggage/opentelemetry-processor-baggage.gemspec @@ -31,7 +31,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'opentelemetry-sdk', '~> 1.1' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/propagator/ottrace/opentelemetry-propagator-ottrace.gemspec b/propagator/ottrace/opentelemetry-propagator-ottrace.gemspec index 7d3b3894d..9e4aa0bcc 100644 --- a/propagator/ottrace/opentelemetry-propagator-ottrace.gemspec +++ b/propagator/ottrace/opentelemetry-propagator-ottrace.gemspec @@ -29,7 +29,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/propagator/vitess/opentelemetry-propagator-vitess.gemspec b/propagator/vitess/opentelemetry-propagator-vitess.gemspec index aaaf55a97..474f06f7c 100644 --- a/propagator/vitess/opentelemetry-propagator-vitess.gemspec +++ b/propagator/vitess/opentelemetry-propagator-vitess.gemspec @@ -30,7 +30,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/propagator/xray/opentelemetry-propagator-xray.gemspec b/propagator/xray/opentelemetry-propagator-xray.gemspec index b1bffaa23..8efcfc243 100644 --- a/propagator/xray/opentelemetry-propagator-xray.gemspec +++ b/propagator/xray/opentelemetry-propagator-xray.gemspec @@ -32,7 +32,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.22.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/resources/azure/opentelemetry-resource-detector-azure.gemspec b/resources/azure/opentelemetry-resource-detector-azure.gemspec index be2a85147..aaa321054 100644 --- a/resources/azure/opentelemetry-resource-detector-azure.gemspec +++ b/resources/azure/opentelemetry-resource-detector-azure.gemspec @@ -31,7 +31,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/resources/container/opentelemetry-resource-detector-container.gemspec b/resources/container/opentelemetry-resource-detector-container.gemspec index 6160f36d7..1589db320 100644 --- a/resources/container/opentelemetry-resource-detector-container.gemspec +++ b/resources/container/opentelemetry-resource-detector-container.gemspec @@ -31,7 +31,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17' spec.add_development_dependency 'yard', '~> 0.9' diff --git a/resources/google_cloud_platform/opentelemetry-resource-detector-google_cloud_platform.gemspec b/resources/google_cloud_platform/opentelemetry-resource-detector-google_cloud_platform.gemspec index 11ad9a060..564b9d620 100644 --- a/resources/google_cloud_platform/opentelemetry-resource-detector-google_cloud_platform.gemspec +++ b/resources/google_cloud_platform/opentelemetry-resource-detector-google_cloud_platform.gemspec @@ -32,7 +32,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'minitest', '~> 5.0' spec.add_development_dependency 'rake', '~> 13.0' spec.add_development_dependency 'rubocop', '~> 1.68.0' - spec.add_development_dependency 'rubocop-performance', '~> 1.22.0' + spec.add_development_dependency 'rubocop-performance', '~> 1.23.0' spec.add_development_dependency 'simplecov', '~> 0.17' spec.add_development_dependency 'webmock', '~> 3.24.0' spec.add_development_dependency 'yard', '~> 0.9' From c387a8d9d935597a6c52914b97c56575f3d7f911 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 24 Nov 2024 17:53:45 +0000 Subject: [PATCH 54/58] chore: bump DavidAnson/markdownlint-cli2-action from 17 to 18 (#1243) Bumps [DavidAnson/markdownlint-cli2-action](https://github.com/davidanson/markdownlint-cli2-action) from 17 to 18. - [Release notes](https://github.com/davidanson/markdownlint-cli2-action/releases) - [Commits](https://github.com/davidanson/markdownlint-cli2-action/compare/v17...v18) --- updated-dependencies: - dependency-name: DavidAnson/markdownlint-cli2-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Ariel Valentin --- .github/workflows/ci-markdownlint.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-markdownlint.yml b/.github/workflows/ci-markdownlint.yml index 646484a9b..037b2fa9e 100644 --- a/.github/workflows/ci-markdownlint.yml +++ b/.github/workflows/ci-markdownlint.yml @@ -11,7 +11,7 @@ jobs: # equivalent cli: markdownlint-cli2 "**/*.md" "#**/CHANGELOG.md" --config .markdownlint.json - name: "Markdown Lint Check" - uses: DavidAnson/markdownlint-cli2-action@v17 + uses: DavidAnson/markdownlint-cli2-action@v18 with: fix: false globs: | From ad8988bc4a11bafa0925c3137f2ae32bc57f40a0 Mon Sep 17 00:00:00 2001 From: Victorsesan <156327324+Victorsesan@users.noreply.github.com> Date: Sun, 24 Nov 2024 19:16:06 +0100 Subject: [PATCH 55/58] refactor: Freeze all range objects #1172 (#1222) * Main Created a readable constant in 8 files to freeze ranges 100..399 . Relate to #1172 * refactor: Create a readable constant in 8 files to freeze ranges 100..399 . Reviewed-by: kaylareopelle Refs: #1172 * refactor: Fix rubocop ruby linter failures Reviewed-by: kaylareopelle Refs: #1172 * refactor: Fix rubocop ruby linter failures Reviewed-by: kaylareopelle Refs: #1172 --------- Co-authored-by: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com> Co-authored-by: Ariel Valentin --- docker-compose.yml | 2 -- .../instrumentation/ethon/patches/easy.rb | 5 ++++- .../excon/middlewares/tracer_middleware.rb | 13 ++++--------- .../faraday/middlewares/tracer_middleware.rb | 7 +++++-- .../instrumentation/http/patches/client.rb | 5 ++++- .../instrumentation/http_client/patches/client.rb | 5 ++++- .../opentelemetry/instrumentation/httpx/plugin.rb | 5 ++++- .../net/http/patches/instrumentation.rb | 5 ++++- .../instrumentation/restclient/patches/request.rb | 8 +++++--- 9 files changed, 34 insertions(+), 21 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index b77ad0e9d..a2fb5633f 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,5 +1,3 @@ -version: "3.5" - x-shared-config: base: &base command: /bin/bash diff --git a/instrumentation/ethon/lib/opentelemetry/instrumentation/ethon/patches/easy.rb b/instrumentation/ethon/lib/opentelemetry/instrumentation/ethon/patches/easy.rb index 74791818e..7850ac565 100644 --- a/instrumentation/ethon/lib/opentelemetry/instrumentation/ethon/patches/easy.rb +++ b/instrumentation/ethon/lib/opentelemetry/instrumentation/ethon/patches/easy.rb @@ -16,6 +16,9 @@ module Easy end HTTP_METHODS_TO_SPAN_NAMES = Hash.new { |h, k| h[k] = "HTTP #{k}" } + # Constant for the HTTP status range + HTTP_STATUS_SUCCESS_RANGE = (100..399) + def http_request(url, action_name, options = {}) @otel_method = ACTION_NAMES_TO_HTTP_METHODS[action_name] super @@ -42,7 +45,7 @@ def complete @otel_span.status = OpenTelemetry::Trace::Status.error("Request has failed: #{message}") else @otel_span.set_attribute('http.status_code', response_code) - @otel_span.status = OpenTelemetry::Trace::Status.error unless (100..399).cover?(response_code.to_i) + @otel_span.status = OpenTelemetry::Trace::Status.error unless HTTP_STATUS_SUCCESS_RANGE.cover?(response_code.to_i) end ensure @otel_span&.finish diff --git a/instrumentation/excon/lib/opentelemetry/instrumentation/excon/middlewares/tracer_middleware.rb b/instrumentation/excon/lib/opentelemetry/instrumentation/excon/middlewares/tracer_middleware.rb index 592fdb793..b17bfc662 100644 --- a/instrumentation/excon/lib/opentelemetry/instrumentation/excon/middlewares/tracer_middleware.rb +++ b/instrumentation/excon/lib/opentelemetry/instrumentation/excon/middlewares/tracer_middleware.rb @@ -21,11 +21,13 @@ class TracerMiddleware < ::Excon::Middleware::Base hash[uppercase_method] ||= "HTTP #{uppercase_method}" end.freeze + # Constant for the HTTP status range + HTTP_STATUS_SUCCESS_RANGE = (100..399) + def request_call(datum) return @stack.request_call(datum) if untraced?(datum) http_method = HTTP_METHODS_TO_UPPERCASE[datum[:method]] - attributes = { OpenTelemetry::SemanticConventions::Trace::HTTP_HOST => datum[:host], OpenTelemetry::SemanticConventions::Trace::HTTP_METHOD => http_method, @@ -35,19 +37,14 @@ def request_call(datum) OpenTelemetry::SemanticConventions::Trace::NET_PEER_NAME => datum[:hostname], OpenTelemetry::SemanticConventions::Trace::NET_PEER_PORT => datum[:port] } - peer_service = Excon::Instrumentation.instance.config[:peer_service] attributes[OpenTelemetry::SemanticConventions::Trace::PEER_SERVICE] = peer_service if peer_service attributes.merge!(OpenTelemetry::Common::HTTP::ClientContext.attributes) - span = tracer.start_span(HTTP_METHODS_TO_SPAN_NAMES[http_method], attributes: attributes, kind: :client) ctx = OpenTelemetry::Trace.context_with_span(span) - datum[:otel_span] = span datum[:otel_token] = OpenTelemetry::Context.attach(ctx) - OpenTelemetry.propagation.inject(datum[:headers]) - @stack.request_call(datum) end @@ -68,7 +65,6 @@ def self.around_default_stack # If the default stack contains a version of the trace middleware already... existing_trace_middleware = default_stack.find { |m| m <= TracerMiddleware } default_stack.delete(existing_trace_middleware) if existing_trace_middleware - # Inject after the ResponseParser middleware response_middleware_index = default_stack.index(::Excon::Middleware::ResponseParser).to_i default_stack.insert(response_middleware_index + 1, self) @@ -84,7 +80,7 @@ def handle_response(datum) if datum.key?(:response) response = datum[:response] span.set_attribute(OpenTelemetry::SemanticConventions::Trace::HTTP_STATUS_CODE, response[:status]) - span.status = OpenTelemetry::Trace::Status.error unless (100..399).cover?(response[:status].to_i) + span.status = OpenTelemetry::Trace::Status.error unless HTTP_STATUS_SUCCESS_RANGE.cover?(response[:status].to_i) end if datum.key?(:error) @@ -93,7 +89,6 @@ def handle_response(datum) end span.finish - OpenTelemetry::Context.detach(datum.delete(:otel_token)) if datum.include?(:otel_token) end rescue StandardError => e diff --git a/instrumentation/faraday/lib/opentelemetry/instrumentation/faraday/middlewares/tracer_middleware.rb b/instrumentation/faraday/lib/opentelemetry/instrumentation/faraday/middlewares/tracer_middleware.rb index 1b4452ac3..981e44e26 100644 --- a/instrumentation/faraday/lib/opentelemetry/instrumentation/faraday/middlewares/tracer_middleware.rb +++ b/instrumentation/faraday/lib/opentelemetry/instrumentation/faraday/middlewares/tracer_middleware.rb @@ -9,7 +9,7 @@ module Instrumentation module Faraday module Middlewares # TracerMiddleware propagates context and instruments Faraday requests - # by way of its middlware system + # by way of its middleware system class TracerMiddleware < ::Faraday::Middleware HTTP_METHODS_SYMBOL_TO_STRING = { connect: 'CONNECT', @@ -23,6 +23,9 @@ class TracerMiddleware < ::Faraday::Middleware trace: 'TRACE' }.freeze + # Constant for the HTTP status range + HTTP_STATUS_SUCCESS_RANGE = (100..399) + def call(env) http_method = HTTP_METHODS_SYMBOL_TO_STRING[env.method] config = Faraday::Instrumentation.instance.config @@ -68,7 +71,7 @@ def tracer def trace_response(span, status) span.set_attribute('http.status_code', status) - span.status = OpenTelemetry::Trace::Status.error unless (100..399).cover?(status.to_i) + span.status = OpenTelemetry::Trace::Status.error unless HTTP_STATUS_SUCCESS_RANGE.cover?(status.to_i) end end end diff --git a/instrumentation/http/lib/opentelemetry/instrumentation/http/patches/client.rb b/instrumentation/http/lib/opentelemetry/instrumentation/http/patches/client.rb index f814e1a65..1d98cb5c1 100644 --- a/instrumentation/http/lib/opentelemetry/instrumentation/http/patches/client.rb +++ b/instrumentation/http/lib/opentelemetry/instrumentation/http/patches/client.rb @@ -10,6 +10,9 @@ module HTTP module Patches # Module to prepend to HTTP::Client for instrumentation module Client + # Constant for the HTTP status range + HTTP_STATUS_SUCCESS_RANGE = (100..399) + def perform(req, options) uri = req.uri request_method = req.verb.to_s.upcase @@ -43,7 +46,7 @@ def annotate_span_with_response!(span, response) status_code = response.status.to_i span.set_attribute('http.status_code', status_code) - span.status = OpenTelemetry::Trace::Status.error unless (100..399).cover?(status_code.to_i) + span.status = OpenTelemetry::Trace::Status.error unless HTTP_STATUS_SUCCESS_RANGE.cover?(status_code) end def create_request_span_name(request_method, request_path) diff --git a/instrumentation/http_client/lib/opentelemetry/instrumentation/http_client/patches/client.rb b/instrumentation/http_client/lib/opentelemetry/instrumentation/http_client/patches/client.rb index a71c8ad7b..46ad72142 100644 --- a/instrumentation/http_client/lib/opentelemetry/instrumentation/http_client/patches/client.rb +++ b/instrumentation/http_client/lib/opentelemetry/instrumentation/http_client/patches/client.rb @@ -10,6 +10,9 @@ module HttpClient module Patches # Module to prepend to HTTPClient for instrumentation module Client + # Constant for the HTTP status range + HTTP_STATUS_SUCCESS_RANGE = (100..399) + private def do_get_block(req, proxy, conn, &block) @@ -42,7 +45,7 @@ def annotate_span_with_response!(span, response) status_code = response.status_code.to_i span.set_attribute('http.status_code', status_code) - span.status = OpenTelemetry::Trace::Status.error unless (100..399).cover?(status_code.to_i) + span.status = OpenTelemetry::Trace::Status.error unless HTTP_STATUS_SUCCESS_RANGE.cover?(status_code) end def tracer diff --git a/instrumentation/httpx/lib/opentelemetry/instrumentation/httpx/plugin.rb b/instrumentation/httpx/lib/opentelemetry/instrumentation/httpx/plugin.rb index 137fca976..2635a39e6 100644 --- a/instrumentation/httpx/lib/opentelemetry/instrumentation/httpx/plugin.rb +++ b/instrumentation/httpx/lib/opentelemetry/instrumentation/httpx/plugin.rb @@ -11,6 +11,9 @@ module Plugin # Instruments around HTTPX's request/response lifecycle in order to generate # an OTEL trace. class RequestTracer + # Constant for the HTTP status range + HTTP_STATUS_SUCCESS_RANGE = (100..399) + def initialize(request) @request = request end @@ -54,7 +57,7 @@ def finish(response) @span.status = Trace::Status.error("Unhandled exception of type: #{response.error.class}") else @span.set_attribute(OpenTelemetry::SemanticConventions::Trace::HTTP_STATUS_CODE, response.status) - @span.status = Trace::Status.error unless (100..399).cover?(response.status) + @span.status = Trace::Status.error unless HTTP_STATUS_SUCCESS_RANGE.cover?(response.status) end OpenTelemetry::Context.detach(@trace_token) if @trace_token diff --git a/instrumentation/net_http/lib/opentelemetry/instrumentation/net/http/patches/instrumentation.rb b/instrumentation/net_http/lib/opentelemetry/instrumentation/net/http/patches/instrumentation.rb index 725d4c546..6cdbfdb2b 100644 --- a/instrumentation/net_http/lib/opentelemetry/instrumentation/net/http/patches/instrumentation.rb +++ b/instrumentation/net_http/lib/opentelemetry/instrumentation/net/http/patches/instrumentation.rb @@ -14,6 +14,9 @@ module Instrumentation HTTP_METHODS_TO_SPAN_NAMES = Hash.new { |h, k| h[k] = "HTTP #{k}" } USE_SSL_TO_SCHEME = { false => 'http', true => 'https' }.freeze + # Constant for the HTTP status range + HTTP_STATUS_SUCCESS_RANGE = (100..399) + def request(req, body = nil, &block) # Do not trace recursive call for starting the connection return super unless started? @@ -78,7 +81,7 @@ def annotate_span_with_response!(span, response) status_code = response.code.to_i span.set_attribute(OpenTelemetry::SemanticConventions::Trace::HTTP_STATUS_CODE, status_code) - span.status = OpenTelemetry::Trace::Status.error unless (100..399).cover?(status_code.to_i) + span.status = OpenTelemetry::Trace::Status.error unless HTTP_STATUS_SUCCESS_RANGE.cover?(status_code) end def tracer diff --git a/instrumentation/restclient/lib/opentelemetry/instrumentation/restclient/patches/request.rb b/instrumentation/restclient/lib/opentelemetry/instrumentation/restclient/patches/request.rb index afb2fdf11..1507948f7 100644 --- a/instrumentation/restclient/lib/opentelemetry/instrumentation/restclient/patches/request.rb +++ b/instrumentation/restclient/lib/opentelemetry/instrumentation/restclient/patches/request.rb @@ -10,6 +10,9 @@ module RestClient module Patches # Module to prepend to RestClient::Request for instrumentation module Request + # Constant for the HTTP status range + HTTP_STATUS_SUCCESS_RANGE = (100..399) + def execute(&block) trace_request do |_span| super @@ -49,13 +52,12 @@ def trace_request # If so, add additional attributes. if response.is_a?(::RestClient::Response) span.set_attribute('http.status_code', response.code) - span.status = OpenTelemetry::Trace::Status.error unless (100..399).cover?(response.code.to_i) + span.status = OpenTelemetry::Trace::Status.error unless HTTP_STATUS_SUCCESS_RANGE.cover?(response.code.to_i) end end rescue ::RestClient::ExceptionWithResponse => e span.set_attribute('http.status_code', e.http_code) - span.status = OpenTelemetry::Trace::Status.error unless (100..399).cover?(e.http_code.to_i) - + span.status = OpenTelemetry::Trace::Status.error unless HTTP_STATUS_SUCCESS_RANGE.cover?(e.http_code.to_i) raise e ensure span.finish From 81cbe08cfab65ad0263fb73e5fa734d832814d98 Mon Sep 17 00:00:00 2001 From: Ariel Valentin Date: Sun, 24 Nov 2024 12:23:13 -0600 Subject: [PATCH 56/58] chore: Update release-please-config.json --- release-please-config.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/release-please-config.json b/release-please-config.json index 056677671..35d6c7b5b 100644 --- a/release-please-config.json +++ b/release-please-config.json @@ -1,5 +1,5 @@ { - "bootstrap-sha": "c7686e532a7348b504ad43024735b12d795756cd", + "bootstrap-sha": "ad8988bc4a11bafa0925c3137f2ae32bc57f40a0", "bump-minor-pre-major": true, "bump-patch-for-minor-pre-major": true, "draft": true, From 0e5dd05f6c33c942747c59848c18f5eefd3e031a Mon Sep 17 00:00:00 2001 From: Ariel Valentin Date: Sun, 24 Nov 2024 12:44:48 -0600 Subject: [PATCH 57/58] chore: sync release-please-versions --- .release-please-manifest.json | 87 ++++++++++++++++++----------------- bin/sync-release-please | 36 +++++++++++++++ 2 files changed, 80 insertions(+), 43 deletions(-) create mode 100755 bin/sync-release-please diff --git a/.release-please-manifest.json b/.release-please-manifest.json index b72270bee..f514eef2c 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,53 +1,54 @@ { "helpers/mysql": "0.1.1", - "helpers/sql_obfuscation": "0.1.1", - "instrumentation/base": "0.22.4", - "instrumentation/graphql": "0.28.2", + "helpers/sql-obfuscation": "0.2.0", + "instrumentation/action_mailer": "0.2.0", + "instrumentation/action_pack": "0.10.0", + "instrumentation/action_view": "0.7.3", + "instrumentation/active_job": "0.7.8", + "instrumentation/active_model_serializers": "0.20.2", + "instrumentation/active_record": "0.8.1", + "instrumentation/active_support": "0.6.0", + "instrumentation/all": "0.69.0", + "instrumentation/aws_lambda": "0.1.1", + "instrumentation/aws_sdk": "0.7.0", + "instrumentation/base": "0.22.6", + "instrumentation/bunny": "0.21.4", + "instrumentation/concurrent_ruby": "0.21.4", + "instrumentation/dalli": "0.25.4", + "instrumentation/delayed_job": "0.22.4", + "instrumentation/ethon": "0.21.8", + "instrumentation/excon": "0.22.4", + "instrumentation/faraday": "0.24.6", + "instrumentation/grape": "0.2.0", + "instrumentation/graphql": "0.28.4", "instrumentation/gruf": "0.2.1", - "instrumentation/racecar": "0.3.2", - "instrumentation/rake": "0.2.2", - "instrumentation/rdkafka": "0.4.6", - "instrumentation/trilogy": "0.59.3", - "instrumentation/active_support": "0.5.1", - "instrumentation/action_mailer": "0.1.0", - "instrumentation/action_view": "0.7.0", - "instrumentation/action_pack": "0.9.0", - "instrumentation/active_job": "0.7.1", - "instrumentation/resque": "0.5.2", - "instrumentation/bunny": "0.21.3", - "instrumentation/active_record": "0.7.2", - "instrumentation/aws_sdk": "0.5.2", - "instrumentation/aws_lambda": "0.1.0", - "instrumentation/lmdb": "0.22.2", - "instrumentation/http": "0.23.3", - "instrumentation/http_client": "0.22.6", + "instrumentation/http": "0.23.4", + "instrumentation/http_client": "0.22.7", "instrumentation/httpx": "0.1.2", "instrumentation/koala": "0.20.5", - "instrumentation/active_model_serializers": "0.20.1", - "instrumentation/concurrent_ruby": "0.21.3", - "instrumentation/dalli": "0.25.3", - "instrumentation/delayed_job": "0.22.2", - "instrumentation/ethon": "0.21.7", - "instrumentation/excon": "0.22.3", - "instrumentation/faraday": "0.24.4", - "instrumentation/mongo": "0.22.3", - "instrumentation/mysql2": "0.27.1", - "instrumentation/net_http": "0.22.6", - "instrumentation/pg": "0.27.3", - "instrumentation/que": "0.8.1", - "instrumentation/rack": "0.24.5", - "instrumentation/rails": "0.30.2", - "instrumentation/grape": "0.1.8", - "instrumentation/redis": "0.25.6", - "instrumentation/restclient": "0.22.6", + "instrumentation/lmdb": "0.22.3", + "instrumentation/mongo": "0.22.4", + "instrumentation/mysql2": "0.28.0", + "instrumentation/net_http": "0.22.7", + "instrumentation/pg": "0.29.0", + "instrumentation/que": "0.8.4", + "instrumentation/racecar": "0.3.4", + "instrumentation/rack": "0.25.0", + "instrumentation/rails": "0.33.0", + "instrumentation/rake": "0.2.2", + "instrumentation/rdkafka": "0.4.8", + "instrumentation/redis": "0.25.7", + "instrumentation/resque": "0.5.2", + "instrumentation/restclient": "0.22.7", "instrumentation/rspec": "0.3.3", - "instrumentation/ruby_kafka": "0.21.1", - "instrumentation/sidekiq": "0.25.5", - "instrumentation/sinatra": "0.23.5", - "instrumentation/all": "0.56.0", + "instrumentation/ruby_kafka": "0.21.3", + "instrumentation/sidekiq": "0.25.7", + "instrumentation/sinatra": "0.24.1", + "instrumentation/trilogy": "0.60.0", "processor/baggage": "0.2.0", - "propagator/ottrace": "0.21.2", - "propagator/xray": "0.22.1", + "propagator/ottrace": "0.21.3", + "propagator/vitess": "0.1.0", + "propagator/xray": "0.22.2", "resources/azure": "0.1.0", "resources/container": "0.1.1", "resources/google_cloud_platform": "0.1.0" diff --git a/bin/sync-release-please b/bin/sync-release-please new file mode 100755 index 000000000..8e669df50 --- /dev/null +++ b/bin/sync-release-please @@ -0,0 +1,36 @@ +#!/usr/bin/env ruby + +require 'json' + +# Function to extract VERSION constant from a file +def extract_version(file_path) + version = nil + File.open(file_path, 'r') do |file| + file.each_line do |line| + if line =~ /VERSION\s*=\s*['"]([^'"]+)['"]/ + version = $1 + break + end + end + end + version +end + +# Hash to store the directory names and their versions +versions = {} + +# Find all version.rb files +Dir.glob('**/version.rb').each do |file_path| + # Extract the top 2 level directories + top_dirs = file_path.split('/')[0..1].join('/') + # Extract the version + version = extract_version(file_path) + # Store in the hash + versions[top_dirs] = version if version +end + +# Write the hash to a JSON file +File.open('.release-please-manifest.json', 'w') do |file| + file.write(JSON.pretty_generate(versions)) + file.write("\n") +end From aae89d7ec7c60e7cd222243a8d3885c774f12650 Mon Sep 17 00:00:00 2001 From: Ariel Valentin Date: Mon, 25 Nov 2024 20:27:00 -0600 Subject: [PATCH 58/58] chore: Add EoL Post Install Messages (#1264) --- POST_INSTALL_MESSAGE | 3 +++ helpers/mysql/opentelemetry-helpers-mysql.gemspec | 2 ++ .../opentelemetry-helpers-sql-obfuscation.gemspec | 2 ++ instrumentation/all/opentelemetry-instrumentation-all.gemspec | 2 ++ .../rails/opentelemetry-instrumentation-rails.gemspec | 2 ++ processor/baggage/opentelemetry-processor-baggage.gemspec | 2 ++ propagator/ottrace/opentelemetry-propagator-ottrace.gemspec | 2 ++ propagator/vitess/opentelemetry-propagator-vitess.gemspec | 2 ++ propagator/xray/opentelemetry-propagator-xray.gemspec | 2 ++ resources/azure/opentelemetry-resource-detector-azure.gemspec | 2 ++ .../opentelemetry-resource-detector-container.gemspec | 2 ++ ...entelemetry-resource-detector-google_cloud_platform.gemspec | 2 ++ 12 files changed, 25 insertions(+) create mode 100644 POST_INSTALL_MESSAGE diff --git a/POST_INSTALL_MESSAGE b/POST_INSTALL_MESSAGE new file mode 100644 index 000000000..96c3ecaa5 --- /dev/null +++ b/POST_INSTALL_MESSAGE @@ -0,0 +1,3 @@ +Ruby 3.0 has reached EoL 2024-04-23. OTel Ruby Contrib gems will no longer accept new features or bug fixes for Ruby 3.0 after 2025-01-15. Please upgrade to Ruby 3.1 or higher to continue receiving updates. + +Rails 6.1 has reached EoL 2024-10-01. OTel Ruby Contrib gems will no longer accept new features or bug fixes for Rails 6.1 after 2025-01-15. Please upgrade to Rails 7.0 or higher to continue receiving updates. diff --git a/helpers/mysql/opentelemetry-helpers-mysql.gemspec b/helpers/mysql/opentelemetry-helpers-mysql.gemspec index ff93af073..f18fff675 100644 --- a/helpers/mysql/opentelemetry-helpers-mysql.gemspec +++ b/helpers/mysql/opentelemetry-helpers-mysql.gemspec @@ -44,4 +44,6 @@ Gem::Specification.new do |spec| spec.metadata['bug_tracker_uri'] = 'https://github.com/open-telemetry/opentelemetry-ruby-contrib/issues' spec.metadata['documentation_uri'] = "https://rubydoc.info/gems/#{spec.name}/#{spec.version}" end + + spec.post_install_message = File.read(File.expand_path('../../POST_INSTALL_MESSAGE', __dir__)) end diff --git a/helpers/sql-obfuscation/opentelemetry-helpers-sql-obfuscation.gemspec b/helpers/sql-obfuscation/opentelemetry-helpers-sql-obfuscation.gemspec index 89ea0b8b1..eefb5dae9 100644 --- a/helpers/sql-obfuscation/opentelemetry-helpers-sql-obfuscation.gemspec +++ b/helpers/sql-obfuscation/opentelemetry-helpers-sql-obfuscation.gemspec @@ -42,4 +42,6 @@ Gem::Specification.new do |spec| spec.metadata['bug_tracker_uri'] = 'https://github.com/open-telemetry/opentelemetry-ruby-contrib/issues' spec.metadata['documentation_uri'] = "https://rubydoc.info/gems/#{spec.name}/#{spec.version}" end + + spec.post_install_message = File.read(File.expand_path('../../POST_INSTALL_MESSAGE', __dir__)) end diff --git a/instrumentation/all/opentelemetry-instrumentation-all.gemspec b/instrumentation/all/opentelemetry-instrumentation-all.gemspec index c9603b518..6b592127f 100644 --- a/instrumentation/all/opentelemetry-instrumentation-all.gemspec +++ b/instrumentation/all/opentelemetry-instrumentation-all.gemspec @@ -77,4 +77,6 @@ Gem::Specification.new do |spec| spec.metadata['bug_tracker_uri'] = 'https://github.com/open-telemetry/opentelemetry-ruby-contrib/issues' spec.metadata['documentation_uri'] = "https://rubydoc.info/gems/#{spec.name}/#{spec.version}" end + + spec.post_install_message = File.read(File.expand_path('../../POST_INSTALL_MESSAGE', __dir__)) end diff --git a/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec b/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec index 0328a44ae..c9243add0 100644 --- a/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec +++ b/instrumentation/rails/opentelemetry-instrumentation-rails.gemspec @@ -48,4 +48,6 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'yard', '~> 0.9' spec.metadata['source_code_uri'] = 'https://github.com/open-telemetry/opentelemetry-ruby-contrib/tree/main/instrumentation/rails' if spec.respond_to?(:metadata) + + spec.post_install_message = File.read(File.expand_path('../../POST_INSTALL_MESSAGE', __dir__)) end diff --git a/processor/baggage/opentelemetry-processor-baggage.gemspec b/processor/baggage/opentelemetry-processor-baggage.gemspec index 8d429b12e..f625e91b1 100644 --- a/processor/baggage/opentelemetry-processor-baggage.gemspec +++ b/processor/baggage/opentelemetry-processor-baggage.gemspec @@ -41,4 +41,6 @@ Gem::Specification.new do |spec| spec.metadata['bug_tracker_uri'] = 'https://github.com/open-telemetry/opentelemetry-ruby-contrib/issues' spec.metadata['documentation_uri'] = "https://rubydoc.info/gems/#{spec.name}/#{spec.version}" end + + spec.post_install_message = File.read(File.expand_path('../../POST_INSTALL_MESSAGE', __dir__)) end diff --git a/propagator/ottrace/opentelemetry-propagator-ottrace.gemspec b/propagator/ottrace/opentelemetry-propagator-ottrace.gemspec index 9e4aa0bcc..9417ed10b 100644 --- a/propagator/ottrace/opentelemetry-propagator-ottrace.gemspec +++ b/propagator/ottrace/opentelemetry-propagator-ottrace.gemspec @@ -39,4 +39,6 @@ Gem::Specification.new do |spec| spec.metadata['bug_tracker_uri'] = 'https://github.com/open-telemetry/opentelemetry-ruby-contrib/issues' spec.metadata['documentation_uri'] = "https://rubydoc.info/gems/#{spec.name}/#{spec.version}" end + + spec.post_install_message = File.read(File.expand_path('../../POST_INSTALL_MESSAGE', __dir__)) end diff --git a/propagator/vitess/opentelemetry-propagator-vitess.gemspec b/propagator/vitess/opentelemetry-propagator-vitess.gemspec index 474f06f7c..c2300ebbf 100644 --- a/propagator/vitess/opentelemetry-propagator-vitess.gemspec +++ b/propagator/vitess/opentelemetry-propagator-vitess.gemspec @@ -40,4 +40,6 @@ Gem::Specification.new do |spec| spec.metadata['bug_tracker_uri'] = 'https://github.com/open-telemetry/opentelemetry-ruby-contrib/issues' spec.metadata['documentation_uri'] = "https://rubydoc.info/gems/#{spec.name}/#{spec.version}" end + + spec.post_install_message = File.read(File.expand_path('../../POST_INSTALL_MESSAGE', __dir__)) end diff --git a/propagator/xray/opentelemetry-propagator-xray.gemspec b/propagator/xray/opentelemetry-propagator-xray.gemspec index 8efcfc243..8305dac7a 100644 --- a/propagator/xray/opentelemetry-propagator-xray.gemspec +++ b/propagator/xray/opentelemetry-propagator-xray.gemspec @@ -42,4 +42,6 @@ Gem::Specification.new do |spec| spec.metadata['bug_tracker_uri'] = 'https://github.com/open-telemetry/opentelemetry-ruby-contrib/issues' spec.metadata['documentation_uri'] = "https://rubydoc.info/gems/#{spec.name}/#{spec.version}" end + + spec.post_install_message = File.read(File.expand_path('../../POST_INSTALL_MESSAGE', __dir__)) end diff --git a/resources/azure/opentelemetry-resource-detector-azure.gemspec b/resources/azure/opentelemetry-resource-detector-azure.gemspec index aaa321054..005742c27 100644 --- a/resources/azure/opentelemetry-resource-detector-azure.gemspec +++ b/resources/azure/opentelemetry-resource-detector-azure.gemspec @@ -42,4 +42,6 @@ Gem::Specification.new do |spec| spec.metadata['bug_tracker_uri'] = 'https://github.com/open-telemetry/opentelemetry-ruby-contrib/issues' spec.metadata['documentation_uri'] = "https://rubydoc.info/gems/#{spec.name}/#{spec.version}" end + + spec.post_install_message = File.read(File.expand_path('../../POST_INSTALL_MESSAGE', __dir__)) end diff --git a/resources/container/opentelemetry-resource-detector-container.gemspec b/resources/container/opentelemetry-resource-detector-container.gemspec index 1589db320..83b5438bf 100644 --- a/resources/container/opentelemetry-resource-detector-container.gemspec +++ b/resources/container/opentelemetry-resource-detector-container.gemspec @@ -41,4 +41,6 @@ Gem::Specification.new do |spec| spec.metadata['bug_tracker_uri'] = 'https://github.com/open-telemetry/opentelemetry-ruby-contrib/issues' spec.metadata['documentation_uri'] = "https://rubydoc.info/gems/#{spec.name}/#{spec.version}" end + + spec.post_install_message = File.read(File.expand_path('../../POST_INSTALL_MESSAGE', __dir__)) end diff --git a/resources/google_cloud_platform/opentelemetry-resource-detector-google_cloud_platform.gemspec b/resources/google_cloud_platform/opentelemetry-resource-detector-google_cloud_platform.gemspec index 564b9d620..acedf0e06 100644 --- a/resources/google_cloud_platform/opentelemetry-resource-detector-google_cloud_platform.gemspec +++ b/resources/google_cloud_platform/opentelemetry-resource-detector-google_cloud_platform.gemspec @@ -43,4 +43,6 @@ Gem::Specification.new do |spec| spec.metadata['bug_tracker_uri'] = 'https://github.com/open-telemetry/opentelemetry-ruby-contrib/issues' spec.metadata['documentation_uri'] = "https://rubydoc.info/gems/#{spec.name}/#{spec.version}" end + + spec.post_install_message = File.read(File.expand_path('../../POST_INSTALL_MESSAGE', __dir__)) end