Skip to content

Commit

Permalink
Merge branch 'main' into que
Browse files Browse the repository at this point in the history
  • Loading branch information
kaylareopelle authored Jan 24, 2025
2 parents abbad6d + f12b0d7 commit c08fdd1
Show file tree
Hide file tree
Showing 252 changed files with 1,071 additions and 879 deletions.
4 changes: 2 additions & 2 deletions .github/actions/test_gem/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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.207.0
uses: ruby/setup-ruby@v1.213.0
with:
ruby-version: "${{ inputs.ruby }}"
working-directory: "${{ steps.setup.outputs.gem_dir }}"
Expand All @@ -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.207.0
uses: ruby/setup-ruby@v1.213.0
with:
ruby-version: "${{ inputs.ruby }}"
bundler: "latest"
Expand Down
24 changes: 0 additions & 24 deletions .github/workflows/ci-contrib.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,12 +44,6 @@ jobs:
with:
gem: "opentelemetry-helpers-${{ matrix.gem }}"
ruby: "3.1"
- name: "Test Ruby 3.0"
if: "${{ matrix.os == 'ubuntu-latest' }}"
uses: ./.github/actions/test_gem
with:
gem: "opentelemetry-helpers-${{ matrix.gem }}"
ruby: "3.0"
yard: true
rubocop: true
build: true
Expand Down Expand Up @@ -89,12 +83,6 @@ jobs:
with:
gem: "opentelemetry-propagator-${{ matrix.gem }}"
ruby: "3.1"
- name: "Test Ruby 3.0"
if: "${{ matrix.os == 'ubuntu-latest' }}"
uses: ./.github/actions/test_gem
with:
gem: "opentelemetry-propagator-${{ matrix.gem }}"
ruby: "3.0"
yard: true
rubocop: true
build: true
Expand Down Expand Up @@ -134,15 +122,9 @@ jobs:
with:
gem: "opentelemetry-${{ matrix.gem }}"
ruby: "3.1"
- name: "Test Ruby 3.0"
if: "${{ matrix.os == 'ubuntu-latest' }}"
uses: ./.github/actions/test_gem
with:
gem: "opentelemetry-${{ matrix.gem }}"
yard: true
rubocop: true
build: true
ruby: "3.0"
- name: "Test JRuby"
if: "${{ matrix.os == 'ubuntu-latest' }}"
uses: ./.github/actions/test_gem
Expand Down Expand Up @@ -177,12 +159,6 @@ jobs:
with:
gem: "opentelemetry-processor-${{ matrix.gem }}"
ruby: "3.1"
- name: "Test Ruby 3.0"
if: "${{ matrix.os == 'ubuntu-latest' }}"
uses: ./.github/actions/test_gem
with:
gem: "opentelemetry-processor-${{ matrix.gem }}"
ruby: "3.0"
yard: true
rubocop: true
build: true
Expand Down
30 changes: 0 additions & 30 deletions .github/workflows/ci-instrumentation-with-services.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,11 +44,6 @@ jobs:
with:
gem: "opentelemetry-instrumentation-${{ matrix.gem }}"
ruby: "3.1"
- name: "Test Ruby 3.0"
uses: ./.github/actions/test_gem
with:
gem: "opentelemetry-instrumentation-${{ matrix.gem }}"
ruby: "3.0"
yard: true
rubocop: true
build: true
Expand Down Expand Up @@ -95,11 +90,6 @@ jobs:
with:
gem: "opentelemetry-instrumentation-${{ matrix.gem }}"
ruby: "3.1"
- name: "Test Ruby 3.0"
uses: ./.github/actions/test_gem
with:
gem: "opentelemetry-instrumentation-${{ matrix.gem }}"
ruby: "3.0"
yard: true
rubocop: true
build: true
Expand Down Expand Up @@ -137,11 +127,6 @@ jobs:
with:
gem: "opentelemetry-instrumentation-${{ matrix.gem }}"
ruby: "3.1"
- name: "Test Ruby 3.0"
uses: ./.github/actions/test_gem
with:
gem: "opentelemetry-instrumentation-${{ matrix.gem }}"
ruby: "3.0"
yard: true
rubocop: true
build: true
Expand Down Expand Up @@ -195,11 +180,6 @@ jobs:
with:
gem: "opentelemetry-instrumentation-${{ matrix.gem }}"
ruby: "3.1"
- name: "Test Ruby 3.0"
uses: ./.github/actions/test_gem
with:
gem: "opentelemetry-instrumentation-${{ matrix.gem }}"
ruby: "3.0"
yard: true
rubocop: true
build: true
Expand Down Expand Up @@ -244,11 +224,6 @@ jobs:
with:
gem: "opentelemetry-instrumentation-${{ matrix.gem }}"
ruby: "3.1"
- name: "Test Ruby 3.0"
uses: ./.github/actions/test_gem
with:
gem: "opentelemetry-instrumentation-${{ matrix.gem }}"
ruby: "3.0"
yard: true
rubocop: true
build: true
Expand Down Expand Up @@ -290,11 +265,6 @@ jobs:
with:
gem: "opentelemetry-instrumentation-${{ matrix.gem }}"
ruby: "3.1"
- name: "Test Ruby 3.0"
uses: ./.github/actions/test_gem
with:
gem: "opentelemetry-instrumentation-${{ matrix.gem }}"
ruby: "3.0"
yard: true
rubocop: true
build: true
Expand Down
8 changes: 2 additions & 6 deletions .github/workflows/ci-instrumentation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ jobs:
- faraday
- grape
- graphql
- grpc
- gruf
- http
- http_client
Expand Down Expand Up @@ -73,12 +74,6 @@ jobs:
with:
gem: "opentelemetry-instrumentation-${{ matrix.gem }}"
ruby: "3.1"
- name: "Test Ruby 3.0"
if: "${{ matrix.os == 'ubuntu-latest' }}"
uses: ./.github/actions/test_gem
with:
gem: "opentelemetry-instrumentation-${{ matrix.gem }}"
ruby: "3.0"
yard: true
rubocop: true
build: true
Expand All @@ -102,6 +97,7 @@ jobs:
[[ "${{ matrix.gem }}" == "lmdb" ]] && echo "skip=true" >> $GITHUB_OUTPUT
[[ "${{ matrix.gem }}" == "rack" ]] && echo "skip=true" >> $GITHUB_OUTPUT
[[ "${{ matrix.gem }}" == "rails" ]] && echo "skip=true" >> $GITHUB_OUTPUT
[[ "${{ matrix.gem }}" == "grpc" ]] && echo "skip=true" >> $GITHUB_OUTPUT
[[ "${{ matrix.gem }}" == "gruf" ]] && echo "skip=true" >> $GITHUB_OUTPUT
# This is essentially a bash script getting evaluated, so we need to return true or the whole job fails.
true
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/installation-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,17 +15,17 @@ jobs:
fail-fast: false
matrix:
ruby-version:
- 3.4
- 3.3
- 3.2
- 3.1
- 3.0
name: ${{ matrix.ruby-version }}
runs-on: ubuntu-latest
steps:
- 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.207.0
- uses: ruby/setup-ruby@v1.213.0
with:
ruby-version: ${{ matrix.ruby-version }}
- name: "Install Latest Gem Versions on ${{ matrix.ruby-version }}"
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/release-hook-on-closed.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ jobs:
release-process-request:
if: ${{ github.repository == 'open-telemetry/opentelemetry-ruby-contrib' }}
env:
ruby_version: "3.0"
ruby_version: "3.1"
runs-on: ubuntu-latest
steps:
- name: Install Ruby ${{ env.ruby_version }}
uses: ruby/setup-ruby@v1.207.0
uses: ruby/setup-ruby@v1.213.0
with:
ruby-version: ${{ env.ruby_version }}
- name: Checkout repo
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/release-hook-on-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,11 @@ jobs:
release-update-open-requests:
if: ${{ github.repository == 'open-telemetry/opentelemetry-ruby-contrib' }}
env:
ruby_version: "3.0"
ruby_version: "3.1"
runs-on: ubuntu-latest
steps:
- name: Install Ruby ${{ env.ruby_version }}
uses: ruby/setup-ruby@v1.207.0
uses: ruby/setup-ruby@v1.213.0
with:
ruby-version: ${{ env.ruby_version }}
- name: Checkout repo
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/release-perform.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,11 @@ jobs:
release-perform:
if: ${{ github.repository == 'open-telemetry/opentelemetry-ruby-contrib' }}
env:
ruby_version: "3.0"
ruby_version: "3.1"
runs-on: ubuntu-latest
steps:
- name: Install Ruby ${{ env.ruby_version }}
uses: ruby/setup-ruby@v1.207.0
uses: ruby/setup-ruby@v1.213.0
with:
ruby-version: ${{ env.ruby_version }}
- name: Checkout repo
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/release-please.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,9 @@ jobs:
chmod 0600 $HOME/.gem/credentials
printf -- "---\n:rubygems_api_key: ${GEM_HOST_API_KEY}\n" > $HOME/.gem/credentials
- uses: ruby/setup-ruby@v1.207.0
- uses: ruby/setup-ruby@v1.213.0
with:
ruby-version: "3.0"
ruby-version: "3.1"
bundler: latest
bundler-cache: false
working-directory: ${{ matrix.path }}
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/release-request-weekly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ jobs:
release-request:
if: ${{ github.repository == 'open-telemetry/opentelemetry-ruby-contrib' }}
env:
ruby_version: "3.0"
ruby_version: "3.1"
runs-on: ubuntu-latest
steps:
- name: Install Ruby ${{ env.ruby_version }}
uses: ruby/setup-ruby@v1.207.0
uses: ruby/setup-ruby@v1.213.0
with:
ruby-version: ${{ env.ruby_version }}
- name: Checkout repo
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/release-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,11 @@ jobs:
release-request:
if: ${{ github.repository == 'open-telemetry/opentelemetry-ruby-contrib' }}
env:
ruby_version: "3.0"
ruby_version: "3.1"
runs-on: ubuntu-latest
steps:
- name: Install Ruby ${{ env.ruby_version }}
uses: ruby/setup-ruby@v1.207.0
uses: ruby/setup-ruby@v1.213.0
with:
ruby-version: ${{ env.ruby_version }}
- name: Checkout repo
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/release-retry.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@ jobs:
release-retry:
if: ${{ github.repository == 'open-telemetry/opentelemetry-ruby-contrib' }}
env:
ruby_version: "3.0"
ruby_version: "3.1"
runs-on: ubuntu-latest
steps:
- name: Install Ruby ${{ env.ruby_version }}
uses: ruby/setup-ruby@v1.207.0
uses: ruby/setup-ruby@v1.213.0
with:
ruby-version: ${{ env.ruby_version }}
- name: Checkout repo
Expand Down
2 changes: 1 addition & 1 deletion .instrumentation_generator/instrumentation_generator.rb
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ def add_to_instrumentation_all
insert_into_file("#{instrumentation_all_path}/Gemfile", gemfile_text, after: "gemspec\n")

gemspec_text = "\n spec.add_dependency '#{instrumentation_gem_name}', '~> 0.0.0'"
insert_into_file("#{instrumentation_all_path}/opentelemetry-instrumentation-all.gemspec", gemspec_text, after: "spec.required_ruby_version = '>= 3.0'\n")
insert_into_file("#{instrumentation_all_path}/opentelemetry-instrumentation-all.gemspec", gemspec_text, after: "spec.required_ruby_version = '>= 3.1'\n")

all_rb_text = "\nrequire '#{instrumentation_gem_name}'"
insert_into_file("#{instrumentation_all_path}/lib/opentelemetry/instrumentation/all.rb", all_rb_text, after: "# SPDX-License-Identifier: Apache-2.0\n")
Expand Down
1 change: 0 additions & 1 deletion .instrumentation_generator/templates/Appraisals
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,3 @@
# appraise 'rack-2.0' do
# gem 'rack', '2.0.8'
# end

4 changes: 2 additions & 2 deletions .instrumentation_generator/templates/gemspec.tt
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ Gem::Specification.new do |spec|
Dir.glob('*.md') +
['LICENSE', '.yardopts']
spec.require_paths = ['lib']
spec.required_ruby_version = '>= 3.0'
spec.required_ruby_version = '>= 3.1'

spec.add_dependency 'opentelemetry-api', '~> <%= opentelemetry_version %>'
spec.add_dependency 'opentelemetry-instrumentation-base', '~> <%= instrumentation_base_version %>'
Expand All @@ -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.69.1'
spec.add_development_dependency 'rubocop', '~> 1.70.0'
spec.add_development_dependency 'rubocop-performance', '~> 1.19.1'
spec.add_development_dependency 'simplecov', '~> 0.17.1'
spec.add_development_dependency 'webmock', '~> 3.24.0'
Expand Down
2 changes: 1 addition & 1 deletion .instrumentation_generator/templates/lib/entrypoint.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@
#
# SPDX-License-Identifier: Apache-2.0

require_relative './opentelemetry/instrumentation'
require_relative 'opentelemetry/instrumentation'
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,4 @@ module OpenTelemetry
end
end

require_relative './instrumentation/<%= instrumentation_name %>'
require_relative 'instrumentation/<%= instrumentation_name %>'
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,5 @@ module OpenTelemetry
end
end

require_relative './<%= instrumentation_name %>/instrumentation'
require_relative './<%= instrumentation_name %>/version'
require_relative '<%= instrumentation_name %>/instrumentation'
require_relative '<%= instrumentation_name %>/version'
Loading

0 comments on commit c08fdd1

Please sign in to comment.