Skip to content

Commit

Permalink
Merge branch 'main' into patch-5
Browse files Browse the repository at this point in the history
  • Loading branch information
rahuldimri authored Jul 10, 2024

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
2 parents dbbb145 + 5ff46ac commit bacee50
Showing 130 changed files with 2,984 additions and 894 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/instrumentations_0.yml
Original file line number Diff line number Diff line change
@@ -127,4 +127,4 @@ jobs:
~/.cache/pip
key: v7-build-tox-cache-${{ env.RUN_MATRIX_COMBINATION }}-${{ hashFiles('tox.ini', 'gen-requirements.txt', 'dev-requirements.txt') }}
- name: run tox
run: tox -f ${{ matrix.python-version }}-${{ matrix.package }} -- -ra --benchmark-json=${{ env.RUN_MATRIX_COMBINATION }}-benchmark.json
run: tox -f ${{ matrix.python-version }}-${{ matrix.package }} -- -ra
4 changes: 3 additions & 1 deletion .github/workflows/instrumentations_1.yml
Original file line number Diff line number Diff line change
@@ -35,7 +35,9 @@ jobs:
- "sdk-extension-aws"
- "propagator-aws-xray"
- "propagator-ot-trace"
- "resource-detector-azure"
- "resource-detector-container"
- "util-http"
os: [ubuntu-20.04]
exclude:
- python-version: pypy3
@@ -58,4 +60,4 @@ jobs:
~/.cache/pip
key: v7-build-tox-cache-${{ env.RUN_MATRIX_COMBINATION }}-${{ hashFiles('tox.ini', 'gen-requirements.txt', 'dev-requirements.txt') }}
- name: run tox
run: tox -f ${{ matrix.python-version }}-${{ matrix.package }} -- -ra --benchmark-json=${{ env.RUN_MATRIX_COMBINATION }}-benchmark.json
run: tox -f ${{ matrix.python-version }}-${{ matrix.package }} -- -ra
2 changes: 2 additions & 0 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -68,8 +68,10 @@ jobs:
- "processor-baggage"
- "propagator-aws-xray"
- "propagator-ot-trace"
- "resource-detector-azure"
- "resource-detector-container"
- "sdk-extension-aws"
- "util-http"
os: [ubuntu-20.04]
runs-on: ubuntu-20.04
steps:
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -58,3 +58,6 @@ _build/
# mypy
.mypy_cache/
target

# Benchmark result files
*-benchmark.json
37 changes: 31 additions & 6 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -7,11 +7,6 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## Unreleased

- `opentelemetry-instrumentation-aws-lambda` Bugfix: AWS Lambda event source key incorrect for SNS in instrumentation library.
([#2612](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2612))
- `opentelemetry-instrumentation-system-metrics` Permit to use psutil 6.0+.
([#2630](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2630))

### Added

- `opentelemetry-instrumentation-pyramid` Record exceptions raised when serving a request
@@ -20,13 +15,26 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
([#2573](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2573))
- `opentelemetry-instrumentation-confluent-kafka` Add support for version 2.4.0 of confluent_kafka
([#2616](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2616))
- `opentelemetry-instrumentation-asyncpg` Add instrumentation to cursor based queries
([#2501](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2501))
- `opentelemetry-instrumentation-confluent-kafka` Add support for produce purge
([#2638](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2638))
- `opentelemetry-instrumentation-asgi` Implement new semantic convention opt-in with stable http semantic conventions
([#2610](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2610))
- `opentelemetry-instrumentation-httpx` Implement new semantic convention opt-in migration with stable http semantic conventions
([#2631](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2631))
- `opentelemetry-instrumentation-system-metrics` Permit to use psutil 6.0+.
([#2630](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2630))
- `opentelemetry-instrumentation-system-metrics` Add support for capture open file descriptors
([#2652](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2652))

### Breaking changes

- `opentelemetry-instrumentation-asgi`, `opentelemetry-instrumentation-fastapi`, `opentelemetry-instrumentation-starlette` Use `tracer` and `meter` of originating components instead of one from `asgi` middleware
([#2580](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2580))
- Populate `{method}` as `HTTP` on `_OTHER` methods from scope
([#2610](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2610))


### Fixed

@@ -38,6 +46,22 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
([#2590](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2590))
- Reference symbols from generated semantic conventions
([#2611](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2611))
- `opentelemetry-instrumentation-psycopg` Bugfix: Handle empty statement.
([#2644](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2644))
- `opentelemetry-instrumentation-confluent-kafka` Confluent Kafka: Ensure consume span is ended when consumer is closed
([#2640](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2640))
- `opentelemetry-instrumentation-asgi` Fix generation of `http.target` and `http.url` attributes for ASGI apps
using sub apps
([#2477](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2477))
- `opentelemetry-instrumentation-aws-lambda` Bugfix: AWS Lambda event source key incorrect for SNS in instrumentation library.
([#2612](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2612))
- `opentelemetry-instrumentation-asyncio` instrumented `asyncio.wait_for` properly raises `asyncio.TimeoutError` as expected
([#2637](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2637))
- `opentelemetry-instrumentation-django` Handle exceptions from request/response hooks
([#2153](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2153))
- `opentelemetry-instrumentation-asgi` Removed `NET_HOST_NAME` AND `NET_HOST_PORT` from active requests count attribute
([#2610](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2610))


## Version 1.25.0/0.46b0 (2024-05-31)

@@ -145,7 +169,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
([#2136](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2136))
- `opentelemetry-resource-detector-azure` Suppress instrumentation for `urllib` call
([#2178](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2178))
- AwsLambdaInstrumentor handles and re-raises function exception ([#2245](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2245))
- AwsLambdaInstrumentor handles and re-raises function exception
([#2245](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2245))

### Added

8 changes: 3 additions & 5 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -96,9 +96,7 @@ for more detail on available tox commands.
### Benchmarks

Performance progression of benchmarks for packages distributed by OpenTelemetry Python can be viewed as a [graph of throughput vs commit history](https://opentelemetry-python-contrib.readthedocs.io/en/latest/performance/benchmarks.html). From the linked page, you can download a JSON file with the performance results.

Running the `tox` tests also runs the performance tests if any are available. Benchmarking tests are done with `pytest-benchmark` and they output a table with results to the console.
Some packages have benchmark tests. To run them, run `tox -f benchmark`. Benchmark tests use `pytest-benchmark` and they output a table with results to the console.

To write benchmarks, simply use the [pytest benchmark fixture](https://pytest-benchmark.readthedocs.io/en/latest/usage.html#usage) like the following:

@@ -114,10 +112,10 @@ def test_simple_start_span(benchmark):
benchmark(benchmark_start_as_current_span, "benchmarkedSpan", 42)
```

Make sure the test file is under the `tests/performance/benchmarks/` folder of
Make sure the test file is under the `benchmarks/` folder of
the package it is benchmarking and further has a path that corresponds to the
file in the package it is testing. Make sure that the file name begins with
`test_benchmark_`. (e.g. `propagator/opentelemetry-propagator-aws-xray/tests/performance/benchmarks/trace/propagation/test_benchmark_aws_xray_propagator.py`)
`test_benchmark_`. (e.g. `propagator/opentelemetry-propagator-aws-xray/benchmarks/trace/propagation/test_benchmark_aws_xray_propagator.py`)

## Pull Requests

Original file line number Diff line number Diff line change
@@ -11,7 +11,6 @@ pluggy==1.5.0
protobuf==4.25.3
py-cpuinfo==9.0.0
pytest==7.4.4
pytest-benchmark==4.0.0
python-snappy==0.7.1
requests==2.32.3
tomli==2.0.1
Original file line number Diff line number Diff line change
@@ -10,7 +10,6 @@ pluggy==1.5.0
py-cpuinfo==9.0.0
Pygments==2.17.2
pytest==7.4.4
pytest-benchmark==4.0.0
rich==13.7.1
tomli==2.0.1
typing_extensions==4.10.0
4 changes: 2 additions & 2 deletions instrumentation/README.md
Original file line number Diff line number Diff line change
@@ -5,7 +5,7 @@
| [opentelemetry-instrumentation-aiohttp-client](./opentelemetry-instrumentation-aiohttp-client) | aiohttp ~= 3.0 | No | experimental
| [opentelemetry-instrumentation-aiohttp-server](./opentelemetry-instrumentation-aiohttp-server) | aiohttp ~= 3.0 | No | experimental
| [opentelemetry-instrumentation-aiopg](./opentelemetry-instrumentation-aiopg) | aiopg >= 0.13.0, < 2.0.0 | No | experimental
| [opentelemetry-instrumentation-asgi](./opentelemetry-instrumentation-asgi) | asgiref ~= 3.0 | No | experimental
| [opentelemetry-instrumentation-asgi](./opentelemetry-instrumentation-asgi) | asgiref ~= 3.0 | Yes | migration
| [opentelemetry-instrumentation-asyncio](./opentelemetry-instrumentation-asyncio) | asyncio | No | experimental
| [opentelemetry-instrumentation-asyncpg](./opentelemetry-instrumentation-asyncpg) | asyncpg >= 0.12.0 | No | experimental
| [opentelemetry-instrumentation-aws-lambda](./opentelemetry-instrumentation-aws-lambda) | aws_lambda | No | experimental
@@ -22,7 +22,7 @@
| [opentelemetry-instrumentation-fastapi](./opentelemetry-instrumentation-fastapi) | fastapi ~= 0.58 | Yes | experimental
| [opentelemetry-instrumentation-flask](./opentelemetry-instrumentation-flask) | flask >= 1.0 | Yes | migration
| [opentelemetry-instrumentation-grpc](./opentelemetry-instrumentation-grpc) | grpcio ~= 1.27 | No | experimental
| [opentelemetry-instrumentation-httpx](./opentelemetry-instrumentation-httpx) | httpx >= 0.18.0 | No | experimental
| [opentelemetry-instrumentation-httpx](./opentelemetry-instrumentation-httpx) | httpx >= 0.18.0 | No | migration
| [opentelemetry-instrumentation-jinja2](./opentelemetry-instrumentation-jinja2) | jinja2 >= 2.7, < 4.0 | No | experimental
| [opentelemetry-instrumentation-kafka-python](./opentelemetry-instrumentation-kafka-python) | kafka-python >= 2.0 | No | experimental
| [opentelemetry-instrumentation-logging](./opentelemetry-instrumentation-logging) | logging | No | experimental
Original file line number Diff line number Diff line change
@@ -11,7 +11,6 @@ pamqp==3.1.0
pluggy==1.5.0
py-cpuinfo==9.0.0
pytest==7.4.4
pytest-benchmark==4.0.0
tomli==2.0.1
typing_extensions==4.9.0
wrapt==1.16.0
Original file line number Diff line number Diff line change
@@ -11,7 +11,6 @@ pamqp==3.2.1
pluggy==1.5.0
py-cpuinfo==9.0.0
pytest==7.4.4
pytest-benchmark==4.0.0
tomli==2.0.1
typing_extensions==4.9.0
wrapt==1.16.0
Original file line number Diff line number Diff line change
@@ -11,7 +11,6 @@ pamqp==3.2.1
pluggy==1.5.0
py-cpuinfo==9.0.0
pytest==7.4.4
pytest-benchmark==4.0.0
tomli==2.0.1
typing_extensions==4.9.0
wrapt==1.16.0
Original file line number Diff line number Diff line change
@@ -11,7 +11,6 @@ pamqp==3.3.0
pluggy==1.5.0
py-cpuinfo==9.0.0
pytest==7.4.4
pytest-benchmark==4.0.0
tomli==2.0.1
typing_extensions==4.9.0
wrapt==1.16.0
Original file line number Diff line number Diff line change
@@ -21,7 +21,6 @@ packaging==24.0
pluggy==1.5.0
py-cpuinfo==9.0.0
pytest==7.4.4
pytest-benchmark==4.0.0
requests==2.32.3
tomli==2.0.1
typing_extensions==4.10.0
Original file line number Diff line number Diff line change
@@ -14,7 +14,6 @@ py-cpuinfo==9.0.0
pytest==7.4.4
pytest-aiohttp==1.0.5
pytest-asyncio==0.23.5
pytest-benchmark==4.0.0
tomli==2.0.1
typing_extensions==4.10.0
wrapt==1.16.0
Original file line number Diff line number Diff line change
@@ -10,7 +10,6 @@ pluggy==1.5.0
psycopg2-binary==2.9.9
py-cpuinfo==9.0.0
pytest==7.4.4
pytest-benchmark==4.0.0
tomli==2.0.1
typing_extensions==4.10.0
wrapt==1.16.0
Loading

0 comments on commit bacee50

Please sign in to comment.