Skip to content

Commit

Permalink
Merge branch 'main' into logger-instrumentation
Browse files Browse the repository at this point in the history
  • Loading branch information
kaylareopelle authored Nov 25, 2024
2 parents ea3351e + 0e5dd05 commit 0f3df26
Show file tree
Hide file tree
Showing 163 changed files with 2,144 additions and 971 deletions.
5 changes: 3 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.191.0
uses: ruby/setup-ruby@v1.202.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.191.0
uses: ruby/setup-ruby@v1.202.0
with:
ruby-version: "${{ inputs.ruby }}"
bundler: "latest"
Expand All @@ -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 }}"

Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/ci-contrib.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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:
Expand Down Expand Up @@ -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:
Expand Down Expand Up @@ -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:
Expand Down Expand Up @@ -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"
2 changes: 1 addition & 1 deletion .github/workflows/ci-instrumentation-with-services.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ci-instrumentation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -111,4 +111,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"
2 changes: 1 addition & 1 deletion .github/workflows/ci-markdownlint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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: |
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/installation-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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.202.0
with:
ruby-version: ${{ matrix.ruby-version }}
- name: "Install Latest Gem Versions on ${{ matrix.ruby-version }}"
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-hook-on-closed.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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.202.0
with:
ruby-version: ${{ env.ruby_version }}
- name: Checkout repo
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-hook-on-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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.202.0
with:
ruby-version: ${{ env.ruby_version }}
- name: Checkout repo
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-perform.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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.202.0
with:
ruby-version: ${{ env.ruby_version }}
- name: Checkout repo
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-please.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -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.202.0
with:
ruby-version: "3.0"
bundler: latest
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-request-weekly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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.202.0
with:
ruby-version: ${{ env.ruby_version }}
- name: Checkout repo
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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.202.0
with:
ruby-version: ${{ env.ruby_version }}
- name: Checkout repo
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-retry.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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.202.0
with:
ruby-version: ${{ env.ruby_version }}
- name: Checkout repo
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@

# Appraisals
instrumentation/**/gemfiles
instrumentation/**/tmp/**/*

# Sqlite file for tests
instrumentation/active_record/db
Expand All @@ -26,3 +27,4 @@ instrumentation/active_record/db
.ruby-version

tags
!**/*/.gitkeep
2 changes: 1 addition & 1 deletion .instrumentation_generator/templates/gemspec.tt
Original file line number Diff line number Diff line change
Expand Up @@ -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)
Expand Down
87 changes: 44 additions & 43 deletions .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -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"
Expand Down
2 changes: 1 addition & 1 deletion CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
Expand Up @@ -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

Expand Down
6 changes: 6 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
4 changes: 2 additions & 2 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,5 @@
source 'https://rubygems.org'

gem 'rake', '~> 13.0'
gem 'rubocop', '~> 1.66.0'
gem 'rubocop-performance', '~> 1.21.0'
gem 'rubocop', '~> 1.68.0'
gem 'rubocop-performance', '~> 1.23.0'
36 changes: 36 additions & 0 deletions bin/sync-release-please
Original file line number Diff line number Diff line change
@@ -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
8 changes: 3 additions & 5 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
version: "3.5"

x-shared-config:
base: &base
command: /bin/bash
Expand Down Expand Up @@ -217,7 +215,7 @@ services:
image: memcached:alpine
command: memcached -m 64
ports:
- "11211:11211"
- "11211:11211"

zookeeper:
image: confluentinc/cp-zookeeper:latest
Expand Down Expand Up @@ -248,8 +246,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:
Expand Down
4 changes: 2 additions & 2 deletions helpers/mysql/opentelemetry-helpers-mysql.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ 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-performance', '~> 1.21.0'
spec.add_development_dependency 'rubocop', '~> 1.68.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'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@ 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-performance', '~> 1.21.0'
spec.add_development_dependency 'rubocop', '~> 1.68.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'

Expand Down
Loading

0 comments on commit 0f3df26

Please sign in to comment.