Skip to content

Commit

Permalink
Merge branch 'main' into as-span-kind
Browse files Browse the repository at this point in the history
  • Loading branch information
xuan-cao-swi authored Jun 18, 2024
2 parents 4ce72b4 + c7686e5 commit dcf1854
Show file tree
Hide file tree
Showing 69 changed files with 322 additions and 115 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.178.0
uses: ruby/setup-ruby@v1.180.1
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.176.0
uses: ruby/setup-ruby@v1.180.1
with:
ruby-version: "${{ inputs.ruby }}"
bundler: "latest"
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/conventional-commits.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
name: Conventional Commits Validation
runs-on: ubuntu-latest
steps:
- uses: dev-build-deploy/commit-me@v1.4.1
- uses: dev-build-deploy/commit-me@v1.5.0
env:
FORCE_COLOR: 3
with:
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.178.0
- uses: ruby/setup-ruby@v1.180.1
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.178.0
uses: ruby/setup-ruby@v1.180.1
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.178.0
uses: ruby/setup-ruby@v1.180.1
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.178.0
uses: ruby/setup-ruby@v1.180.1
with:
ruby-version: ${{ env.ruby_version }}
- name: Checkout repo
Expand Down
6 changes: 4 additions & 2 deletions .github/workflows/release-please.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,10 @@ jobs:
name: Process Release
runs-on: ubuntu-latest
steps:
- uses: googleapis/[email protected].1
- uses: googleapis/[email protected].3
id: prepare
with:
token: ${{ secrets.OPENTELEMETRYBOT_GITHUB_TOKEN }}

outputs:
paths_released: ${{ steps.prepare.outputs.paths_released }}
Expand Down Expand Up @@ -48,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.178.0
- uses: ruby/setup-ruby@v1.180.1
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.178.0
uses: ruby/setup-ruby@v1.180.1
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.178.0
uses: ruby/setup-ruby@v1.180.1
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.178.0
uses: ruby/setup-ruby@v1.180.1
with:
ruby-version: ${{ env.ruby_version }}
- name: Checkout repo
Expand Down
74 changes: 37 additions & 37 deletions .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -1,49 +1,49 @@
{
"helpers/mysql": "0.0.0",
"helpers/sql_obfuscation": "0.0.0",
"instrumentation/gruf": "0.1.1",
"instrumentation/grape": "0.1.6",
"instrumentation/racecar": "0.3.0",
"instrumentation/rake": "0.2.1",
"instrumentation/rdkafka": "0.4.2",
"instrumentation/trilogy": "0.58.0",
"helpers/mysql": "0.1.0",
"helpers/sql_obfuscation": "0.1.0",
"instrumentation/graphql": "0.28.2",
"instrumentation/gruf": "0.2.1",
"instrumentation/racecar": "0.3.2",
"instrumentation/rake": "0.2.2",
"instrumentation/rdkafka": "0.4.5",
"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.0",
"instrumentation/bunny": "0.21.1",
"instrumentation/resque": "0.5.2",
"instrumentation/bunny": "0.21.3",
"instrumentation/base": "0.22.3",
"instrumentation/active_record": "0.7.0",
"instrumentation/aws_sdk": "0.5.0",
"instrumentation/active_record": "0.7.2",
"instrumentation/aws_sdk": "0.5.2",
"instrumentation/aws_lambda": "0.1.0",
"instrumentation/lmdb": "0.22.1",
"instrumentation/http": "0.23.2",
"instrumentation/graphql": "0.27.0",
"instrumentation/http_client": "0.22.3",
"instrumentation/httpx": "0.1.1",
"instrumentation/koala": "0.20.2",
"instrumentation/lmdb": "0.22.2",
"instrumentation/http": "0.23.3",
"instrumentation/http_client": "0.22.5",
"instrumentation/httpx": "0.1.2",
"instrumentation/koala": "0.20.4",
"instrumentation/active_model_serializers": "0.20.1",
"instrumentation/concurrent_ruby": "0.21.2",
"instrumentation/dalli": "0.25.0",
"instrumentation/delayed_job": "0.22.1",
"instrumentation/ethon": "0.21.3",
"instrumentation/excon": "0.22.0",
"instrumentation/faraday": "0.23.4",
"instrumentation/mongo": "0.22.2",
"instrumentation/mysql2": "0.25.0",
"instrumentation/net_http": "0.22.4",
"instrumentation/pg": "0.26.1",
"instrumentation/que": "0.7.1",
"instrumentation/rack": "0.24.0",
"instrumentation/rails": "0.30.0",
"instrumentation/redis": "0.25.3",
"instrumentation/restclient": "0.22.3",
"instrumentation/rspec": "0.3.2",
"instrumentation/ruby_kafka": "0.21.0",
"instrumentation/sidekiq": "0.25.0",
"instrumentation/sinatra": "0.23.2",
"instrumentation/concurrent_ruby": "0.21.3",
"instrumentation/dalli": "0.25.2",
"instrumentation/delayed_job": "0.22.2",
"instrumentation/ethon": "0.21.6",
"instrumentation/excon": "0.22.2",
"instrumentation/faraday": "0.24.3",
"instrumentation/mongo": "0.22.3",
"instrumentation/mysql2": "0.27.1",
"instrumentation/net_http": "0.22.5",
"instrumentation/pg": "0.27.3",
"instrumentation/que": "0.8.1",
"instrumentation/rack": "0.24.4",
"instrumentation/rails": "0.30.2",
"instrumentation/grape": "0.1.8",
"instrumentation/redis": "0.25.5",
"instrumentation/restclient": "0.22.5",
"instrumentation/rspec": "0.3.3",
"instrumentation/ruby_kafka": "0.21.1",
"instrumentation/sidekiq": "0.25.4",
"instrumentation/sinatra": "0.23.4",
"instrumentation/all": "0.56.0",
"processor/baggage": "0.1.0",
"propagator/ottrace": "0.21.2",
Expand Down
6 changes: 6 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -162,6 +162,12 @@ services:
command: ./start_server.sh
working_dir: /app/instrumentation/sinatra/example

processor-baggage-test:
<<: *base
working_dir: /app/processor/baggage
command: |
bash -c "bundle install && rake"
mongo:
image: mongo:4.4
expose:
Expand Down
4 changes: 4 additions & 0 deletions helpers/mysql/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Release History: opentelemetry-helpers-mysql

### v0.1.1 / 2024-06-18

* FIXED: Relax otel common gem constraints

### v0.1.0 / 2024-02-08

Initial release.
2 changes: 1 addition & 1 deletion helpers/mysql/lib/opentelemetry/helpers/mysql/version.rb
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
module OpenTelemetry
module Helpers
module MySQL
VERSION = '0.1.0'
VERSION = '0.1.1'
end
end
end
2 changes: 1 addition & 1 deletion helpers/mysql/opentelemetry-helpers-mysql.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -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-common', '~> 0.20'
spec.add_dependency 'opentelemetry-common', '~> 0.21'

spec.add_development_dependency 'bundler', '~> 2.4'
spec.add_development_dependency 'minitest', '~> 5.0'
Expand Down
4 changes: 4 additions & 0 deletions helpers/sql-obfuscation/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Release History: opentelemetry-helpers-sql-obfuscation

### v0.1.1 / 2024-06-18

* FIXED: Relax otel common gem constraints

### v0.1.0 / 2024-02-08

Initial release.
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
module OpenTelemetry
module Helpers
module SqlObfuscation
VERSION = '0.1.0'
VERSION = '0.1.1'
end
end
end
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ Gem::Specification.new do |spec|
spec.require_paths = ['lib']
spec.required_ruby_version = '>= 3.0'

spec.add_dependency 'opentelemetry-common', '~> 0.20'
spec.add_dependency 'opentelemetry-common', '~> 0.21'

spec.add_development_dependency 'bundler', '~> 2.4'
spec.add_development_dependency 'minitest', '~> 5.0'
Expand Down
5 changes: 5 additions & 0 deletions instrumentation/base/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Release History: opentelemetry-instrumentation-base

### v0.22.4 / 2024-06-18

* FIXED: Relax otel common gem constraints
* DOCS: Add function doc for config_overrides_from_env

### v0.22.3 / 2023-11-23

* CHANGED: Applied Rubocop Performance Recommendations [#727](https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/727)
Expand Down
12 changes: 12 additions & 0 deletions instrumentation/base/lib/opentelemetry/instrumentation/base.rb
Original file line number Diff line number Diff line change
Expand Up @@ -326,6 +326,18 @@ def enabled_by_env_var?
ENV[var_name] != 'false'
end

# Checks to see if the user has passed any environment variables that set options
# for instrumentation. By convention, the environment variable will be the name
# of the instrumentation, uppercased, with '::' replaced by underscores,
# OPENTELEMETRY shortened to OTEL_{LANG}, and _CONFIG_OPTS appended.
# For example, the environment variable name for OpenTelemetry::Instrumentation::Faraday
# will be OTEL_RUBY_INSTRUMENTATION_FARADAY_CONFIG_OPTS. A value of 'peer_service=new_service;'
# will override the options set from ::OpenTelemetry::SDK.configure do |c| ... end for Faraday.
#
# For an array option, simply separate the values with commas (e.g., option=a,b,c,d).
# For a boolean option, set the value to true or false (e.g., option=true).
# For integer, string, enum, set the value as a string (e.g., option=string).
# Callable options are not allowed to be set through environment variables.
def config_overrides_from_env
var_name = name.dup.tap do |n|
n.upcase!
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@

module OpenTelemetry
module Instrumentation
VERSION = '0.22.3'
VERSION = '0.22.4'
end
end
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ Gem::Specification.new do |spec|
spec.required_ruby_version = '>= 3.0'

spec.add_dependency 'opentelemetry-api', '~> 1.0'
spec.add_dependency 'opentelemetry-common', '~> 0.21'
spec.add_dependency 'opentelemetry-registry', '~> 0.1'

spec.add_development_dependency 'bundler', '~> 2.4'
Expand Down
4 changes: 4 additions & 0 deletions instrumentation/dalli/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Release History: opentelemetry-instrumentation-dalli

### v0.25.3 / 2024-06-18

* FIXED: Relax otel common gem constraints

### v0.25.2 / 2024-05-09

* FIXED: Untrace entire request
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
module OpenTelemetry
module Instrumentation
module Dalli
VERSION = '0.25.2'
VERSION = '0.25.3'
end
end
end
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ Gem::Specification.new do |spec|
spec.required_ruby_version = '>= 3.0'

spec.add_dependency 'opentelemetry-api', '~> 1.0'
spec.add_dependency 'opentelemetry-common', '~> 0.21.0'
spec.add_dependency 'opentelemetry-instrumentation-base', '~> 0.22.1'

spec.add_development_dependency 'appraisal', '~> 2.5'
Expand Down
4 changes: 4 additions & 0 deletions instrumentation/ethon/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Release History: opentelemetry-instrumentation-ethon

### v0.21.7 / 2024-06-18

* FIXED: Relax otel common gem constraints

### v0.21.6 / 2024-06-12

* FIXED: Add net.peer.name to ethon
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
module OpenTelemetry
module Instrumentation
module Ethon
VERSION = '0.21.6'
VERSION = '0.21.7'
end
end
end
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ Gem::Specification.new do |spec|
spec.required_ruby_version = '>= 3.0'

spec.add_dependency 'opentelemetry-api', '~> 1.0'
spec.add_dependency 'opentelemetry-common', '~> 0.21.0'
spec.add_dependency 'opentelemetry-instrumentation-base', '~> 0.22.1'

spec.add_development_dependency 'appraisal', '~> 2.5'
Expand Down
5 changes: 5 additions & 0 deletions instrumentation/excon/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Release History: opentelemetry-instrumentation-excon

### v0.22.3 / 2024-06-18

* FIXED: Relax otel common gem constraints
* FIXED: Add `http.url` to Excon instrumentation

### v0.22.2 / 2024-05-09

* FIXED: Untrace entire request
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,11 @@ def request_call(datum)
http_method = HTTP_METHODS_TO_UPPERCASE[datum[:method]]

attributes = {
OpenTelemetry::SemanticConventions::Trace::HTTP_HOST => datum[:host],
OpenTelemetry::SemanticConventions::Trace::HTTP_METHOD => http_method,
OpenTelemetry::SemanticConventions::Trace::HTTP_SCHEME => datum[:scheme],
OpenTelemetry::SemanticConventions::Trace::HTTP_TARGET => datum[:path],
OpenTelemetry::SemanticConventions::Trace::HTTP_HOST => datum[:host],
OpenTelemetry::SemanticConventions::Trace::HTTP_URL => OpenTelemetry::Common::Utilities.cleanse_url(::Excon::Utils.request_uri(datum)),
OpenTelemetry::SemanticConventions::Trace::NET_PEER_NAME => datum[:hostname],
OpenTelemetry::SemanticConventions::Trace::NET_PEER_PORT => datum[:port]
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
module OpenTelemetry
module Instrumentation
module Excon
VERSION = '0.22.2'
VERSION = '0.22.3'
end
end
end
Loading

0 comments on commit dcf1854

Please sign in to comment.