Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ServiceBus] Removed async from sync op #28761

Merged
merged 3 commits into from
Mar 8, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions sdk/servicebus/azure-servicebus/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
### Breaking Changes

### Bugs Fixed
- Fixed a bug where asynchronous method to add distributed tracing attributes was not being awaited (Issue #28738).

### Other Changes

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -387,7 +387,7 @@ async def _mgmt_request_response_with_retry(
**kwargs
)

async def _add_span_request_attributes(self, span):
def _add_span_request_attributes(self, span):
return BaseHandlerSync._add_span_request_attributes( # pylint: disable=protected-access
self, span
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,7 @@ async def schedule_messages(
schedule_time_utc, send_span, *obj_messages
)
if send_span:
await self._add_span_request_attributes(send_span)
self._add_span_request_attributes(send_span)
return await self._mgmt_request_response_with_retry(
REQUEST_RESPONSE_SCHEDULE_MESSAGE_OPERATION,
request_body,
Expand Down Expand Up @@ -375,7 +375,7 @@ async def send_messages(
return # Short circuit noop if an empty list or batch is provided.

if send_span:
await self._add_span_request_attributes(send_span)
self._add_span_request_attributes(send_span)

await self._do_retryable_operation(
self._send,
Expand Down