Skip to content

Conversation

duncanpharvey
Copy link
Contributor

@duncanpharvey duncanpharvey commented Jun 30, 2025

In #13691 the v0 messaging operation for azure_servicebus was set to azure.servicebus.produce to follow the pattern set by the kafka integration (kafka.produce). However since the v1 operation schema is *.send both in this tracer and other tracers, and this is a new integration, we should use this *.send schema from the start.

  • use azure.servicebus.send for v0 operation
  • use cloud messaging operation schema for v1 operation

Note that PR #13691 has not been released yet so this is not considered a breaking change and no release note is needed

Checklist

  • PR author has checked that all the criteria below are met
  • The PR description includes an overview of the change
  • The PR description articulates the motivation for the change
  • The change includes tests OR the PR description describes a testing strategy
  • The PR description notes risks associated with the change, if any
  • Newly-added code is easy to change
  • The change follows the library release note guidelines
  • The change includes or references documentation updates if necessary
  • Backport labels are set (if applicable)

Reviewer Checklist

  • Reviewer has checked that all the criteria below are met
  • Title is accurate
  • All changes are related to the pull request's stated goal
  • Avoids breaking API changes
  • Testing strategy adequately addresses listed risks
  • Newly-added code is easy to change
  • Release note makes sense to a user of the library
  • If necessary, author has acknowledged and discussed the performance implications of this PR as reported in the benchmarks PR comment
  • Backport labels are set in a manner that is consistent with the release branch maintenance policy

@duncanpharvey duncanpharvey requested review from a team as code owners June 30, 2025 18:31
@duncanpharvey duncanpharvey changed the title fix(azure_servicebus): use azure.servicebus.send for v0 operation and cloud messaging operat… fix(azure_servicebus): use azure.servicebus.send for operation Jun 30, 2025
Copy link
Contributor

github-actions bot commented Jun 30, 2025

CODEOWNERS have been resolved as:

tests/snapshots/tests.contrib.azure_servicebus.test_azure_servicebus_snapshot.test_send_messages[span_attribute_schema_v1].json  @DataDog/apm-python
ddtrace/contrib/internal/azure_servicebus/utils.py                      @DataDog/apm-core-python @DataDog/apm-idm-python
ddtrace/ext/azure_servicebus.py                                         @DataDog/apm-core-python @DataDog/apm-idm-python
tests/contrib/azure_servicebus/test_azure_servicebus_snapshot.py        @DataDog/apm-core-python @DataDog/apm-idm-python
tests/snapshots/tests.contrib.azure_functions.test_azure_functions_snapshot.test_service_bus_distributed_tracing[disabled].json  @DataDog/apm-python
tests/snapshots/tests.contrib.azure_functions.test_azure_functions_snapshot.test_service_bus_distributed_tracing[enabled].json  @DataDog/apm-python
tests/snapshots/tests.contrib.azure_servicebus.test_azure_servicebus_snapshot.test_schedule_messages.json  @DataDog/apm-python
tests/snapshots/tests.contrib.azure_servicebus.test_azure_servicebus_snapshot.test_schedule_messages_async.json  @DataDog/apm-python
tests/snapshots/tests.contrib.azure_servicebus.test_azure_servicebus_snapshot.test_send_messages[default_config].json  @DataDog/apm-python
tests/snapshots/tests.contrib.azure_servicebus.test_azure_servicebus_snapshot.test_send_messages[distributed_tracing_disabled].json  @DataDog/apm-python
tests/snapshots/tests.contrib.azure_servicebus.test_azure_servicebus_snapshot.test_send_messages_async.json  @DataDog/apm-python

Copy link
Contributor

github-actions bot commented Jun 30, 2025

Bootstrap import analysis

Comparison of import times between this PR and base.

Summary

The average import time from this PR is: 276 ± 3 ms.

The average import time from base is: 277 ± 3 ms.

The import time difference between this PR and base is: -1.0 ± 0.1 ms.

Import time breakdown

The following import paths have shrunk:

ddtrace.auto 1.842 ms (0.67%)
ddtrace.bootstrap.sitecustomize 1.169 ms (0.42%)
ddtrace.bootstrap.preload 1.169 ms (0.42%)
ddtrace.internal.remoteconfig.client 0.630 ms (0.23%)
ddtrace 0.673 ms (0.24%)
ddtrace.internal._unpatched 0.030 ms (0.01%)
json 0.030 ms (0.01%)
json.decoder 0.030 ms (0.01%)
re 0.030 ms (0.01%)
enum 0.030 ms (0.01%)
types 0.030 ms (0.01%)

@pr-commenter
Copy link

pr-commenter bot commented Jun 30, 2025

Benchmarks

Benchmark execution time: 2025-07-01 16:39:25

Comparing candidate commit 853c039 in PR branch duncan-harvey/azure-servicebus-operation-send with baseline commit f4ac9fd in branch main.

Found 0 performance improvements and 0 performance regressions! Performance is the same for 570 metrics, 2 unstable metrics.

@brettlangdon brettlangdon added the changelog/no-changelog A changelog entry is not required for this PR. label Jul 1, 2025
@brettlangdon brettlangdon changed the title fix(azure_servicebus): use azure.servicebus.send for operation chore(azure_servicebus): use azure.servicebus.send for operation Jul 1, 2025
@duncanpharvey duncanpharvey merged commit d9a1237 into main Jul 1, 2025
445 of 449 checks passed
@duncanpharvey duncanpharvey deleted the duncan-harvey/azure-servicebus-operation-send branch July 1, 2025 17:10
happynancee pushed a commit that referenced this pull request Jul 7, 2025
)

In #13691 the v0 messaging
operation for azure_servicebus was set to `azure.servicebus.produce` to
follow the pattern set by the kafka integration (`kafka.produce`).
However since the v1 operation schema is `*.send` both in this tracer
and other tracers, and this is a new integration, we should use this
`*.send` schema from the start.

- use `azure.servicebus.send` for v0 operation
- use cloud messaging operation schema for v1 operation

**Note that PR #13691 has not been released yet so this is not
considered a breaking change and no release note is needed**

## Checklist
- [x] PR author has checked that all the criteria below are met
- The PR description includes an overview of the change
- The PR description articulates the motivation for the change
- The change includes tests OR the PR description describes a testing
strategy
- The PR description notes risks associated with the change, if any
- Newly-added code is easy to change
- The change follows the [library release note
guidelines](https://ddtrace.readthedocs.io/en/stable/releasenotes.html)
- The change includes or references documentation updates if necessary
- Backport labels are set (if
[applicable](https://ddtrace.readthedocs.io/en/latest/contributing.html#backporting))

## Reviewer Checklist
- [x] Reviewer has checked that all the criteria below are met 
- Title is accurate
- All changes are related to the pull request's stated goal
- Avoids breaking
[API](https://ddtrace.readthedocs.io/en/stable/versioning.html#interfaces)
changes
- Testing strategy adequately addresses listed risks
- Newly-added code is easy to change
- Release note makes sense to a user of the library
- If necessary, author has acknowledged and discussed the performance
implications of this PR as reported in the benchmarks PR comment
- Backport labels are set in a manner that is consistent with the
[release branch maintenance
policy](https://ddtrace.readthedocs.io/en/latest/contributing.html#backporting)
alyshawang pushed a commit that referenced this pull request Jul 25, 2025
)

In #13691 the v0 messaging
operation for azure_servicebus was set to `azure.servicebus.produce` to
follow the pattern set by the kafka integration (`kafka.produce`).
However since the v1 operation schema is `*.send` both in this tracer
and other tracers, and this is a new integration, we should use this
`*.send` schema from the start.

- use `azure.servicebus.send` for v0 operation
- use cloud messaging operation schema for v1 operation

**Note that PR #13691 has not been released yet so this is not
considered a breaking change and no release note is needed**

## Checklist
- [x] PR author has checked that all the criteria below are met
- The PR description includes an overview of the change
- The PR description articulates the motivation for the change
- The change includes tests OR the PR description describes a testing
strategy
- The PR description notes risks associated with the change, if any
- Newly-added code is easy to change
- The change follows the [library release note
guidelines](https://ddtrace.readthedocs.io/en/stable/releasenotes.html)
- The change includes or references documentation updates if necessary
- Backport labels are set (if
[applicable](https://ddtrace.readthedocs.io/en/latest/contributing.html#backporting))

## Reviewer Checklist
- [x] Reviewer has checked that all the criteria below are met 
- Title is accurate
- All changes are related to the pull request's stated goal
- Avoids breaking
[API](https://ddtrace.readthedocs.io/en/stable/versioning.html#interfaces)
changes
- Testing strategy adequately addresses listed risks
- Newly-added code is easy to change
- Release note makes sense to a user of the library
- If necessary, author has acknowledged and discussed the performance
implications of this PR as reported in the benchmarks PR comment
- Backport labels are set in a manner that is consistent with the
[release branch maintenance
policy](https://ddtrace.readthedocs.io/en/latest/contributing.html#backporting)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
changelog/no-changelog A changelog entry is not required for this PR.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants