Skip to content

Commit

Permalink
Merge branch 'main' into add-ruby-3-3-tests-for-sql-helper-gems
Browse files Browse the repository at this point in the history
  • Loading branch information
xuan-cao-swi authored Jul 20, 2024
2 parents 17a0d83 + 246fc10 commit 511ecb1
Show file tree
Hide file tree
Showing 105 changed files with 250 additions and 136 deletions.
83 changes: 83 additions & 0 deletions .cspell.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
# cSpell:ignore textlintrc
# For settings, see
# https://www.streetsidesoftware.com/vscode-spell-checker/docs/configuration/
version: '0.2'
caseSensitive: false
patterns:
- name: CodeBlock
pattern: |
/
^(\s*[~`]{3,}) # code-block start
.* # all languages and options, e.g. shell {hl_lines=[12]}
[\s\S]*? # content
\1 # code-block end
/igmx
languageSettings:
- languageId: markdown
ignoreRegExpList:
- CodeBlock
words:
- AWSX
- Azuma
- backports
- behaviour
- Bogsanyi
- callables
- circleci
- Clientcontext
- codeowners
- dalli
- datadog
- enqueuers
- ethon
- excon
- faas
- fanout
- faraday
- gettime
- gemfile
- Gitter
- gruf
- HTTPX
- httpx
- instrumenter
- Laurin
- Lightstep
- linux
- lmdb
- microbenchmarks
- Mustin
- myapp
- namespacing
- opentelemetry
- otelcol
- ottrace
- postgres
- postgresql
- racecar
- rabbitmq
- Railtie
- Rakefile
- Reopelle
- rdkafka
- resque
- restclient
- Robb
- rubocop
- rubydocs
- ruboproof
- rubygems
- Šimánek
- semconv
- sidekiq
- sinatra
- Solarwinds
- spanid
- toolset
- traceid
- traceresponse
- Untrace
- vitess
- webmocks
- Xuan
- yardoc
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.180.1
uses: ruby/setup-ruby@v1.187.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.180.1
uses: ruby/setup-ruby@v1.187.0
with:
ruby-version: "${{ inputs.ruby }}"
bundler: "latest"
Expand Down
17 changes: 17 additions & 0 deletions .github/workflows/check-spelling.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
name: Spelling

on:
pull_request:

jobs:
spelling-check:
name: SPELLING check
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: streetsidesoftware/cspell-action@v6
with:
# Files should be consistent with check:spelling files
files: |
**/*.md
config: .cspell.yml
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.6.0"
ruby: "jruby-9.4.8.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.6.0"
ruby: "jruby-9.4.8.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.6.0"
ruby: "jruby-9.4.8.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.6.0"
ruby: "jruby-9.4.8.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.6.0"
ruby: "jruby-9.4.8.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 @@ -110,4 +110,4 @@ jobs:
uses: ./.github/actions/test_gem
with:
gem: "opentelemetry-instrumentation-${{ matrix.gem }}"
ruby: "jruby-9.4.6.0"
ruby: "jruby-9.4.8.0"
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.180.1
- uses: ruby/setup-ruby@v1.187.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.180.1
uses: ruby/setup-ruby@v1.187.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.180.1
uses: ruby/setup-ruby@v1.187.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.180.1
uses: ruby/setup-ruby@v1.187.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.180.1
- uses: ruby/setup-ruby@v1.187.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.180.1
uses: ruby/setup-ruby@v1.187.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.180.1
uses: ruby/setup-ruby@v1.187.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.180.1
uses: ruby/setup-ruby@v1.187.0
with:
ruby-version: ${{ env.ruby_version }}
- name: Checkout repo
Expand Down
2 changes: 1 addition & 1 deletion .instrumentation_generator/templates/gemspec.tt
Original file line number Diff line number Diff line change
Expand Up @@ -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.48.1'
spec.add_development_dependency 'rubocop', '~> 1.65.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'
Expand Down
16 changes: 13 additions & 3 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -208,11 +208,21 @@ merge. You'll probably get some feedback from these fine folks which helps to
make the project that much better. Respond to the feedback and work with your
reviewer(s) to resolve any issues.

The some of the things the code owners are looking for include:
* a signed [CNCF CLA][cncf-cla]
* a passing CI build
* adherence to the principles and features outlined in the
[instrumentation author's guide](.instrumentation/CONTRIBUTING.md)

Reviewers are responsible for ensuring that each merged PR's commit message
conforms to [conventional commits](https://conventionalcommits.org). This may
mean editing the commit message when you merge the pull request. Alternately,
the reviewer may ask the pull request submitter to amend the commit message of
their initial commit.
mean editing the commit message or the pull request title when you merge the
pull request. Alternately, the reviewer may ask the pull request submitter
to amend the commit message of their initial commit.

In addition, when a change is complex or a reviewer is unfamiliar with the code,
the reviewer may seek additional reviews from people more familiar with the
change before merging a PR.

## Releases

Expand Down
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ multiple instrumentation libraries.
- [SQL Obfuscation](helpers/sql-obfuscation/)
## Additional Libraries

This repository also contains libraries to aid with interoperablity with vendor specific tracing solutions:
This repository also contains libraries to aid with interoperability with vendor specific tracing solutions:

- [Context Propagation](propagator/): OTTrace and Amazon X-Ray
- [Resource Detectors](resources/):
Expand All @@ -74,18 +74,18 @@ This repository also contains libraries to aid with interoperablity with vendor

OpenTelemetry Ruby follows the [versioning and stability document][otel-versioning] in the OpenTelemetry specification. Notably, we adhere to the outlined version numbering exception, which states that experimental signals may have a `0.x` version number.

### Library Compatability
### Library Compatibility

This project is managed on a volunteer basis and therefore we have limited capacity to support compatability with unmaintained or EOL libraries.
This project is managed on a volunteer basis and therefore we have limited capacity to support compatibility with unmaintained or EOL libraries.

We will regularly review the instrumentations to drop compatability for any versions of Ruby or gems that reach EOL or no longer receive regular maintenance.
We will regularly review the instrumentations to drop compatibility for any versions of Ruby or gems that reach EOL or no longer receive regular maintenance.

Should you need instrumentation for _older_ versions of a library then you must pin to a specific version of the instrumentation that supports it,
however, you will no longer receive any updates for the instrumentation from this repository.

> When a release series is no longer supported, it's your own responsibility to deal with bugs and security issues. We may provide backports of the fixes and publish them to git, however there will be no new versions released. If you are not comfortable maintaining your own versions, you should upgrade to a supported version. <https://guides.rubyonrails.org/maintenance_policy.html#security-issues>
Consult instrumentation gem's README file and gemspec for details about library compatability.
Consult instrumentation gem's README file and gemspec for details about library compatibility.

### Releases

Expand Down
2 changes: 1 addition & 1 deletion helpers/mysql/opentelemetry-helpers-mysql.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -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.64.0'
spec.add_development_dependency 'rubocop', '~> 1.65.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'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -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.64.0'
spec.add_development_dependency 'rubocop', '~> 1.65.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'
Expand Down
6 changes: 3 additions & 3 deletions instrumentation/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,7 @@ For example, the `Werewolf` module generated in the example above is available v

Whenever possible, use first-party extension points (hooks) to instrument libraries. This ensures that the instrumentation is compatible with the latest versions of the library and that the instrumentation is maintained by the library authors. [`ActiveSupport::Notifications`](https://guides.rubyonrails.org/active_support_instrumentation.html) and `Middleware` are good examples of first-party extension points used by our instrumentation libraries.

Monkey patching is discouraged in OpenTelemetry Ruby because it is the most common source of bugs and incompatability with the libraries we instrument. If you must monkey patch, please ensure that the monkey patch is as isolated as possible and that it is clearly documented.
Monkey patching is discouraged in OpenTelemetry Ruby because it is the most common source of bugs and incompatibility with the libraries we instrument. If you must monkey patch, please ensure that the monkey patch is as isolated as possible and that it is clearly documented.

### Use Semantic Conventions

Expand Down Expand Up @@ -337,7 +337,7 @@ Add the service container to `jobs/instrumentation_with_services/services` and a

> :information_source: Please refer to the official [GitHub Actions Documentation](https://docs.github.com/en/actions/using-containerized-services/about-service-containers) for more information on how to add a service container.

If we determine the service container slows down the test suite significantly, it may make sense to copy the marix and steps stanzas from an existing instrumentation and update it to use the new service container as a dependency:
If we determine the service container slows down the test suite significantly, it may make sense to copy the matrix and steps stanzas from an existing instrumentation and update it to use the new service container as a dependency:

```yaml
Expand Down Expand Up @@ -407,7 +407,7 @@ In addition to that, there should also be redundant `yardoc` comments in the ent

### Examples

Executuable examples should be included in the `examples` directory that demonstrate how to use the instrumentation in a real-world scenario.
Executable examples should be included in the `examples` directory that demonstrate how to use the instrumentation in a real-world scenario.

We recommend using [Bundler's inline gemfile](https://bundler.io/guides/bundler_in_a_single_file_ruby_script.html) to run the examples. Here is an example from the `grape` instrumentation:

Expand Down
6 changes: 3 additions & 3 deletions instrumentation/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,14 +40,14 @@ Instrumentation-specific documentation can be found in each subdirectory's `READ

You also have the option of installing all of the instrumentation libraries by installing `opentelemetry-instrumentation-all`. See that gem's [README](https://github.com/open-telemetry/opentelemetry-ruby-contrib/tree/main/instrumentation/all) for more.

### Maintenance and Version Compatability
### Maintenance and Version Compatibility

We are a community of volunteers who do our best to provide our users with up to date support for instrumentations,
however we have limited capacity and are unable to support compatability with EOL or unmaintained libraries.
however we have limited capacity and are unable to support compatibility with EOL or unmaintained libraries.

Should you need to instrument an _older_ version of a library you will have to ensure to pin to an instrumentation version that is compatible with that library.

Please review the individual instrumentation READMEs for more information about version compatability.
Please review the individual instrumentation READMEs for more information about version compatibility.

## How can I get involved?

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -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.64.0'
spec.add_development_dependency 'rubocop', '~> 1.65.0'
spec.add_development_dependency 'rubocop-performance', '~> 1.20'
spec.add_development_dependency 'simplecov', '~> 0.17.1'
spec.add_development_dependency 'webmock', '~> 3.19'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -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.64.0'
spec.add_development_dependency 'rubocop', '~> 1.65.0'
spec.add_development_dependency 'rubocop-performance', '~> 1.20'
spec.add_development_dependency 'simplecov', '~> 0.17.1'
spec.add_development_dependency 'webmock', '~> 3.19'
Expand Down
2 changes: 1 addition & 1 deletion instrumentation/action_view/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@

### v0.2.0 / 2021-12-01

* ADDED: Move activesupport notification subsciber out of action_view gem
* ADDED: Move activesupport notification subscriber out of action_view gem
* FIXED: Instrumentation of Rails 7

### v0.1.3 / 2021-10-06
Expand Down
Loading

0 comments on commit 511ecb1

Please sign in to comment.